Replies: 18 comments
-
@sanderlv, the sensor uses I2C, and the library relies on Wire. To use alternative pins, you need to modify the .h file and edit the Wire declaration. It is possible that if you just use the i2c stanza inside your YAML, it will work as well. A note: I am currently working on making this an external component, which will make the usage in ESPHome simpler. |
Beta Was this translation helpful? Give feedback.
-
Hi, thanks for the reply and sorry for my delay. Where in the amg8833.h file do I need to assign pins? |
Beta Was this translation helpful? Give feedback.
-
The |
Beta Was this translation helpful? Give feedback.
-
I can confirm it's working on an esp32 using an i2c stanza, no need to muck around in amg8833.h. Here's what I added to my esphome yaml:
|
Beta Was this translation helpful? Give feedback.
-
Thanks for letting us know @sharpopotamus ! I really should get myself an ESP32 to play with. |
Beta Was this translation helpful? Give feedback.
-
Unfortunately not having as good luck getting this working on an ESP32 tinypico board. Here's my yaml for my esphome sensor:
and the error I'm getting at compile:
I am able to get pretty much the exact same yaml config working on a ES8266 Adafruit Huzzah, only the pin assignments are different. Trying to use the tinypico for packaging reasons. From the sounds of things the reference to Wire.h inside Sparkfun Grideye isn't connecting like it should. Unfortunately this is way too far beyond my understanding of platformio. I tried adding "Wire" to Any suggestions or ideas appreciated. |
Beta Was this translation helpful? Give feedback.
-
@ThreeFN |
Beta Was this translation helpful? Give feedback.
-
@TheRealWaldo ESPHome is v2021.10.3 (latest stable). Full output for a compile to datafile:
You would think this error shouldn't be happening, and maybe I'm misinterpreting the error, but it looks like the Sparkfun libraries reference to Wire isn't matching up with the other references and is being labelled as missing. Again only happening for me when I try to compile for ESP32 boards (tinypico), not for ESP8266 boards (Huzzah). |
Beta Was this translation helpful? Give feedback.
-
@ThreeFN I have to guess that they use different I2C libraries for that specific board for one reason or another (likely some incompatibility). Please open a new issue citing that board specifically, and I'll try to look into it a bit deeper tomorrow. |
Beta Was this translation helpful? Give feedback.
-
After I tried to reinstall on my esp32, I actually had the same error pop up. Not sure what the issue is, but I solved it by just downloading the sparkfun library and referencing it locally. I downloaded this: https://github.com/sparkfun/SparkFun_GridEYE_Arduino_Library/releases/tag/v1.0.1 then copied SparkFun_GridEYE_Arduino_Library.cpp and SparkFun_GridEYE_Arduino_Library.h into my esphome directory. It's in the same file as amg8833.h, amg8833_camera.h, and amg8833_person_detected.h. Then I modified the esphome yaml to call those files, removing the sparkfun library call. This is the relevant bit:
|
Beta Was this translation helpful? Give feedback.
-
Can confirm this workaround solved the issue for me. Again not really my expertise as to why this would solve the issue, but my guess is that the issue lies with platformio vs arduino c, etc. @TheRealWaldo would you still like me to open a separate/new issue? |
Beta Was this translation helpful? Give feedback.
-
@ThreeFN, yes, please. I think this might boil down to a recent change in ESPHome, and it may resolve itself when I finish up the external component. |
Beta Was this translation helpful? Give feedback.
-
For me this was the solution/workaround. Added "Wire" before "SparkFun GridEYE AMG88 Library":
|
Beta Was this translation helpful? Give feedback.
-
More promising... But next step is how and where do I get a camera created? Where do I put: https://github.com/TheRealWaldo/AMG8833-ESPHOME#example When I put it in And a person is detected but there is no person in sight :-) |
Beta Was this translation helpful? Give feedback.
-
Perhaps it's not clear: You need to install https://github.com/therealwaldo/thermal into your Home Assistant (via. HACS is the easiest), and configure the camera in your HASS yaml. The current rudimentary person detection works off a difference of 4°C. Your min appears to be 20, and your max, 26, so it's triggering. You can tune that however you like, masking out the area that is too much heat, or adjusting the angle of the sensor so that you are not seeing hot-spots in the room. |
Beta Was this translation helpful? Give feedback.
-
@sanderlv for the thermal camera you Need this: https://github.com/TheRealWaldo/thermal |
Beta Was this translation helpful? Give feedback.
-
got it... You can tune that however you like, masking out the area that is too much heat, or adjusting the angle of the sensor so that you are not seeing hot-spots in the room. How and where do I mask? do? |
Beta Was this translation helpful? Give feedback.
-
How and where would I do that? |
Beta Was this translation helpful? Give feedback.
-
Hi, I am preparing to go with an ESP32... I have esphome setup with the custom .h files and no errors in the yaml. I screenshot so you can see it is all ok.
Never mind: I accidentally screwed another esp.... wrong COM port...
But:
Where are the pins declared?
D1 and D2 are GPIO4 and 5 (or viceversa). Converting to my ESP GPIO4 and 5 are IO4 and IO5.
I now get:
Beta Was this translation helpful? Give feedback.
All reactions