Multiple Steppers

Supporting Visual Studio on Windows
Posts: 10
Joined: Wed Jan 23, 2013 2:22 pm

Multiple Steppers

Postby meister » Tue Mar 17, 2015 11:17 am

I'm having serious issues trying to attach 2 stepper motors to a project at the same time. No matter what i try either one or both motors fail to attach, and end up killing my app.

This is the kind of thing i'm trying:

Code: Select all

public Carriage(iRuncible passedRuncible)
            iRuncible = passedRuncible;
            IOBoard = iRuncible.IOBoard;

            int mySNY = Convert.ToInt32(YMOTORSERIAL);
            int mySNX = Convert.ToInt32(XMOTORSERIAL);

            stepperY = new Stepper();
            stepperY.Attach += new AttachEventHandler(stepperY_Attach);
            stepperY.Detach += new DetachEventHandler(stepperY_Detach);
            stepperY.PositionChange += new StepperPositionChangeEventHandler(stepperY_PositionChange);
            stepperX = new Stepper();
            stepperX.Attach += new AttachEventHandler(stepperX_Attach);
            stepperX.Detach += new DetachEventHandler(stepperX_Detach);
            stepperX.PositionChange += new StepperPositionChangeEventHandler(stepperX_PositionChange);

            LEFT.Load(); //Placeholder plates, not barcode specific


Return to “C#.NET”

Who is online

Users browsing this forum: No registered users and 5 guests