RasPiArduino icon indicating copy to clipboard operation
RasPiArduino copied to clipboard

I2C communication with RasPiArduino and SPI

Open craig42 opened this issue 8 years ago • 4 comments
trafficstars

Hi,

I have a Raspberry 3 and I use RasPiArduino for I2C communication with this gas sensor : http://wiki.seeed.cc/Grove-Multichannel_Gas_Sensor/

And I use this LoRa hardware which communicates in SPI which use this library : https://github.com/Snootlab/lora_chisterapi/blob/master/lib/radiohead/RH_RF95.cpp

When I start RasPiArduino, LoRa hardware can't send and receive data so I think RaspiArduino use SPI...

Is it possible to disable SPI connection in RasPiArduino ?

craig42 avatar Sep 13 '17 09:09 craig42

it uses interrupts and maybe that is the issue ;) RPI does not really have interrupt vectors

me-no-dev avatar Sep 13 '17 09:09 me-no-dev

So, what can I do ? It's not possible to run the two program at the same time ?

craig42 avatar Sep 13 '17 09:09 craig42

ahh wait... I missread your initial post ;) you access the SPI through another APP and I2C through Arduino. Would it work if you first start Arduino and then RF95?

me-no-dev avatar Sep 13 '17 15:09 me-no-dev

No, I tested it. But now, I think RasPiArduino is not the problem. I test LoRa Hardware HAT with a simple LED. The LED is controlled by python program, and when I launch LoRa program, I have an error message "Init failed"

craig42 avatar Sep 18 '17 15:09 craig42