Nodes simpleHomeSwitch template
Open the template as an Arduino example file and set the
compiler directives to the NodeID type "WS", "00" or "01" to max. "98".
A
Node must have a unique ID. Nodes "WS" with "00" are the minimum configuration.
- "WS" (WebSocket Node with SoftwareSerial/Bluetooth) Wi-Fi Home Network and Internet
- "00" (Mesh Node with SoftwareSerial/Bluetooth) Wi-Fi ad-hoc Network
- "01"-"98" (Mesh Nodes ) Wi-Fi ad-hoc Network. The ID "99" and "WB" are
reserved
("99" to all the Nodes and "WB" the Web Browser ID)
(free use oft two chars. also "AA" and "bc" is also OK)
There is also a "very basic" HTML UI, with the ID "WB", and associated scripts. It is usable for all the
Node functions and commands.
Make your own (graphic) UI and use this as a "How To ...".
Each Node can be set by using a Web Browser. Input: Node ID, function, command, a
unique key and parameters
(command list). These settings
are stored in the simpleDatabase on the Node. A record has 30 fields and can hold
a lot of data for, whether or not automatic, use. There are eleven modes available,
one manual and ten automatic on varied data:
0:Manual,
1:Time, 2:Lux, 3:Temp, 4:sunRise, 5:sunSet, 6:Sun, 7:Day, 8:Night, 9:Timer, 10:TimeTemp.
A record has a unique KEY, fixed on 4 chars, and hold the unit setups, status
and time counters. On Node (Re)Start/Reset the unit(s) are set in the right status.
Every minute a check on unit automatic mode 1-10 actions. If a action is done then
the unit-KEY-record is updated. If a Node has lost the connection than it works
standalone and will try to reestablish the connection.
Typical use: Light on/off, curtains close/open, blinds down/up, relays on/off,
Publish (this Node send commands to other Nodes . Replacement for (Not)Athome), steppers
turning left/right and find the home/end position, steppers degrees and find home
position, and ... all what you want.
A Node can ask another Node for values such as time, temperature, light intensity,
Pin or whatever.
So, if no RTC then the Node can get and sync the time from a "ask Node(nn) list".
There is also a STOP mode, 0: Active, 1: Pause and 04:00am reset, 2: Stop and wait for revoked.