Showing results for 
Show  only  | Search instead for 
Did you mean: 
Registered: ‎09-18-2019

Running Python Script on Zynq-7000

Hello all,

I am working with a ZC706 eval board and I am trying to run a python script that should convert incoming data packets from ethernet into peek and poke commands on the processor.  I am using Petalinux2018.3 and ubuntu 16.04.

I have the python scripts written but I am unclear on how to get the scripts onto the Zynq board and then to execute them once there.  I have already enabled python and the necessary packages via:

petalinux-config -c rootfs

Any help is greatly appreciated,

Thank you

0 Kudos
2 Replies
Registered: ‎02-07-2018

HI @stephen.lindeman 

I think if you have a phython script on Sdcard, then you can simply mount your sdcard & copy to /home/root folder Then run suing below commands.

1. mount /dev/mmcblk0p1 /mnt/.

2.cp -rf /mnt/ .

3. chmod 777

4. phython 


Thanks & regards


Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.
Give Kudos to a post which you think is helpful and reply oriented.


0 Kudos
Xilinx Employee
Xilinx Employee
Registered: ‎09-12-2007

Enable the python:

petalinux-config -c rootfs

  • Filesystem Packages → devel →python
    • python-mmap
    • python-shell
    • python-io
    • python-distutils
    • python-pydoc


If you want to do peek and poke, you will need to do:

petalinux-config -c kernel

  • kernel hacking → [] Filter access to /dev/mem


You can create a recipe to place your python files in the sysroot, or .. just copy to the SD card

and mount the SD card and execute from there.



0 Kudos