Tsunami Super Wav Qwiic communication not working

I cannot get Qwiic/I2C communication between arduino mega and tsunami super wav card.

The tsunami card works without a problem using manual triggers.

The arduino mega card works without a problem talking to a RTC board indicating the I2C implementation is OK.

I have tried connecting tsunami through the RTC board (it has pass-thru I2C pins) and also tried connecting the tsunami directly to the arduino board - no difference.

The tsunami is connected through a bi-directional level shifter board, and I confirmed that a negative-going 3.3V logic signal (burst) from the arduino is present at the Qwiic connector using an oscilloscope. I have checked I2C clock and data are connected correctly (and I tried swapping the signals just in case). I am using the default 0x13 address.

I am using your Tsunami Qwiic Arduino Library and your Example Code. The code fails the tsunami.begin() statement. It returns error code 1. It is compiled using Arduino IDE v2.04 and the sketch generates no compile errors. I looked at the tsunami library .h and .cpp code and it seems to be all there.

The tsunami card has the original firmware version, I have not changed it. Is there another firmware version to enable the Qwiic port?

The tsunami.ini file includes #tsum (I run mono mode) and #baud 9600 to match the PC / arduino baud rates.

The arduino code I used to test the tsunami communication:

#include “SparkFun_Tsunami_Qwiic.h”

#include “uEEPROMLib.h”

#include “Arduino.h”

#include “RTClib.h”

#include “Wire.h”

TsunamiQwiic tsunami;

RTC_DS1307 rtc;

int onoffled = 13; // On board yellow LED - using for debug

int relaypinnumber;

char daysOfTheWeek[7][12] = { “Sunday”, “Monday”, “Tuesday”, “Wednesday”, “Thursday”, “Friday”, “Saturday” };

// Initialize hardware ports and environment

void setup() {

Serial.begin(9600);

Wire.begin();

tsunami.begin(); // initialize Tsunami card

Serial.print("Tsunami return code: ");

Serial.println(tsunami.begin());

delay(2000); //Let console routine run

// Check to see if Tsunami Qwiic is present on the bus

// Note, here we are calling begin() with no arguments = defaults (address:0x13, I2C-port:Wire)

if (tsunami.begin() == false) {

Serial.println(“Tsunami Qwiic failed to respond. Please check wiring and possibly the I2C address. Freezing…”);

while (1)

;

};

I talked to Robertsonics about the situation, and they indicated it must be something with the SparkFun application.

I do not know how to proceed from here. Need some help.

Thanks,

-Greg

How is it wired? You may need to disable the i2c pullup resistors on the tsunami (backside of board, cut trace between pads) and/or ensure you’re using pins 20/21 on the mega…likely need to declare which i2c its using as well (mega has 2 i2c buses)

Thanks for the reply!

The logic levels at the Tsunami Qwiic connector are 3.3V (high) and 0.1V (low) from the bi-directional level shifter, so I think the resistors are not in play here.

I tried cutting the traces anyway between the 3 pads on the backside of the board, but this seems to cut the 3.3V supply to the Qwiic connector. Is this right? In this case that removes power feeding the level shifter board so now I get no logic signal to the tsunami Qwiic port.

What is the function of the two pads next to the 3 shorted I2C pads marked 3.3V Qwiic? One is at 3.3V and the other at 0V. On the 3 (previously shorted) I2C pads, the two outside pads are at 0V and the center pad is at 3.3V - I assume this is the 3.3V feed to the two pull-up resistors.

I am using pins 1 & 2 on the arduino mega. When the mega went to rev 3, parallel I2C pins were brought to the J6 connector - shorted to the respective pins 20 & 21. This should not be an issue. I am not aware of any declaration needed in the wire.h library (other than the address of the peripheral). The RTC peripheral that uses the same I2C port works fine. I added an I2C monitor routine to the sketch and it correctly detects the RTC and E2Memory I2C addresses but not the tsunami’s address.

One change that I missed above.

I routed a 3.3V supply wire from the tsunami to the level shifter to get it working again.

The tsunami.begin() line continues to return error 1, BUT the I2C monitor routing now shows 0x0D in the list of active addresses! Not the right address, but it is seeing something new.

The logic levels at the Qwiic connector are 3.3V/0.0V - a slight improvement in the logic low level.

This is very strange.

I changed the tsunami library default address to 0x0D that I detected with the I2C monitor.

#define TSUNAMI_QWIIC_DEFAULT_ADDR 0x0D // 7-bit unshifted default I2C Address

IT WORKS !?!?!?

The tsunami board uses the default address 0x13 (19 decimal as shown in the latest Tsunami Configurator).

There is something wrong somewhere.

Nobody Move! heh