25.04.2024, 12:30
Hello,
We're working on a project where the CCF provider demands that the blinds can only be moved up or down once per day. As a result, I'm in need of a script that can process inputs from two separate sources: a push button, which provides a 1-bit signal for up or down movement, and a weather station, which gives a signal ranging from 0 to 100%.
Here's how it should function: If a 1-bit signal for "down" (1) is received, the blinds should move downward. If a 1-bit signal for "up" (0) is received, no action should be taken. When a 100% signal is received, the blinds should move down, and if a 0% signal is received, no action should occur.
The slat can move during the day.
Additionally, by the end of the day, say at 23:00, the blinds should automatically move up again. We also require a counter to keep track of the number of times the blinds move up and down, which should be stored as a 2-byte value.
We're working on a project where the CCF provider demands that the blinds can only be moved up or down once per day. As a result, I'm in need of a script that can process inputs from two separate sources: a push button, which provides a 1-bit signal for up or down movement, and a weather station, which gives a signal ranging from 0 to 100%.
Here's how it should function: If a 1-bit signal for "down" (1) is received, the blinds should move downward. If a 1-bit signal for "up" (0) is received, no action should be taken. When a 100% signal is received, the blinds should move down, and if a 0% signal is received, no action should occur.
The slat can move during the day.
Additionally, by the end of the day, say at 23:00, the blinds should automatically move up again. We also require a counter to keep track of the number of times the blinds move up and down, which should be stored as a 2-byte value.