Build a Weather Station with Elixir and Nerves: SGP30 vs SGP40

This is as much a suggestion as a question, as a note for others.

Locally the SGP30 wasn’t available, so I ordered a SGP40. On page 53, during ICS2.detect_devices() this sensor isn’t found.

At this point in my journey, I’m not sure if it’s a faulty board, a new board so not mapped or something else. Tried working cables, sequence, all powered on, so I’m going with maybe faulty, as the 0x59 isn’t listing.

Thankfully it’s not the main focus of the next few pages so I’ll have some time to figure it out, or figure out where to begin. Likey with a SGP30 on backorder.

So the suggestion… maybe a footnote to what to consider/explore if it’s not as listed… Or it could just be me :slight_smile:

Just by way of a head scratch… using the SGP40 hex package I can get answers back.

{:ok, sgp} = SGP40.start_link(bus_name: "i2c-1")
{:ok, %SGP40.Measurement{timestamp_ms: 316809, voc_index: 71}}

Onwards in this new journey I guess, thanks for an interesting afternoon so far :slight_smile:

I had similar issues detecting an SGP30… It never showed up with I2c.detect_devices(). I haven’t gotten to the hex package yet, but when I do I’ll try out searching for the device with this method.