Exemplo n.º 1
0
 public static HBridgeMotor CreateForNetduino (Microsoft.SPOT.Hardware.Cpu.PWMChannel enable, Microsoft.SPOT.Hardware.Cpu.Pin a1, Microsoft.SPOT.Hardware.Cpu.Pin a2)
 {
     var leftPwm = new Robotics.Micro.Devices.PwmOutputPin (enable);
     var leftMotor = new HBridgeMotor (leftPwm);
     leftMotor.A1Output.ConnectTo (new Robotics.Micro.Devices.DigitalOutputPin (a1).Input);
     leftMotor.A2Output.ConnectTo (new Robotics.Micro.Devices.DigitalOutputPin (a2).Input);
     return leftMotor;
 }
Exemplo n.º 2
0
        public static HBridgeMotor CreateForNetduino(Microsoft.SPOT.Hardware.Cpu.PWMChannel enable, Microsoft.SPOT.Hardware.Cpu.Pin a1, Microsoft.SPOT.Hardware.Cpu.Pin a2)
        {
            var leftPwm   = new Robotics.Micro.Devices.PwmOutputPin(enable);
            var leftMotor = new HBridgeMotor(leftPwm);

            leftMotor.A1Output.ConnectTo(new Robotics.Micro.Devices.DigitalOutputPin(a1).Input);
            leftMotor.A2Output.ConnectTo(new Robotics.Micro.Devices.DigitalOutputPin(a2).Input);
            return(leftMotor);
        }