Pid Control
Pid Control
1. Priority Management:
o A Priority array tracks the current priority of each pump.
o A PriorityCounter array tracks how many times each pump has been at its
current priority.
o After cycling 5 times, the priority is shifted, and the pump's position in the
PumpOrder is updated.
2. Pump Order Update:
o The PumpOrder array determines the activation sequence of pumps for the current
cycle.
o Priorities are rotated after every 5 cycles for each pump.
3. Dynamic Activation:
o Pumps are activated in the order specified by the updated PumpOrder array, based
on the value of NB_pump.
4. Remapping with BB:
o The pump IDs are dynamically remapped if BB = 1, as specified in your
requirements.
5. Flexibility:
o The program dynamically adjusts the activation order and can scale if more
pumps or cycles are added.