i grabbed a new BeagleBoard-XM Rev C from eBay and thought i would document the first steps towards getting a project running with it…
WTF is a BeagleBoard-XM?
the BeagleBoard, BeagleBoard-XM, and BeagleBone are a family of small (3.5″), inexpensive, singe-board computers based on the ARM Cortex-A8 CPU. unlike MCU’s such as the Arduino, PIC, NetDuino, these run a full OS (usually Linux or Android). they do however feature some of the same low level interfaces like GPIO, I2C, SPI, etc. there are faster boards (PandaBoard ES, HawkBoard, etc.), but the BeagleBoard has a nice size-to-power ratio and still supports the ubiquitous ARMv7 architecture. the super-cheap Raspberry Pi is all the rage this year, but I went with the BeagleBoard-XM as it had the right combination of ports and features for an upcoming project.
Let’s Go Shopping
- BeagleBoard-XM Rev C (or Beagleboard/BeagleBone) (~$150) (Google for somewhere in-stock, Digi-Key usually…, maybe Amazon…)
- A Quality DC 5V Power Supply, 2 Amp or greater, with Center-positive 5.5 x 2.1mm Barrel Connector ($10) (from Adafruit…) (from Amazon… – this does fit, the tip specs are just listed wrong)
- USB to RS-232 Serial Cable (~$10) (from Amazon…)
- Highly Recommended:
- HDMI to DVI cable ($-6) (from Amazon…) or an S-Video cable
- USB Keyboard/Mouse (the Rii Mini Wireless is a handy device that gets the job done, ~$25)
- USB WiFi Adapter (with certain Realtek chipsets if you want to make it easy on yourself) ($12) (this one from Adafruit works, and this one from Amazon worked for me) (i’ll cover how to setup networking in a future post)
Show Me Your Boot (via Serial)
theoretically you should be able to configure networking ahead of time on the microSD and then remote in with just a network connection and power. you could also connect to a display using HDMI-to-DVI or S-Video cables. however, at some point you may need the most basic “fall-back” way to interact with the board (the serial connection), so i’m covering that here.
TIP: these boards can be a little touchy, so it’s best to connect everything while the power is off, then switch it on. i actually plug into a switched power strip to make it easy to turn on/off since there’s no mechanical switch on the board.
- insert the microSD card that came with your BBXM (it goes label up towards top of the board, and should click in. it presses again to eject – dont yank it)
- attach the USB-to-Serial Cable to the BBXM and to your “host” computer
- attach the power cord to the BBXM, but don’t plug it into the wall yet
at this point most computers with a modern OS will work with the USB-to-serial cable without installing any drivers. verify the cable was detected and see what port it was assigned:
- in Linux (i’m currently using Linux Mint 13 in a virtual machine inside of Windows 8 x64 as my “host” machine):
- open Terminal, type: ls /dev/ttyUSB* and press enter
- you should get back at least one listing, usually “/dev/ttyUSB0” (if you have more than one, you’ll have to disconnect the cable, execute the command again and see which one is now missing)
- if you don’t have a “/dev/ttyUSB#”, Google the lsusb and dmesg commands for more info on troubleshooting
- on Windows:
- open Device Manager (right-click on “My Computer”, choose “Manage”, then click on “Device Manager” in the left-side tree of the window that opens).
- expand the “Ports” section, you should see a “USB-to-Serial” device in the list.
- at the end of the name should be “COM#”, take note of the number.
configure a connection to the BBXM:
- in Linux you can use minicom:
- use your distro’s package tool to find and install “minicom” (in Mint’s GUI: “Menu” > “Administration” > “Software Manager” > search “minicom” > select it in the results > “Install”)
- open Terminal, type: sudo minicom -s and press enter
- goto “Serial Port Setup” and configure:
- Serial Device: /dev/ttyUSB# (replace # with the correct number you found in the steps above)
- Bps/Par/Bits: 115200 8N1
- Hardware Flow Control: Yes
- Software Flow Control: No
- press enter to get back to the main menu
- choose “Save setup as dfl”, then choose “Exit from Minicom”
- apply power to the BBXM
- type: sudo minicom and press enter
- after a second you should see “Initializing Modem”, then a long list of boot status text should scroll by
- (to exit minicom, press CTRL+A then Z, then X)
- in Windows you can use putty:
- download putty.exe from here: http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
- launch putty and configure a new session:
- Connection Type: Serial
- Serial Line: COM# (replace # with the number you noted from Device Manager)
- Speed: 115200
- click “Open” and you should get a console window with a blinking cursor
- apply power to the BBXM
- you should see boot status text scrolling by
- eventually you will get the “Angstrom” ASCII art, and then a “beagleboard login:” prompt. depending on the image that your factory microSD card came with, you may have to wait several minutes the very first time you boot before you get the login prompt – if it looks like it’s hung, give it 5 minutes before you reset.
- the login is: root
- the password is blank, just press enter
Woopidy Doo, I’m Logged In… Now what?
well, some useful commands for a noob like myself:
- uname -a
- reboot (the physical button next to the revision number is also a reset)
- shutdown now
and what else? you could set it up with a webcam and webserver software to stream images (or something more complex), combine it with an Arduino to make a WiFi controlled robot, host your blog on it, use it to scratch that spot on your back that’s hard to reach…
TIP: the first thing to do is not mess with the factory microSD. put it away as your fail-safe backup, and setup another card as your working drive. it’s very likely the factory card is out of date and you’ll want a newer image anyway. i’ll cover the special format of the card and how to get a newer build in my next post.
(awar driver thingyshown above)
Self-Study Time Kids
here are some of my “goto” bookmarks for the BBXM:
- BeagleBoard-XM Manual PDF
- eLinux’s Beagleboard Section
- beagleboard.org Projects
- BeagleBoard Google Groups
- The Ã…ngstrÃ¶m Distribution
- Angstrom BeagleBoard Pre-buit Images
- Arch Linux ARM for BeagleBoard-XM
and some toys:
- Liquidware Embedded Hardware Accessories
- Chalkboard Electronics (touchscreens)
- “Dog House” for the BBXM at SparkFun
stay tuned for posts on preparing a microSD with an updated build, and getting wired & wireless networking configured…