Unable to Run Python Script Outside Jupyter

Hi Guys,

I have an RFSoC 4x2 board with pynq 3.0.1 and I’m trying to implement a hardware design on the FPGA side, along with its controller on the PS side. So far, I’ve successfully implemented my design in PL and also have a preliminary Python script that controls the PL.

Currently, to run the Python program, I need to connect to Jupyter and then manually run the program through its terminal. As a next step, I want my program to run automatically at each system boot. I discovered that this can be achieved using crontab, but unfortunately, I haven’t been successful in setting this up.

I suspect the root of the problem lies in my inability to run the Python program outside of the Jupyter notebook. For example, I attempted to import ‘pynq’ in a Python library, but that was to no avail. I would greatly appreciate any assistance you could provide in resolving this issue. Thank you!
Screenshot from 2023-06-04 10-17-39

1 Like

You probably need to activate the python pynq virtual environment.

sudo -s
source /usr/local/share/pynq-venv/bin/activate
python your_script.py

2 Likes

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.