Maestro with 3 servo channels and 4 output channels

I wish to use some of the unused channels on my Maestro as digital output pins. I have them configured as “Output” instead of “Servo” I am using the “Visual Basic / Maestro” SDK.

I use the “Set Target” method to move the servos. How do I set the output pin to one or zero?
Is there a " Set channel to one" method? Do I just just set the target to a high number, or a low number? What numbers are recommended?

If I was using a pin as an Input, how would I read if it is a one or a zero?

You can test all that using the Maestro Control Centre and reading the documentation.

Use SetTarget()

If the channel is configured as a servo, then the target represents the pulse width to transmit in units of quarter-microseconds. A target value of 0 tells the Maestro to stop sending pulses to the servo.

If the channel is configured as a digital output, values less than 6000 tell the Maestro to drive the line low, while values of 6000 or greater tell the Maestro to drive the line high.

Use GetPosition()

If the specified channel is configured as a servo, this position value represents the current pulse width that the Maestro is transmitting on the channel, reflecting the effects of any previous commands, speed and acceleration limits, or scripts running on the Maestro.

If the channel is configured as a digital output, a position value less than 6000 means the Maestro is driving the line low, while a position value of 6000 or greater means the Maestro is driving the line high.

If the channel is configured as an input, the position represents the voltage measured on the channel. The inputs on channels 0–11 are analog: their values range from 0 to 1023, representing voltages from 0 to 5 V. The inputs on channels 12–23 are digital: their values are either exactly 0 or exactly 1023.

1 Like