I apologize if it seems like I'm "jumping the gun" this is my first big arduino project I've ever done. After reading some comments, I agree, I do need to write out everything I want the control system to do. So I have taken the time to vividly explain the functions of the control panel. The purpose of this project is to simulate the user interface of an amusement ride control system. This will be controlling a LEGO roller coaster via a control panel utilizing an Arduino mega. The control panel is designed to have 10 control points: (2) dispatch buttons, Emergency Stop, Emergency Stop Reset (ESR), Lift Stop, Restraints Release, Gates Open/Close, Panel Function Enable, Maintenance Bypass, Ghost Mode, And a lock out- tag out switch. Certain functions can only be used if the proper “safety” criteria are met and will be described below.
PANEL FUNCTION ENABLE- This is a key switch that when in the “on” position will allow the control panel to be used and will flash the control panel lights when in idle. When the ride is turned on: in order to “enable” the panel the MAINTENANCE BYPASS key must be turned on, and all buttons must be pushed at least once. This is called a lamp and function test on a real coaster. (They should flash to indicate which button needs to be pressed).
DISPATCH ONE AND TWO- Two green momentary buttons with LEDs. When pressed in conjunction these buttons will start the ride cycle (turn on the lift motor for 10-15 seconds). When not pressed and with panel power on the lights should flash intermittently. Once pressed to start ride they will stay solid the while the lift is running. In order to start the ride the PANEL ENABLE must be “on”, the GATES must be in the “closed” position, and the RESTRAINTS must be in the “closed” position.
LIFT STOP - A red momentary button with a LED. When in idle, the LED will flash intermittently, when pressed the LED will stay solid until the LIFT STOP has been reset, also when pressed this will cause the ESR to flash rapidly. Once pressed will stop the lift and turn off the LEDs on the Dispatch Buttons. In order to restart the lift’s timed cycle and the LIFT STOP press, the ESR must be pressed. Once pressed panel and ride shall resume normal operation.
EMERGENCY STOP- A red position-maintained button with a LED. When in idle, LED will flash intermittently along with the LIFT STOP LED. When pressed, LED will flash rapidly, all control functions of the ride will lose functionality, and the lift (if running) will stop. In order to reset the EMERGENCY STOP; the button must be pulled back up, the panel must be turned to maintenance mode via the MAINTENANCE BYPASS key switch (which will cause the ESR to flash), then the ESR must be pressed. Once the ESR has been pressed the MAINTENANCE BYPASS must be disabled to resume normal operation.
EMERGECNCY STOP RESET (ESR)- An amber momentary button with an LED. When in idle, this LED will remain off. The LED will only illuminate if it is to indicate an EMERGENCY STOP, LIFT STOP, PANEL ENABLE, or LOCK OUT must be reset.
GATES OPEN/CLOSE- A position maintained switch. When enabled it “pretends” gates are open and will prevent the ride from being dispatched. (Eventually I will actually control the gates in the station with this switch) when closed ride may be dispatched.
RESTRAINTS OPEN/CLOSE- A green momentary button with a LED. When in idle or “restraints closed” position, the LED will remain off and the ride may be dispatched. When pressed the LED with flash intermittently signaling the restraints are “open” and will prevent the ride from being dispatched. To “close” the restraints the button must be pressed again.
MAINTENANCE BYPASS- a position maintained key switch. When enabled it puts the controls into “maintenance mode”. This will allow the ESR to be used if a LIFT STOP, EMERGENCY STOP, or a LOCK OUT needs to be reset. This must also be used to initiate the “lamp test” when the ride is first turned on via the PANEL ENABLE. When off, the ride will be in normal operation mode.
GHOST MODE- A position maintained key switch. When enabled will cause the coaster to continuously run without user input.
LOCK OUT- a position maintained switch. When enabled it will act almost exactly like the EMERGENCY STOP described above. The only difference is the EMERGENCY STOP’s LED will illuminate solid when the lock out is engaged. Reset the same way as the EMERGENCY STOP.
Hopefully this gives an insight to exactly what I want this Arduino to accomplish. Luckily the actual LEGO coaster is on back order and won’t be here for a while so this will give me plenty of time to hopefully get this code close to working order.