Friday, November 13, 2015

Develop an application using Beeglebone Black/ ARM Cortex A5 development board to simulate the working of signal lights.

traffic.py

import Adafruit_BBIO.GPIO as g
g.setup("P8_10",g.OUT)
g.setup("P8_14",g.OUT)
g.setup("P8_16",g.OUT)
#g.setup("P8_10",g.OUT)
import time
while True :
        g.output("P8_10",g.HIGH)
       # g.output("P8_9",g.HIGH)
        g.output("P8_14",g.LOW)
        g.output("P8_16",g.LOW)
        time.sleep(5)
        g.output("P8_14",g.HIGH)
        g.output("P8_16",g.LOW)
        g.output("P8_10",g.LOW)
      #  g.output("P8_9",g.LOW)
        time.sleep(5)
~       g.output("P8_14",g.LOW)
        g.output("P8_16",g.HIGH)
        g.output("P8_10",g.LOW)

      #  g.output("P8_9",g.LOW)

6 comments:

  1. what is "g" here,if it is an object then where is its corresponding class ?

    ReplyDelete
    Replies
    1. Check the change. Tell if you need further explanation.
      Thanks for bringing my attention to it.

      Delete
  2. Whether it is a complete one code or a module.....

    ReplyDelete
    Replies
    1. It is the complete code Jenit. P8_10,P8_14 and P8_16 pins of the BBB are connected to green, yellow and red led bulbs respectively.

      Delete
  3. Can i have a look over the output pease....

    ReplyDelete
    Replies
    1. Sorry Aman
      I don't have a BBB anymore to show you the output. But try implementing the code with one and you will understand the output.

      Delete

Perform a suitable assignment using Xen Hypervisor or equivalent open source to configure it. Give necessary GUI.

 To install kvm on Fedora:  yum install kvm  yum install virt-manager libvirt libvirt-python python-virtinst  su -c "yum install @v...