Qwiic Human Presence Sensor (AK9753) no data collected

I had this posted at the bottom of another chain in the forum, wasn’t getting any views so I figured I’d make it a topic, hoping to get some responses before the weekend.

I’m working on a python version of the driver for the human presence sensor. Got the whole thing written. Just ported the c++ one provided with some guidance from a few other sensors with python code already created from them. Seems to work. I can read and write to to all the configuration registers etc. I can read the high and low order data registers but they are always 0. Its like the chip isn’t really on - its not collecting data.

Its in continuos mode (100). The data ready flags (DR and DRDY) never change to 1.

Anybody got any ideas what to look at?

I’m reading the high and low bytes separeately using readByte from the qwiic_i2c module. All the IR registers and temperature value bytes come back as 0. I know I’ve got to put the bytes together and deal with two’s complement, but with all 0s not sure how any of that could be an issue. I’m also reading the dummy register to let it know it can refill data.

It just seems like I’m missing something that says “GO”. I’m doing all the initial setup the c++ driver does. Wondering if its also missing something.

Thanks.

Just to add. I’ve tried various ways of reading the registers. The readBlock and readWord and then a couple ways I found in other modules for other sensors. Those either didn’t work at all or got 0s also.

If you suspect there might be something missing from your code, I would advise cross checking our Qwiic_Py Github Repo: https://github.com/sparkfun/Qwiic_Py/tr … ic/drivers.

Yes. I’ve been all through that looking for hints. I’ve found three c++ drivers for it at various places. I’m doing all the initialization I find in them (they were all the same pretty much) I’m starting to wonder if I have a bad chip. Not sure what else to do. I get values as appropriate on all the non-data registers. I can reset the chip successfully. It just never collects data - never sets the data ready bit or has any data in the temperature or IR registers.

Got it working - I had to initialize interrupts something that wasn’t in any of the examples I had found.