-
Asking for help locating the part of the GPIO code where the detection of the magnet would be reversed. Why? I wanted to go away from mechanical hall sensors and try something like TL4905L or a A3144 board with LM393 comparator that gives the"high" state when magnet is detected. Such board is even cheaper than some of hall effect sensors and more reliable and some of them even have a regulator (potentiometer) where you can precisely adjust the sensitivity of the circuit. In ideal case this setting could be as one of the parameters in the config file too. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
That's an interesting idea! Have a look at All that you would have to change is the initialization call for the sensor:
For your scenario you probably want to set it to If it works out nicely we can make it a configurable option and describe the sensor setup in the docs... |
Beta Was this translation helpful? Give feedback.
-
In the proposed modifications, the option to select an upward, downward or both flanks has been added (see #84). |
Beta Was this translation helpful? Give feedback.
That's an interesting idea! Have a look at
openrowingmonitor/app/gpio/GpioTimerService.js
to change the gpio sensor settings.All that you would have to change is the initialization call for the sensor:
For your scenario you probably want to set it to
falling
. There are also a bunch of additional options (like denouncing) that you could set if needed, see here for the available options: https://github.com/fivdi/onoff#gpiogpio-direction--edge--optionsIf it works out nicely we can make it a configurable option and describe the sensor setup in the docs...