Python on the Red Pitaya board

Discussions about active development projects
Pierre C
Posts: 2
Joined: Mon Dec 01, 2014 7:09 pm

Python on the Red Pitaya board

Post by Pierre C » Thu Jun 25, 2015 4:30 pm

Hi,

I have successfully cross-compiled Python for the Red Pitaya board and I wrote a small library that can be used to access directly the register of the board. This library can run on the Red Pitaya board or a remote computer.

An object oriented interface to the different applications (scope, PID, analog mixed signals, ...) is provided. This interface is implemented using Python properties and can quickly be extended to your own application.

It is important to notice that Python runs on the board : one can run an ipython shell through SSH and directly interact with the board or one can run scripts. Using libraries (such as numpy), one can easily perform data analysis on the board before sending data through the network.

More details can be found on https://github.com/clade/RedPitaya/tree/master/python

Pierre

geggor
Posts: 3
Joined: Mon Jul 20, 2015 8:15 am

Re: Python on the Red Pitaya board

Post by geggor » Mon Jul 20, 2015 8:28 am

Dear Pierre,

thank you very much for this work! This makes writing custom control programs running on the RP much easier for me.
Do you have plans for the future of your project? I am dreaming of an IPython notebook server running on the RP.

thanks
Gregor

Pierre C
Posts: 2
Joined: Mon Dec 01, 2014 7:09 pm

Re: Python on the Red Pitaya board

Post by Pierre C » Tue Jul 21, 2015 2:36 pm

Hi Gregor,

I don't have any plans for the future of this project. If you want to run the notebook you need to install a bunch of python package. If youwant the pylab mode, then you need also to cross-install matplotlib. This probly tricky.

Pierre

pavel
Posts: 790
Joined: Sat May 23, 2015 5:22 pm

Re: Python on the Red Pitaya board

Post by pavel » Wed Jul 22, 2015 8:56 am

Hi Gregor,

You can try to boot your Red Pitaya board using the Debian based SD card image:

http://pavel-demin.github.io/red-pitaya ... ecosystem/

and then you can install any of the Python related packages provided by the Debian distribution:

https://packages.debian.org/jessie/python/

Cheers,

Pavel

geggor
Posts: 3
Joined: Mon Jul 20, 2015 8:15 am

Re: Python on the Red Pitaya board

Post by geggor » Wed Jul 22, 2015 8:04 pm

Dear Pavel,

thank you for providing a Debian image for the RedPitaya, this is a very complete and powerful environment, I will give it try - after downloading and writing to the SD card has finished ...

Gregor

newkew
Posts: 5
Joined: Thu Apr 02, 2015 1:26 pm

Re: Python on the Red Pitaya board

Post by newkew » Fri Aug 28, 2015 1:39 pm

Dear all,
I'm a beginner in REDPITAYA and Python
I used redpitaya+python distribution with succes. It s a perfect tool for my application. I tested it with eclipse on windows PC, now I would like to export py scripts directly on redpitaya board. But ...
How could I install other python package on repitaya board ?
I tried to install pip on REDPITAYA with get-pip.py without succes
I tried to install debian distribution with SD image supplied by Pavel http://pavel-demin.github.io/red-pitaya ... ecosystem/ but I never succeed in connecting REDPITAYA !

regards
Kewin

pavel
Posts: 790
Joined: Sat May 23, 2015 5:22 pm

Re: Python on the Red Pitaya board

Post by pavel » Fri Aug 28, 2015 4:45 pm

Dear Kewin,

May be I could help you to solve your problem with the Debian based SD card image. Could you please tell me how you copy the image to a SD card? Is there anything that appears on the serial console when Red Pitaya boots with this image?

Best regards,

Pavel

newkew
Posts: 5
Joined: Thu Apr 02, 2015 1:26 pm

Re: Python on the Red Pitaya board

Post by newkew » Sat Aug 29, 2015 10:04 pm

Pavel,
I writed image with Win32DiskImager
I tried to connect redpitaya with putty like i did it before

Kewin

pavel
Posts: 790
Joined: Sat May 23, 2015 5:22 pm

Re: Python on the Red Pitaya board

Post by pavel » Sat Aug 29, 2015 11:36 pm

Kewin,

It's possible that Red Pitaya gets different IP addresses when it boots from the original SD image and from the Debian based one.

Have you tried to connect to the serial console as described at the following link?
http://wiki.redpitaya.com/index.php?tit ... connection

This way, you'll see if the Debian based system boots and if it boots you'll be able to find the IP address using the ifconfig command.

Pavel

smwright
Posts: 4
Joined: Tue Jun 23, 2015 8:26 pm

Re: Python on the Red Pitaya board

Post by smwright » Mon Aug 31, 2015 4:55 am

I'm having similar difficulties. Watching the pitaya boot from the serial port with my original (working) SD image, and then typing ifconfig, the pitaya reports:
init addr: 192.168.1.100 Bcast: 192.168.1.255 Mask 255.255.255.0

When I watch Pavel's image boot, then type ifconfig after logging into root, the pitaya reports nothing. The corresponding line with the internet address is simply not there.

During boot it does say "Failed to start LSB: DHCP server. " New at this, no idea if that is important.

Steve

Post Reply
jadalnie klasyczne ekskluzywne meble wypoczynkowe do salonu ekskluzywne meble tapicerowane ekskluzywne meble do sypialni ekskluzywne meble włoskie

Who is online

Users browsing this forum: No registered users and 28 guests