As soon as we finish shipping I'll have a proper guide with a library for the Pi so everyone can start to really play with this. Thanks for sharing!!
-Kevin
How to.... interface the RPi with spirit board
-
- Posts: 3
- Joined: Sat Oct 14, 2017 5:40 pm [phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable
Re: How to.... interface the RPi with spirit board
Thanks for your share, mgodiya
I had tried today, sometime I can send buzzer command from Python, but more of time I saw IOError message during the 1st I2C command, have you saw that also? Any idea?
Traceback (most recent call last):
File "sr_python_test.py", line 49, in <module>
writeByte(serv_values[x%3],reg_serv_values[x%3])
File "sr_python_test.py", line 17, in writeByte
bus.write_byte_data(address,reg_val,value)
IOError: [Errno 121] Remote I/O error
I had tried today, sometime I can send buzzer command from Python, but more of time I saw IOError message during the 1st I2C command, have you saw that also? Any idea?
Traceback (most recent call last):
File "sr_python_test.py", line 49, in <module>
writeByte(serv_values[x%3],reg_serv_values[x%3])
File "sr_python_test.py", line 17, in writeByte
bus.write_byte_data(address,reg_val,value)
IOError: [Errno 121] Remote I/O error
-
- Posts: 180
- Joined: Tue Jul 28, 2015 12:56 am [phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable
Re: How to.... interface the RPi with spirit board
The Pi's I2C hardware has some bugs. This is apparently related to the chip used on the Pi and it caused all kinds of problems and hassles getting things to work correctly. For most of the Pi to Pic I2C communications, we need to add a slight delay (I think it's a few microseconds if I remember correctly) before the PIC responds back. There is a function in the library we wrote to deal with this and only needs to be called once. This together with the rest of the pre-written functions in our Python library makes all the coms real easy. I'm going to get that posted with some instructions soon. Almost done shipping these guys. That's the big focus right now then we'll have the Pi stuff posted. Hang in there. It should work smoothly once that's posted.
Thanks!
-Kevin
Thanks!
-Kevin
-
- Posts: 5
- Joined: Tue Oct 31, 2017 3:45 am [phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable
Re: How to.... interface the RPi with spirit board
Thanks for the details Kevin, we are patiently waiting for your python library.
Meanwhile odinshen, you could try the following to make the above script work.
1. Make sure you are following the steps above correctly despite my poor formatting
2. Make sure I2C and SPI are enabled on the Pi
3. As Kevin mentioned, try uncommenting the 3 lines in the script (it will give the pi more time to respond)
let me know how you make out.
Sorry for the late reply.
PS:I am pretty sure your problem can be solved using 1st or/and 2nd solutions.
Meanwhile odinshen, you could try the following to make the above script work.
1. Make sure you are following the steps above correctly despite my poor formatting
2. Make sure I2C and SPI are enabled on the Pi
3. As Kevin mentioned, try uncommenting the 3 lines in the script (it will give the pi more time to respond)
let me know how you make out.
Sorry for the late reply.
PS:I am pretty sure your problem can be solved using 1st or/and 2nd solutions.
- Astroghost
- Posts: 9
- Joined: Tue Oct 24, 2017 10:35 pm [phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable
Re: How to.... interface the RPi with spirit board
Hi all,
Have a special robotic day in ower Fablab tomorrow , , i was expecting that we get all information from Kevin to control the robot by BLE and remote controller , but nothing come at this day.
Bad news that i would not be able to present the spirit rover
Do someone know how to send data to serial via BLE , i've actually programmed the HC-06 BLE module to work at 57600 and connecting it with my smartphone , but spirit rover don"t received the command i send.
Have a special robotic day in ower Fablab tomorrow , , i was expecting that we get all information from Kevin to control the robot by BLE and remote controller , but nothing come at this day.
Bad news that i would not be able to present the spirit rover
Do someone know how to send data to serial via BLE , i've actually programmed the HC-06 BLE module to work at 57600 and connecting it with my smartphone , but spirit rover don"t received the command i send.
BERNIER François
FabLab Manager at L.A.B. Aix en Provence -FRANCE
http://astronomie-astrophotographie.fr
FabLab Manager at L.A.B. Aix en Provence -FRANCE
http://astronomie-astrophotographie.fr
Re: How to.... interface the RPi with spirit board
Does anyone have a list of what's available at what addresses on the i2c in addition to what was in the python test code above? A handy reference would be nice...
----------
Erik S. Bailey
Entry, Descent, and Landing Aerospace Engineer
Maker, and Musician
SpiritRover Kickstarter Backer #460
Erik S. Bailey
Entry, Descent, and Landing Aerospace Engineer
Maker, and Musician
SpiritRover Kickstarter Backer #460
Re: How to.... interface the RPi with spirit board
Also, what frequency is the i2c bus running at? It seems to be higher than 100kHz based on what I'm seeing with pigpiod and piscope, which can only sample the gpio at 1 microsecond... I'm also seeing 20Hz activity on the I2C pins (2 and 3) on the RasPI...
----------
Erik S. Bailey
Entry, Descent, and Landing Aerospace Engineer
Maker, and Musician
SpiritRover Kickstarter Backer #460
Erik S. Bailey
Entry, Descent, and Landing Aerospace Engineer
Maker, and Musician
SpiritRover Kickstarter Backer #460
Re: How to.... interface the RPi with spirit board
----------
Erik S. Bailey
Entry, Descent, and Landing Aerospace Engineer
Maker, and Musician
SpiritRover Kickstarter Backer #460
Erik S. Bailey
Entry, Descent, and Landing Aerospace Engineer
Maker, and Musician
SpiritRover Kickstarter Backer #460
-
- Posts: 75
- Joined: Fri Jan 26, 2018 5:03 pm [phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable
Re: How to.... interface the RPi with spirit board
This is very cool. So you're using I2C to talk directly to the PIC processor?
I was poking around the Arduino sketch, and it looks like you can probably use SPI to go from the Pi to the Arduino, and then use the existing Arduino libraries. You could probably do all the code for easing/simultaneous moves on the Arduino, I think.
It looks like the missing piece of the puzzle is just some libraries on the Pi side to send commands over SPI.
I was poking around the Arduino sketch, and it looks like you can probably use SPI to go from the Pi to the Arduino, and then use the existing Arduino libraries. You could probably do all the code for easing/simultaneous moves on the Arduino, I think.
It looks like the missing piece of the puzzle is just some libraries on the Pi side to send commands over SPI.
Who is online
Users browsing this forum: No registered users and 12 guests