Add support for motor drivers. Some points to consider while adding support ⚠️
1) Must handle Parallel and normal mode through code, rather than menuconfig. This can be done with functions like enable_parallel_mode() or passing parameters to enable_motor_driver(PARALLEL) function.
2) Declare a static variable which is set to 0 if motor driver is disabled, set to 1 if motor driver is enabled in parallel mode, and set to 2 if it is initialise in normal mode.
3) There must be helper method like, read_motor_driver_mode(), which will return the mode of the motor driver by reading the static variable defined above.
4) Functions should be abstract enough, don't define functions like bot_forward(), etc. We don't know for what purpose the motor is going to be used, functions like set_motor_speed() should be defined.
Add support for motor drivers. Some points to consider while adding support ⚠️
1) Must handle Parallel and normal mode through code, rather than menuconfig. This can be done with functions like
enable_parallel_mode()
or passing parameters toenable_motor_driver(PARALLEL)
function.2) Declare a static variable which is set to 0 if motor driver is disabled, set to 1 if motor driver is enabled in parallel mode, and set to 2 if it is initialise in normal mode.
3) There must be helper method like,
read_motor_driver_mode()
, which will return the mode of the motor driver by reading the static variable defined above.4) Functions should be abstract enough, don't define functions like
bot_forward()
, etc. We don't know for what purpose the motor is going to be used, functions likeset_motor_speed()
should be defined.