Python PYTHONPATH?


#1

I installed the Dexter Wheezy, did a git of BrickPi and I had to copy BrickPi.py into the samples folder to get it to work. What is the recommended Python configuration to use the BrickPi?

Also the lego motor sensor sample works going forward for 3 seconds, but as soon as the motors start to go backwards, the Pi reboots!


#2

JimW,you’re right, to make the python programs work, you have to move a copy of the BrickPi.py into the folder you’re executing on. I’ve added a note on the readme to try to make that more obvious. Thanks for pointing that out.

With our LEGO motor sample, are you using a 9V battery to power it? Is there a way you can try with a fresh 9V battery (right out of the packaging) or a 6XAA adapter? I suspect, from what you’ve put up here, that the battery might be worn down or unable to deliver the amperage needed to change direction of the motors. When the 5V rail drops low, the RPi will turn off. This could be what’s resetting it.

I’m curious if you change the battery or use a new power supply, if it improves performance at all.


#3

I’m using the 6xAA adapter with brand new alkaline batteries. I did bump up the motor speed to the max since the samples were not. You may try that and see if you can reproduce it.