1#ifndef J_MOTOR_DRIVER_DUAL_H
2#define J_MOTOR_DRIVER_DUAL_H
20 bool m1state =
m1.
set(val);
21 bool m2state =
m2.
set(val);
22 return m1state && m2state;
28 return m1state || m2state;
34 return m1state || m2state;
control two JMotorDrivers (of any type) as if they are one driver
Definition JMotorDriverDual.h:9
bool setEnable(bool _enable)
use to enable or disable a motor, and sets up pin states
Definition JMotorDriverDual.h:24
JMotorDriverDual(JMotorDriver &_m1, JMotorDriver &_m2)
Definition JMotorDriverDual.h:13
float getMinRange()
low end of the range
Definition JMotorDriverDual.h:40
JMotorDriver & m1
Definition JMotorDriverDual.h:11
bool set(float val)
set motor power
Definition JMotorDriverDual.h:18
JMotorDriver & m2
Definition JMotorDriverDual.h:12
bool getEnable()
get the enable state of the driver
Definition JMotorDriverDual.h:30
float getMaxRange()
high end of the range
Definition JMotorDriverDual.h:36
defines common interface for all types of JMotorDrivers
Definition JMotorDriver.h:10
virtual bool set(float val)
set motor power
virtual bool setEnable(bool _enable)
use to enable or disable a motor, and sets up pin states
virtual float getMaxRange()
high end of the range
virtual float getMinRange()
low end of the range
virtual bool getEnable()
get the enable state of the driver