If talking to an AVR from the Raspberry Pi and you see that error message, read this:
http://elinux.org/BCM2835_datasheet_err ... stretching
WebIDE Pi I2C "Error accessing..."
Moderators: adafruit_support_bill, adafruit
Forum rules
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/
-
- Posts: 25
- Joined: Sun Feb 10, 2013 7:10 am
WebIDE Pi I2C "Error accessing..."
Last edited by teachop on Mon Feb 18, 2013 6:11 pm, edited 1 time in total.
-
- Posts: 25
- Joined: Sun Feb 10, 2013 7:10 am
Re: WebIDE Pi I2C "Error accessing..."
See...
Last edited by teachop on Mon Feb 18, 2013 6:12 pm, edited 2 times in total.
-
- Posts: 25
- Joined: Sun Feb 10, 2013 7:10 am
Re: WebIDE Pi I2C "Error accessing..."
Below...
Last edited by teachop on Mon Feb 18, 2013 6:13 pm, edited 2 times in total.
-
- Posts: 25
- Joined: Sun Feb 10, 2013 7:10 am
Re: WebIDE Pi I2C "Error accessing..."
Even though the problem is actually with the Pi I2C hardware, it can be worked around. This is a changed to the slave CPU, not the Pi. Putting a time delay in the Wire library twi.c allows talking to Arduino-likes from the Raspberry Pi on I2C. My atmega328p CPU is @ 8 MHz so perhaps this needs to be tweaked for 16 MHz cases (normal Arduino). Anyway, this bandaid completely stopped the problem (twi.c, in SIGNAL(TWI_vect) routine):
Code: Select all
// Slave Receiver
case TW_SR_SLA_ACK: // addressed, returned ack
case TW_SR_GCALL_ACK: // addressed generally, returned ack
delayMicroseconds(3);
Forum rules
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/