This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Issues running SHT3xD example with my SHT35 sensor PCB

I've got a bunch of my own SHT35-D sensor PCB's fresh off the production line, and I want to come up with a simple way to test they are all operational.

Thought I'd use the \v1.9.1\zephyr\samples\sensor\sht3xd example project to try and get myself up and running with the minimum of fuss.

Unfortunately I'm not able to get things to progress beyond the point in the code where it attempts to acquire my sensor:

const struct device *dev = device_get_binding("SHT3XD");
	int rc;

	if (dev == NULL) {
		printf("Could not get SHT3XD device\n");
		return;
	}

This is basically returning the "Could not get SHT3XD device" error.

I'm trying to run this on my nRF52-DK board, and have tried with both the i2c0 (SDA = 26 & SCL = 27) and i2c1 (SDA = 30 & SCL = 31).  But both are coming up with the same issue.

I've got my sensor configured with address 0x44, but I can't see anywhere in the example code where this is configured - either as 0x44 or 0x45.  So, haven't been able to eliminate this as an issue.

My hardware shouldn't be an issue - it includes the sensor, a 10K pull-up on both the SCL and SDA lines and a decoupling capacitor from VDD to VSS.  So I suspect I'm doing (or not doing) something simple with regards to the firmware side of things.

Can any one help me progress this?  Apologies for what is probably a very beginner question.

Cheers,

Mike

Parents
  • Hello,

    Look at the v1.9.1\zephyr\samples\sensor\sht3xd\boards folder. In there you should find a file called nrf52840dk_nrf52840.overlay file. Try creating a similar file with your boards name (if you are using an nrf52832 DK try creating a file called nrf52dk_nrf52832.overlay. Other than that, you shouldn't need to change anything in the file.

    BR,
    Edvin

Reply
  • Hello,

    Look at the v1.9.1\zephyr\samples\sensor\sht3xd\boards folder. In there you should find a file called nrf52840dk_nrf52840.overlay file. Try creating a similar file with your boards name (if you are using an nrf52832 DK try creating a file called nrf52dk_nrf52832.overlay. Other than that, you shouldn't need to change anything in the file.

    BR,
    Edvin

Children
Related