Qwiic Shield for Arduino communicating with Arduino Mega

I am trying to connect the Qwiic MP3 Trigger to an Arduino Mega 2560. To do so, I am using the Qwiic Shield for Arduino. When connected to an Arduino Uno, the headers on the shield for SDA and SCL align with the Uno’s SDA and SCL pins, but on a Mega, the SDA and SCL pins are 20 and 21 respectively. These do not align with the shield. Therefore, I am expecting to run jumper wires from the Mega’s pins 20 and 21 to the shield’s SDA and SCL pins.

When I do this and upload the Qwiic MP3 Trigger example sketch, Example1-PlaySong, the serial monitor displays, “Qwiic MP3 failed to respond. Please check wiring and possibly the I2C address. Freezing…”.

Have I wired this incorrectly for use with an Arduino Mega? If so, what is the correct wiring? If not, what am I missing in order to get the Qwiic MP3 Trigger to be recognized?

Image

Products

Qwiic MP3 Trigger [15165] https://www.sparkfun.com/products/15165

Qwiic Shield for Arduino [14352] https://www.sparkfun.com/products/14352

Arduino Mega 2560 R3 [11061] https://www.sparkfun.com/products/11061


Thank you,

Brian

Hi Brian,

The Qwiic Shield uses A4/A5 for SDA and SCL (respectively) to work with legacy Arduinos (think pre-R3). Try re-routing your wires to go from A4/A5 to either the SDA/SCL pins or D20 and D21 and see if that helps. As a side note, we are working on a revision of that board that should be released soon that fixes this problem so it works with all R3 footprints with those dedicated SDA/SCL pins.

I have removed the Qwiic Shield and replaced it with a Qwiic Adapter wiring the Mega’s pin 20 and 21 to the adapter’s SDA and SCL respectively. When I upload the Example 1-PlaySong sketch, the serial monitor now displays, “All done!” I think that confirms the problem lies with the Qwiic Shield. Rather than pondering how to fix it or work around it, I’ll move forward using the Qwiic Adapter.

Thank you for your time and help.

Product Change

Qwiic Adapter product [14495] https://www.sparkfun.com/products/14495


Thank you,

Brian