How to create sensors not tied to pins
-
I am working with some devices that aren't directly tied to pins, yet I would still like to interact with these devices, ideally using NodeManager. An example device is a TTP229 touch sensor. This has 8 or 16 buttons and sends the state changes as serial data over a single data pin. I would like to treat these button presses as inputs to an S_BINARY sensors but at the moment I don't see a way to send sets for a sensor child by anything other than a physical pin.
On the receive side I would like to be able to receive arbitrary data from a controller to, for example, an S_CUSTOM device and then use that data to control the behaviour of the node. I could use the state of the child to do something like reduce the brightness of all the S_DIMMERs on the node.
Is there any way to do this type of thing?
-
@gohan yes, I certainly could treat these sensors manually but of course that is more work!
I think I will create a feature request on NodeManager to add a "virtual" sensor capability anyway because it would be useful and probably not that hard to build. This concept already exists for things like the battery sensor which has a pin "-1".
Edit: added request for this feature as issue #257.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login