RedPitaya / RedPitaya

Red Pitaya Ecosystem and Applications
Other
484 stars 631 forks source link

Unable to run python programs in red pitaya #125

Closed vaishsuri closed 1 year ago

vaishsuri commented 7 years ago

I am new to Red Pitaya and Python. I have an issue. This might seem really silly. But since I am new to both, it would be really helpful if someone could help. If i establish the root connection, start the SCPI server using the link "systemctl start redpitaya_scpi &" and then run the program, sometimes it works. Otherwise if i load the scpi module normally and run the program, it keeps displaying an error For example, the blink tutorial: "rp_s = scpi.scpi(sys.argv(2)) list index out of range. " Pls do help!

pefu commented 7 years ago

vaishsuri wrote 17.08.2017 09:54:

I am new to Red Pitaya and Python. I have an issue. This might seem really silly. But since I am new to both, it would be really helpful if someone could help. If i establish the root connection, start the SCPI server using the link "systemctl start redpitaya_scpi &" and then run the program, sometimes it works. Otherwise if i load the scpi module normally and run the program, it keeps displaying an error For example, the blink tutorial: "rp_s = scpi.scpi(sys.argv(2)) list index out of range. " Pls do help!

In Python "sys" is a module and "sys.argv" is a list (or array if you prefer) containing the command line arguments given to this particular Python program from the shell. The error message "list index out of range." in this context means that the called programm did not receive the expected number of at least two command line arguments.

Best Regards, Peter Funk -- Peter Funk, home: ✉Oldenburger Str.86, D-27777 Ganderkesee mobile:+49-179-640-8878 ☎phone:+49-421-20419-0 http://www.artcom-gmbh.de/ office: ArtCom GmbH, ✉Haferwende 2, D-28357 Bremen, Germany