So I’ve decided that, rather than have a “lower” limit switch, it would be much more advantageous to have a second “home” switch. Who gives a crap how far it's reclined, anyway?
As such, there would be a “rise” home switch, and a “recline” home switch. If they BOTH are closed, you know the chair is in the “home” position; Not raised and not reclined. This would also make software engineering for it much easier.
As is, sure it knows it is at the home position, but it doesn't know
HOW it got there. The “Recline Home” limit switch would eliminate the question.
Why is this important, and why does it matter?
So the chair "knows" what to do when any button is pressed:
- If the 'recline home' switch is open and you press the logic "up" button, it will engage the up motor until the 'recline home' switch closes.
- Likewise, if the 'rise home' switch is open you press the logic "down" button, it will engage the down motor until the 'rise home' switch closes*.
- Pressing the up button when at home or the rise home is open, it initiates the "up-and-out" process:
- Activating the up motor for an adjustable (setup) amount of time. By default, this is 22 seconds.
- Pausing at the top for an adjustable (setup) amount of time. By default, this is 10 seconds.
- *Activates the down motor until the 'rise home' switch closes or the "up-and-out" time is reached (22 seconds mentioned above). This is a safety routine in case the 'rise home' switch never closes for whatever reason.
- Pressing the down button when at home or the 'recline home' is open activates the down motor for an adjustable (setup) amount of time. By default, this is 8 seconds.
Of course, pressing any button anytime the chair is in motion will exit the currently running step and halt the chair's motion immediately.