-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
ESP32 Hall Sensor Not Working #7721
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Using latest master building the GENERIC board with ESP IDF v4.2, the |
Ok... I tried a devkit-C... It gives me readings around 110 when no field, and rises to about 300 when a standard refrigerator magnet is laid directly on the top. This seems to imply that any value of 0 returned by hall_sensor() almost definately means an error occured, especially if solid. It also seems to imply that neither an ESP32-Wrover, nor an ESP32-S2 have internal Hall Sensors. Let he call me stupid who already knew this :S Perhaps some research may have revealed the ESP32-S2 lacks one, but I thought the ESP32-Wrover was the exact same chip as the ESP32-Wrover, except that the Wrover has an additional PSRAM chip. Seems that's incorrect. |
As a side note, would be nice if micropython were able to detect the presence/lack of a Hall Sensor and throw an exception instead of 0. |
The It might be that it didn't work on your board because channels 0 and 3 of ADC1 were used for something else. |
No honestly, I'm using factory modules with nothing but the programmer attached. Those pins are free. Yet still I see only 0. I double checked the chips, the Wrover Modules I'm using are ESP32-D0WDQ6 (revision 1). So no idea why it's not working. Unless Wrover Modules internally connect those channels to something else? I'm starting to think the internal SPIRAM/PSRAM is attached to ADC0/3. Can anyone confirm this? |
linking Pr that removes the hal_sensor |
The PR detail has the comment
It also seems to have vanished from the docs. So the only solution is to use old firmware. |
On the documentation, @jimmo, this was part of our conversation on st documentation, Python docs often have a note describing when a feature was introduced or deprecated. |
I freshly erased an ESP32-Wrover, then flashed v1.16 of micropython. When I call hall_sensor(), it only returns 0. I'm testing it with a strong magnet, which I have moved all around the ESP32, in all thinkable orientations of the magnet. Still, the return value from hall_sensor doesn't even jitter, it remains a solid 0.
The text was updated successfully, but these errors were encountered: