When attempting to run a PS3 Controller script on the GoPiGo3 with DexterOS, I get an error thrown by pygame.event.get()
(the line which causes pygame to pull an update from the controller): pygame.error: video system not initialized
. I checked, and I am calling pygame.init()
(which is the usual culprit of this error). Ok, not a problem, the video library did not initialize properly. Therefore, I added pygame.display.init()
to my code. PyGame then raised a different error: pygame.error: unable to raise a console terminal
. The program is being launched by calling either python ps3Controller.py
or python3 ps3Controller.py
from a terminal session in the browser GUI under http://mygopigo.com/python
. Upon checking the provided files ps3.py
and ps3_gpg_example.py
, and updating them to the current python syntax, I noted that they also use the pygame.event.get()
function call. Based on what I’ve seen, I believe this to be a DexterOS issue with pygame integration (as several years ago, pygame did not need the display
module for pygame.event.get()
to work). Perchance has a workaround been developed, or a different way to launch the program, which allows pygame to function properly?
An additional note: I have considered using Raspbian and loading all of the required modules (and have in the past, though getting proper integration with the GoPiGo3 board is a pain), however, these robots that I have are being used as teaching tools, and therefore the administration would prefer that we stay on DexterOS. Due to this, I would prefer to keep development of demos in DexterOS to maintain all the robots in the proper configuration for classroom use.