Checking for alarm in this function means we will check when in control to flow or control to pressure states. Also checked only once per control interval which is maybe ok, but not typical for alarm checks. We do control to flow for treatment modes. Control to pressure is used in some cleaning modes. Not sure we want this alarm enforced in cleaning modes.
Another constraint is that embedded command mode command must be given first. Should also recommend a minimum time between embedded commands constraint to prevent f/w queue from overflowing.
I don't believe we need did * spaceChange. I am not interested in when the space changes. I am only interested when that partition gets too low on available space. Unless there is a case that you have which indicates otherwise. This signal is similar to didSDCardSpaceTooLow, line 231
This if condition appears to be redundant. rinsebackTimerCtr is set to zero in states where BP is running, so previous if condition would only be TRUE (rinsebackTimerCtr > 0) if BP not running.
I see your point. Issue is that we don't have a UI dialin folder with an HD proxy class (where this function should go). This command is not an HD proxy for DG so doesn't really belong here. I would maybe put it in hd\buttons.