PyEV3 (peeve?)
Posted: 28 Sep 2013, 16:11
Some people have mentioned the idea of running Python on the EV3, but I haven't actually seen it happen. So here you are:
https://www.dropbox.com/s/jmz4wqfbm7lmzqw/ev3.tar.gz
Just extract that somewhere and run the python3.3 binary. I'm using the LejOS image, but you don't need to.
There are currently no drivers, so you can't do anything cool, but I plan to remedy that soon. I will also compile NumPy, for all your mathy A.I. needs
I have not yet decided if I should expose John's C API, or port it... I'm leaning towards exposing because things are young and evolving rapidly, so concentrating effort is preferred in these early days.
HOWTO:
You might try older Python versions, but be advised that cross-compiling them requires more work.
https://www.dropbox.com/s/jmz4wqfbm7lmzqw/ev3.tar.gz
Just extract that somewhere and run the python3.3 binary. I'm using the LejOS image, but you don't need to.
There are currently no drivers, so you can't do anything cool, but I plan to remedy that soon. I will also compile NumPy, for all your mathy A.I. needs
I have not yet decided if I should expose John's C API, or port it... I'm leaning towards exposing because things are young and evolving rapidly, so concentrating effort is preferred in these early days.
HOWTO:
- Get CodesSourcery from 2009q1: https://sourcery.mentor.com/GNUToolchain/release858
- Follow this guide: http://datko.net/2013/05/10/cross-compi ... -angstrom/
Code: Select all
wget https://sourcery.mentor.com/GNUToolchain/package4573/public/arm-none-linux-gnueabi/arm-2009q1-203-arm-none-linux-gnueabi.bin
chmod +x arm-2009q1-203-arm-none-linux-gnueabi.bin
sudo apt-get install openjdk-7-jre
sudo apt-get install lib32 # on 64 bit systems
sudo dpkg-reconfigure -plow dash # installer needs real bash
./arm-2009q1-203-arm-none-linux-gnueabi.bin -i console # swing did not work for me
export PATH="/home/parallels/CodeSourcery/Sourcery_G++_Lite/bin:$PATH"
wget http://www.python.org/ftp/python/3.3.2/Python-3.3.2.tar.bz2
tar -xjf Python-3.3.2.tar.bz2
./configure # first we need to install python3.3 on the host system
make
sudo make altinstall
make clean # remove all the stuff and start the real deal
vim config.site # copy-paste from that link above
CONFIG_SITE=config.site ./configure --build=x86_64-ubuntu-linux --host=arm-none-linux-gnueabi --prefix=/home/parallels/ev3/ --disable-ipv6
make
make install