"Abort" switch

hi guys

not sure how to post my code correctly so bear with me!!

in designing a control system for a wheelchair lift for my mother. i would like to build in an abort switch so if things get a little haywire i can stop the lift immediately where its at. does anyone have ideas on how to proceed?? im in the process of organizing the code so its not 100%

thanks

chris

Lift_2.0.ino (10.6 KB)

The abort switch cuts the power and applies the mechanical brake.
It does not involve software.

got it!!

thanks!!

not sure how to post my code correctly

For future reference, this is described in the "How to use this forum" post.

I finally got to a laptop to download your code.

Auto_Shutdown = Shutdown.after (1000 * 60 * 10, Inverter_Auto_Shutdown);

Oops

if ((Door_Open == false) && (Door_Closed == true));

And again

if ((Door_Open == true) && (Door_Closed == false) && (Home == true) && (Position_1 == false) && (Position_2 == false));

Oh dear.

const int Vehicle_Power_Signal = 43;
...
  if (Vehicle_Power_Signal == HIGH) {

Not going to happen

const int Door_Sensor = 32;
const int Door_Tilt_Sensor = 33;
...
  Door_Open = ((Door_Sensor) == LOW && (Door_Tilt_Sensor) == LOW);

Again, not happening.

And so on ...

How did this get to version 2?

Please stop, before someone gets hurt - you have way too much code, and clearly, none of it tested.

Put it in the bin, and start again