I have a LCD display that has software running on a windows PC. Using the software (web listener) I can make POST requests to the listener and the text will display on the LCD display.
I'm trying to determine the best way to pass those requests to the listener based on actions. Some actions will be local (Hubitat) while others may come from IFTTT triggers.
I'd also like the ability (if possible) to "turn off" text a certain amount of time after the initial POST - IE if I send "Motion Detected", I'd like that text removed after x minutes from that point.
Any suggestions on how to accomplish this? Is there a virtual device time that this would work for? In that instance not sure how to track the time from the previous request however...
You could almost do this from Hubitat natively, but Rule Machine can do GETs and PUTs but not POSTs. An easy workaround for that is to use a custom driver, like this one from @ogiewon:
All you'd need to do is configure it correctly to point to your device and send the data in the format it expects. You could create several different devices if you need different text; I don't see a way in that driver to specify a different body (or whatever you'd need for your device) as part of a command, though you could also modify the driver to maybe add a command that takes your desired text and formats/sends it to the device as needed if you feel adventurous (or need that for your use case).
Unless you want to write a custom app (also an option, and then you might not even need the driver--the app could do a POST too), I'd use this device with Rule Machine. You can configure the actions to do whatever you want. Say, if your rule triggers on "motion active," you do a POST to make the LCD say "motion active," then either do a "Wait for event: elapsed time -> 0:10:00" or a "Wait for condition: motion inactive --> duration 0:10:00" (depending on however you really want this to work), then do another POST to clear the display. Just one idea!