i2c_t3.h and audio.h

Status
Not open for further replies.

Sharpie

Member
Hi, My project involves a Teensy 3.2, the Audio Shield, a SSD1306 based display and a DS1881 digital pot chip. Using Wire for I2C I get an I2C NACK error (code 2) from the DS1881. No problems talking to the display.

So I tried Basic_scanner. Basic_scanner finds the DS1881 and if I add code to change the values in the DS1881 that works. Basic_scanner uses i2c_t3.
So just use i2c_t3 I hear you say. But I can't because when I add audio.h there are lots of compile errors as the audio code seems to use Wire.
After looking at the forums I tried the trick of renaming Wire.h and creating a Wire.h with one line #include "i2c_t3". Now I get lots of errors from Wirekinetis. What does Wirekinetis do and is there any way round this problem?

The problem now exceeds my understanding, help please.
 
Hi, My project involves a Teensy 3.2, the Audio Shield, a SSD1306 based display and a DS1881 digital pot chip. Using Wire for I2C I get an I2C NACK error (code 2) from the DS1881. No problems talking to the display.

So I tried Basic_scanner. Basic_scanner finds the DS1881 and if I add code to change the values in the DS1881 that works. Basic_scanner uses i2c_t3.
So just use i2c_t3 I hear you say. But I can't because when I add audio.h there are lots of compile errors as the audio code seems to use Wire.
After looking at the forums I tried the trick of renaming Wire.h and creating a Wire.h with one line #include "i2c_t3". Now I get lots of errors from Wirekinetis. What does Wirekinetis do and is there any way round this problem?

The problem now exceeds my understanding, help please.

Try to find out why it does not work with Wire - that sounds like you have a problem elsewhere. It should work with Wire, too. - Perhaps try without audio library, first? Which I2C Pins do you use? Pull-Up resistors? You know the Audio Shield uses I2c, too?
 
Try to find out why it does not work with Wire - that sounds like you have a problem elsewhere. It should work with Wire, too. - Perhaps try without audio library, first? Which I2C Pins do you use? Pull-Up resistors? You know the Audio Shield uses I2c, too?

The audio shield has pull-up resistors, so you shouldn't need extra ones on the Teensy. You need to use the standard i2c pins 18/A4 and 19/A5.

You would need to clone Audio.h to a different directory with a different name, and change all of the Wire.h's to i2c_t3.h to use i2c_t3.h.
 
i2c_t3 and audio.h [SOLVED]

The audio shield has pull-up resistors, so you shouldn't need extra ones on the Teensy. You need to use the standard i2c pins 18/A4 and 19/A5.

You would need to clone Audio.h to a different directory with a different name, and change all of the Wire.h's to i2c_t3.h to use i2c_t3.h.

Thanks for the suggestions. It turned out to be a wild goose chase. A faulty connection was causing the DS1881 CS line to float though why Wire flagged an error and i2c-t3 didn't still puzzles me.
 
Status
Not open for further replies.
Back
Top