Problems with TSL25911

Post here about your Arduino projects, get help - for Adafruit customers!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
the_programmer
 
Posts: 2
Joined: Sat May 02, 2015 8:22 am

Problems with TSL25911

Post by the_programmer »

Recently I bought a TSL25911 Lux sensor (through a international reseller). Somehow I can't get the i2c communication working.

So my setup:
A Mini Arduino Pro (3v3 8Mhz)
A TSL25911 Lux sensor
A bus pirate V3 (debugging)

The connections are as follows:

Code: Select all

[Arduino] [TSL25911] [Bus pirate]
[A4]------[SDA]------[MOSI]
[A5]------[SCL]------[CLK]
[VCC]-----[Vin]------[VPU]
[GND]-----[GND]------[GND]
The VPU line on the bus pirate is intended to supply the pull-up resistors or the bus pirate with some power. These resistors can be switched on and of but are at the moment switched on. A additional sample on how the bus pirate can be used can be found here: http://hackaday.com/2009/06/26/parts-i2 ... r-pcf8563/
My code can be found here: https://codebender.cc/sketch:108472

So on to my problem:
With the default sketch and library all I get is the following: "Starting Adafruit TSL2591 Test!" and here the output stops..

If I use the sniffer in the bus pirate I get the following output:
[0x52-][0x53-]
Translated:

Code: Select all

[    Start condition
0x52 Address 0x29 Write
-    NACK
]    Stop condition
[    Start condition
0x53 Address 0x29 Read
-    NACK
]    Stop condition
So I started poking around with the bus pirate to see what addresses are alive. (i2c macro 1 can be used for this). The output is that there is a device at address 0x72(0x39 W) and 0x73(0x39 R). Thus the address found is 0x39. So if I switch my address to 0x39 I do get some output.

Code: Select all

Starting Adafruit TSL2591 Test!
$0 = 0x0
$1 = 0x2
$2 = 0x0
$3 = 0x0
$4 = 0x0
$5 = 0x0
$6 = 0x0
$7 = 0x0
$8 = 0xC2
$9 = 0x29
$A = 0x50
$B = 0x4
$C = 0x0
$D = 0x0
$E = 0x0
$F = 0x0
$10 = 0x0
$11 = 0x2
$12 = 0x0
$13 = 0x0
$14 = 0x0
$15 = 0x0
$16 = 0x0
$17 = 0x0
$18 = 0xC2
$19 = 0x39
$1A = 0x50
$1B = 0x4
$1C = 0x0
$1D = 0x0
$1E = 0x0
$1F = 0x0
Err
No sensor found ... check your wiring?
On the sniffer of the bus pirate I see a lot of traffic. So the communication part seems to be working, however the TSL25911 doesn't respond to the ID request (0x12) with the correct data (0x50)

Any suggestions on how to fix this?

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Problems with TSL25911

Post by adafruit_support_rick »

Please post clear, detailed pictures of both sides of the module, showing your soldering and wiring

User avatar
the_programmer
 
Posts: 2
Joined: Sat May 02, 2015 8:22 am

Re: Problems with TSL25911

Post by the_programmer »

As requested the pictures:
ImageTSL2561 FrontImageTSL2561 BackImageWiring

While looking at the pictures I just made I realized that I was incredibly stupid and identified the sensor as the wrong one.

I have a TSL2561 and not a TSL25911.

So now I grabbed the correct library and it works.

Thanks for the support but I need to look closer next time.

p.s. There is a small typo in the sample for the TSL2591
Line 1 reads

Code: Select all

/* TSL25911 Digital Light Sensor */
instead of

Code: Select all

/* TSL2591 Digital Light Sensor */

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Problems with TSL25911

Post by adafruit_support_rick »

Glad t hear you figured it out!

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino”