Multiple steppers including limit Switches does not work

@gcjr

the code you posted looks like a ready to use or almost ready to use code.
I haven't done anything yet with classes.

Would you mind explaining what you coded with the class through adding comments to all interesting lines inside the class?

Especially I'm wondering about the three parameters here

  public:
    AccelStepper (int a, int b, int p)  {
        pin = p;
        pinMode (pin, OUTPUT);
        digitalWrite (pin, Off);
    };

I have no idea what parameter "a" and parameter "b" are doing.

the names "a" and "b" don't explain anything.

From the numbers in creating the instances

AccelStepper StepperA(1, 26, 25);
AccelStepper StepperB(1, 13, 12);

I can guess "a" number of steppermotors?? does not really make sense
both instances have one stepper-motor

number in the meaning of motor 1, motor 2, motor 3
makes no sense too.
So what is the first parameter for?

second parameter might be a pin-number
but the definition uses only parameter "p" as a pin number.
So what is parameter "a" and parameter "b" for?

Just place-holders for future use?
No idea at all

I was asking "should the count-down until the solenoid makes the object drop
be started if the limit switch is triggered.
Julius-me did not answer this question.

The code that gcjr posted doesn't take care of that.
Dropping is done constantly if the time defined in variable interval has passed by.

Dropping the object assumes that the limit-switch changes his stage to "no-object near to limit-switch" and that this change can be used to start the stepper-motor to wind up.

best regards Stefan