Upgraded MIGRATION document.

Mon, 08 Apr 2024 11:23:45 +0200

author
Michiel Broek <mbroek@mbse.eu>
date
Mon, 08 Apr 2024 11:23:45 +0200
changeset 668
4df4c8b17733
parent 667
bba6ca418e09
child 669
daa22055cd3d

Upgraded MIGRATION document.

MIGRATION file | annotate | diff | comparison | revisions
--- a/MIGRATION	Mon Apr 08 10:57:12 2024 +0200
+++ b/MIGRATION	Mon Apr 08 11:23:45 2024 +0200
@@ -3,7 +3,7 @@
 
 WiringPi is unmaintained and replaced by pigpio. This will need large parts
 of thermferm to be rewritten. It is also a good moment to replace the current
-server protocol with json data and start sending data chaanges over
+server protocol with json data and start sending data changes over
 websockets.
 
 Some parts of the code can make use of direct kernel support, since kernel 4
@@ -12,7 +12,7 @@
 
 The current devices model is not very practical. We need to separate the parts
 that don't need gpio out of it. All one-wire devices need their own driver
-thread.
+thread. Is done.
 
 
 	Current threads.
@@ -47,11 +47,11 @@
   2. Check for exit.
      Scan for devices. Add to one-wire list.
   3. Check for exit.
-     Read all DS2413 devices programmed as input.
+     Read all DS2413 devices programmed as input. TODO: set output bits.
   4. Check for exit.
      Read one temperture sensor from list and update.
   5. Check for exit.
-     Check for missing devices not in one wire table.
+     Check for missing devices not in one wire table. TODO.
      Goto 2.
   6. Exit state.
 
@@ -65,39 +65,24 @@
      Publish DBirth
      Publish Startup
 
-States (nested):
+States:
 
   1. Init.
   2. Check shutdown.
      Check run_pause.
      Wait for new minute.
+       Yes, goto 3.
+       No, goto 8.
   3. Update clock on display.
      Show room temp/humidity.
   4. If THB changed or 5 minutes passed publish NData.
-  5. For units loop.
-
-       1. Init.
-       2. If air address
-       3. If beer address
-       4. If chiller address
-       5. If door address
-       6. If PSU address
-       7. If unit->mode == UNITMODE_PROFILE
-       8. If unit->mode == UNITMODE_NONE
-       9. Usage counters
-      10. If light address
-      11. if ((unit->mode == UNITMODE_FRIDGE) || (unit->mode == UNITMODE_BEER) || (unit->mode == UNITMODE_PROFILE)) // Temp control active
-      12. Update the LCD
-      13. Set unit->mqtt_flag |= MQTT_FLAG_DATA after 60 seconds
-      14. Publish what is needed.
-      15. Handle alarms.
-      16. End.
-
+  5. For units loop, do all units.
   6. Show LCD buffer.
-  7. 60 seconds reset and actions.
+  7. 60 seconds reset and Minute actions.
   8. Keyboard check.
-  9. Delay 100 mSec and goto 2.
- 10. Done.
+     Delay 50 mSec.
+     Goto 2.
+  9. Done.
 
 After:
      Stop all units.

mercurial