I2C between two RedBoard Artemis

Hi,

For the life of me, I cannot get two Artemis RedBoard to talk to each other over I2C and I don’t understand why.

I have stripped everything from the boards the only connections I have are (top right of the board, near the USBC connector)

Controller Target


SCL <------------------> SCL

SDA <------------------> SDA

GND <------------------> GND

I uploaded the code from the Arduino doc

Controller:

// Wire Controller Reader
// by Nicholas Zambetti [http://www.zambetti.com](http://www.zambetti.com)

// Demonstrates use of the Wire library
// Reads data from an I2C/TWI peripheral device
// Refer to the "Wire Peripheral Sender" example for use with this

// Created 29 March 2006

// This example code is in the public domain.


#include <Wire.h>

void setup() {
  Wire.begin();        // join i2c bus (address optional for master)
  Serial.begin(9600);  // start serial for output
}

void loop() {
  Wire.requestFrom(8, 6);    // request 6 bytes from peripheral device #8

  while (Wire.available()) { // peripheral may send less than requested
    char c = Wire.read(); // receive a byte as character
    Serial.print(c);         // print the character
  }

  delay(500);
}

Target:

// Wire Peripheral Sender
// by Nicholas Zambetti [http://www.zambetti.com](http://www.zambetti.com)

// Demonstrates use of the Wire library
// Sends data as an I2C/TWI peripheral device
// Refer to the "Wire Master Reader" example for use with this

// Created 29 March 2006

// This example code is in the public domain.


#include <Wire.h>

void setup() {
  Wire.begin(8);                // join i2c bus with address #8
  Wire.onRequest(requestEvent); // register event
}

void loop() {
  delay(100);
}

// function that executes whenever data is requested by master
// this function is registered as an event, see setup()
void requestEvent() {
  Wire.write("hello "); // respond with message of 6 bytes
  // as expected by master
}

I am not seeing anything on the serial terminal. These are the signals that I see on the I2C bus (blue is SCL, yellow is SDA):

I have tested the exact same code between two esp32 and everything works as expected.

I don’t understand what I am doing wrong.

BTW, I also tried using a QWIIC cable between the two artemis, no luck. The Qwiic cable works between the two ESP32.

The Sparkfun Artemis Wire library does NOT support slave(peripheral) mode. It can only act as a Master (controller).

It is half-documented in the README on https://github.com/sparkfun/Arduino_Apollo3, but it is 100% sure as there is NO code to handle it.

You can connect an ESP32 as a peripheral to an Artemis running as a controller.

I see, thank you for the link. I had overlooked that part