Sunday, July 5, 2009
Pico Projector with BeagleBoard
Accessing GPIO
1. On and Off LED at the expansion pins of Beagle Board
10 easy steps for switching on and off the LED at expansion pins of BB.
It is assumed that you are having Angstrom distribution on your BB.
Make sure that you have mounted (soldered) the expansion connector on BB. You have a low powered LED. If you dont have low power LED, use multimeter instead. Connect the LED between pin 24 and 28 (GND). And now follow the steps below to on and off LED via expansion pin.
1. Open a Terminal (Applications >> Accessories >> terminal ).
2. Boot BB by writing command minicom.
3. Log-in as a root.
4. write command cd /sys/class/gpio
5. Enter command echo 168 > export (expansion port GPIO 168 = pin 24. You can also access User LED where 150 = usr1 LED and 149 = usr0 LED. For numbers refer http://http://elinux.org/upload/5/51/Bb-expansion.pdf ). That should create directory /sys/class/gpio/gpio150, with all the access you want.
6. Enter cd /sys/class/gpio/gpio150
7. Enter echo "high" > direction (Check the LED status. It should be on)
8. Enter echo "low" > direction (Check the LED status. It should be off)
Done!
If you want then to unmount the device, use unexport
9. Enter cd /sys/class/gpio/
10. Enter echo 150 > unexport
You can follow the above procedure to check the functioning of the other pins
2. Infinite loop - On and Off LED at the expansion pins of Beagle
So log in to your Beagle Board as root, and enter the following program into a file called strobe_gpio:
#!/bin/sh
#
# Blink the onboard LED
GPIO=$1
cleanup() { # Release the GPIO port
echo $GPIO > /sys/class/gpio/unexport
exit
}
# Open the GPIO portThe vi editor is included with the Beagle Board, so you can type "
#
echo $GPIO > /sys/class/gpio/export
trap cleanup SIGINT # call cleanup on Ctrl-C
# Blink forever
while [ "1" = "1" ]; do
echo "high" > /sys/class/gpio/gpio$GPIO/direction
sleep 1
echo "low" > /sys/class/gpio/gpio$GPIO/direction
sleep 1
done
cleanup # call the cleanup routine
vi strobe_gpio"
, type "i" (to get into insert mode), then paste the program in. Next, press Escape (to get back into command mode), and type to save the file and ":w"":q" to exit from VI. This should drop you back into the Linux shell. (There are many vi tutorials 
Next, type " chmod 755 strobe_gpio"
. Then, insert an LED as shown (short end into pin 28, long end into pin 24) . Try the command"./strobe_gpio 168"
and you should see the LED blinking.
Try this out also: type " chmod 755 strobe_gpio"
. Try the command "./strobe_gpio 149" or
"./strobe_gpio 150"
and you should see the user LED blinking
3. Reading Beagleboard User button or any GPIO
vi read_gpio"
, type "i" and paste the program belowchmod 755 read_gpio"
. Try the command "./read_gpio 7"
OS on Beagleboard
Peripherals for BeagleBoard
The supply must have a 2.1mm center hot connector with a 5.5mm outside diameter. A picture in right of the type of power supply will be used on the BeagleBoard.
WARNING: DO NOT PLUG IN ANYTHING BUT 5V TO THE DC CONNECTOR OR THE BOARD WILL BE DAMAGED!!!!
The main USB port on the BeagleBoard is a USB OTG (On-the-Go) port. It can be used as an OTG port or Client port. The main use is as a client port, as that is the mode that will supply the power needed to power the BeagleBoard.
NOTE: In order to use the OTG in the Host mode, the BeagleBoard must be powered from the DC supply.
RS232 :
In order to access the serial port of the BeagleBoard a flat cable is required to connect to a PC. The adapter will not plug directly into the PC and will require an external Female to Female twisted cable (Null Modem) in order to connect it to the PC. The ribbon cable is not supplied with the BeagleBoard but can be obtained from numerous sources.
An S-Video cable can be connected to the BeagleBoard and from there is can be connected to a TV or monitor that supports an S-Video input.
In order to connect the DVI-D output to a monitor, a HDMI to DVI-D cable is required.
External Audio input devices, such as a powered microphone or the audio output of a PC or MP3 player, can be connected to the via a 3.5mm jack (Audio IN).
An external Audio output device, such as external stereo powered speakers, can be connected to the BeagleBoard via a 3.5mm jack (Audio OUT).
The SD/MMC connector can be used for Memory or SDIO type cards.
HS USB 2.0 Host Port (Rev C2 Only) :
The Rev C2 Beagle is equipped with a USB Host only connector and can be used to support USB based devices. In order to connect multiple devices a Hub is required. The hub can be powered or un-powered if the total current on the devices connected to the hub do not exceed the available power from the DC source. If the board is powered from the OTG connector, then the power available from this port is extremely limited and will not be able to provide sufficient power to run most USB devices. It may be possible to run a USB keyboard or mouse, but that is about all it will have the power to supply. The USB Host port is HS only and does not support LS or FS devices without a hub.
The expansion header is provided to allow a limited number of functions to be added to the board via the addition of a daughtercard.
A JTAG emulator can be used for advanced debugging by connecting it to the JTAG header on the BeagleBoard. Only the 14pin version of the JTAG is supported and if a 20 pin version is needed, you will to contact your emulator supplier for the appropriate adapter.
There are four green indicators on the BeagleBoard. One of them, POWER, indicates that the main supply is active. The other three can be controlled by the software.
BeagleBoard out of box
What's in the box?
Box should have a 3"x3" OMAP3530 Board.
Is their any factory default software flashed onto this board?
Yes, x-loader and u-boot will be flashed on to this board.
How can I execute factory defaults from Beagle Board?
Each BeagleBoard comes pre-loaded with the XLoader and UBoot in Flash. When powered up, it will do the following:
1. Plug in either a USB cable to the board and then to a PC or plug in a 5V power supply.
2. Power LED (D5) will turn on.
3. On the terminal window the following will be printed:
Texas Instruments X-Loader 1.4.2 (Feb 19 2009 - 12:01:24)
Loading u-boot.bin from nand
U-Boot 2009.01-dirty (Feb 19 2009 - 12:22:31)
I2C: ready
OMAP3530-GP rev 2, CPU-OPP2 L3-165MHz
OMAP3 Beagle board + LPDDR/NAND
DRAM: 256 MB
NAND: 256 MiB
*** Warning - bad CRC or NAND, using default environment
MUSB: using high speed
In: serial usbtty
Out: serial usbtty
Err: serial usbtty
The warning message is not an indication of an error condition and is normal. The UBoot is configured to look for a script file on the SD card for booting instructions. If not found, it will then look for the environment variables. As these are not loaded at the factory, you will see the warning message.
4. At this point the following LEDS will turn on:
o USR0
o USR1
o PMU
5. Then the following will be sent to the terminal window and a countdown will commence. To stop the countdown, hit any key on the terminal Board revision C
Serial #486000030000000004013f8a17019010
Hit any key to stop autoboot: 10
The revision of the board should be identified as a Rev C. The Serial# is NOT the board serial number, but a unique ID for the processor.
Validating BeagleBoard with test and Diagnostics:
Visit http://code.google.com/p/beagleboard/wiki/BeagleBoardDiagnostics
What to do next?
Can try to compile Linux Kernel Image directly from O[http://www.muru.com/linux/omap OMAP GIT]
Can try some [http://code.google.com/p/beagleboard/wiki/BeagleSourceCode sample images and sources]
Learn [http://code.google.com/p/beagleboard/wiki/BeagleSoftCompile how to compile sources] and generate images for Beagle
Try some quick [http://code.google.com/p/beagleboard/wiki/Demos Demos]
Source of these contents is here (http://beagleboard.googlecode.com/svn-history/r166/wiki/outofthebox.wiki)
What is a BeagleBoard ?
The BeagleBoard is an OMAP3530 platform designed specifically to address the Open Source Community. It has been equipped with a minimum set of features to allow the user to experience the power of the OMAP3530 and is not intended as a full development platform as many of the features and interfaces supplied by the OMAP3530 are not accessible from BeagleBoard. By utilizing standard interfaces, the BeagleBoard is highly extensible to add many features and interfaces.
This site is for those who just bought BeagleBoard and don't know how and where to start. :-)
What exactly a BeagleBoard is ?
The Beagle Board is a low-power, low-cost Single-board computer produced by Texas Instruments in association with Digi-Key, designed with open source development in mind, to demonstrate the Texas Instrument's OMAP3530 system-on-a-chip. The board was developed by a small team of TI engineers. (for more than a brief introduction, go here )
Literally BeagleBoard stands for
Besides this fellow
B ring your own peripherals
E ntry-level cost ($149)
A rm Cortex-A8 (600MHz, superscaler)
G raphics and DSP / Video accelerated
L inux and open source community
E nvironment for software innovators
Where can BeagleBoard be used?
Useful Links (credit goes to Matthias Klostermann)
- Official Beagle Board HP: http://beagleboard.com
- eLinux.org Wiki Beagle Board page: http://www.elinux.org/BeagleBoard
- Angström Linux Distribution: http://www.angstrom-distribution.org/
- Angström Image Builder: http://amethyst.openembedded.net/~koen/narcissus/
- OpenEmbedded?: http://wiki.openembedded.net/index.php/Main_Page
- DavinciDSP?: http://wiki.davincidsp.com/index.php?title=Main_Page&HQS=dsp_omap_dav_dev_wiki_081012&DCMP=mytinwsltr_02_21_2009
- OmapZoom?: https://www.omapzoom.org/gf/project/omapzoomhome/
- VirtualBox?: http://www.virtualbox.org/wiki/Downloads
Important:
I am not responsible for any false information or any problems occurring due to use of this site. This is an effort to help the students who would like to have a hand on Beagleboard and its development. Information provided here is completely based on either my experience or compilation of information from other websites. If anyone would like to take part in improving the quality of this site, please contact me at kunal.mm@gmail.com
The BeagleBoard is an OMAP3530 platform designed specifically to address the Open Source Community. It has been equipped with a minimum set of features to allow the user to experience the power of the OMAP3530 and is not intended as a full development platform as many of the features and interfaces supplied by the OMAP3530 are not accessible from BeagleBoard. By utilizing standard interfaces, the BeagleBoard is highly extensible to add many features and interfaces.
This site is for those who just bought BeagleBoard and don't know how and where to start. :-)
B ring your own peripherals
E ntry-level cost ($149)
A rm Cortex-A8 (600MHz, superscaler)
G raphics and DSP / Video accelerated
L inux and open source community
E nvironment for software innovators
- Official Beagle Board HP: http://beagleboard.com
- eLinux.org Wiki Beagle Board page: http://www.elinux.org/BeagleBoard
- Angström Linux Distribution: http://www.angstrom-distribution.org/
- Angström Image Builder: http://amethyst.openembedded.net/~koen/narcissus/
- OpenEmbedded?: http://wiki.openembedded.net/index.php/Main_Page
- DavinciDSP?: http://wiki.davincidsp.com/index.php?title=Main_Page&HQS=dsp_omap_dav_dev_wiki_081012&DCMP=mytinwsltr_02_21_2009
- OmapZoom?: https://www.omapzoom.org/gf/project/omapzoomhome/
- VirtualBox?: http://www.virtualbox.org/wiki/Downloads