Programming python to make BeagleBone on board LED'd blink
2012-05-01 09:56
344 查看
I'm on a Ubuntu Linux 11.10 so I used the following command:
screen /dev/`dmesg | grep FTDI | grep "now attached to" | tail -n 1 | awk '{ print $NF }'` 115200
Your terminal should show a Logo of Angstrom and then a login screen. Just type in "root" and press enter.
Now we should see a screen that displays this:
root@beaglebone:
So lets download our Blinking python script by typing in the following
wget http://pastebin.com/raw.php?i=US7UaD31
[wait for the file to download]
then we want to rename the file from raw.php?i=US7UaD31 to an easier to type name so lets to the following to rename the file
mv raw.php?i=US7UaD31 led-blink.py
now we have the filename renamed to what we want lets run it! (The fun part)
python led-blink.py
The python should be running infitely blinking on and off on the led beaglebone onboard LEDs
Thats it!!
To stop the python script from running any more go to the BeagleBone terminal and press Ctrl+C to stop the program. If its gridlocked you can do Ctrl+A then press Z
screen /dev/`dmesg | grep FTDI | grep "now attached to" | tail -n 1 | awk '{ print $NF }'` 115200
Your terminal should show a Logo of Angstrom and then a login screen. Just type in "root" and press enter.
Now we should see a screen that displays this:
root@beaglebone:
So lets download our Blinking python script by typing in the following
wget http://pastebin.com/raw.php?i=US7UaD31
[wait for the file to download]
then we want to rename the file from raw.php?i=US7UaD31 to an easier to type name so lets to the following to rename the file
mv raw.php?i=US7UaD31 led-blink.py
now we have the filename renamed to what we want lets run it! (The fun part)
python led-blink.py
The python should be running infitely blinking on and off on the led beaglebone onboard LEDs
Thats it!!
To stop the python script from running any more go to the BeagleBone terminal and press Ctrl+C to stop the program. If its gridlocked you can do Ctrl+A then press Z
相关文章推荐
- How to install RXTX on Beaglebone board
- error: No rule to make target `c:/Users/Administrator/Desktop/LED_mainWindow/pcb_view.ui', needed by
- python manag.py syncdb不能成功创建表 Run 'manage.py makemigrations' to make new migrations,
- 运行python manage.py syncdb时出现“cannot connect to MySQL server on 'localhost'”的解决方法
- Openwrt编译python3时出现错误:No rule to make target `package//host/compile'
- linux内核编译中的各种问题:No rule to make target `menuconfig'&&Unable to find the Ncurses libraries
- 编译内核是出现No rule to make target `firmware/sd8686_helper.bin', 错误的解决
- Nios II编译出错:make: *** No rule to make target `e:/nios ', needed by `/cygdrive/e/nios/Debug/system_de
- Error using fmincon (line 816), Hessian option set to 'on' but no Hessian function provided in optio
- Robbie's Notes on File System Security in Linux (and comparison to Windows NT)
- Unable to start gdbserver on port '63411' Can't open socket: Permission denied.的解决办法
- I'll teach you to make a fool out of me
- beaglebone 开发(PyBBIO is a Python library for hardware IO support on the TI Beaglebone)
- How to enable time stamps for logs in 'dmesg' on Gaia and SecurePlatform
- error:undefined reference to `coloured_LED_init'
- 关于make: *** No rule to make target `clean'. Stop.的解决
- MacPorts svn Unable to execute port: can't read "build.cmd": Failed to locate 'make' in path:
- Functional Programming HOWTO(Python It's great)
- Failed to install *.apk on device 'emulator-5554': timeout': EOF
- Uncaught Error: cannot call methods on dialog prior to initialization; attempted to call method 'clo