KurtE
Senior Member+
Update: I just created a pull request for Wire library that supports the additional IO pins. I tested on an Adafruit BNO055 Where I tried 4 different combinations for SCL, SDA
(16, 17), (19, 18), (33, 34), (7, 8)
Test program:
(16, 17), (19, 18), (33, 34), (7, 8)
Test program:
Code:
#include <Wire.h>
#include <Adafruit_Sensor.h>
#include <Adafruit_BNO055.h>
#include <utility/imumaths.h>
Adafruit_BNO055 bno = Adafruit_BNO055(55);
void setup(void)
{
uint32_t time_start = millis();
while (!Serial && ((millis()-time_start) < 4000)) ;
Serial.begin(9600);
Serial.println("Orientation Sensor Test"); Serial.println("");
/* Initialise the sensor */
// On Test board
// SCL 19, 16, 33, 7
// SDA 18, 17, 34, 8
Wire.setSCL(33);
Wire.setSDA(34);
if(!bno.begin())
{
/* There was a problem detecting the BNO055 ... check your connections */
Serial.print("Ooops, no BNO055 detected ... Check your wiring or I2C ADDR!");
while(1);
}
delay(1000);
bno.setExtCrystalUse(true);
Serial.println("Setup Complete");
}
void loop(void)
{
/* Get a new sensor event */
sensors_event_t event;
bno.getEvent(&event);
/* Display the floating point data */
Serial.print("X: ");
Serial.print(event.orientation.x, 4);
Serial.print("\tY: ");
Serial.print(event.orientation.y, 4);
Serial.print("\tZ: ");
Serial.print(event.orientation.z, 4);
Serial.println("");
delay(100);
}