Erste Vorbereitungen für Settings-Datei
This commit is contained in:
@@ -15,17 +15,13 @@
|
||||
#include <linux/can.h>
|
||||
#include <linux/can/raw.h>
|
||||
|
||||
#define MOTOR_COUNT 2
|
||||
#define MAX_MOTOR_COUNT 2
|
||||
|
||||
// motor gear: 0x7C=reverse, 0x7D=neutral, 0x7E=forward
|
||||
#define MOTOR_GEAR_REVERSE 0x7C
|
||||
#define MOTOR_GEAR_NEUTRAL 0x7D
|
||||
#define MOTOR_GEAR_FORWARD 0x7E
|
||||
|
||||
#define MOTOR_PWR_STEP_COUNT 7 // how many steps to set power
|
||||
#define MOTOR_PWR_MIN_RAW 38
|
||||
#define MOTOR_PWR_MAX_RAW 250 // max. raw power value for motor
|
||||
|
||||
struct MOTOR_CONTROL_DATA
|
||||
{
|
||||
char nDriveConnected;
|
||||
@@ -36,7 +32,7 @@ struct MOTOR_CONTROL_DATA
|
||||
unsigned char nSwitchState;
|
||||
int iActualMotorPowerW;
|
||||
};
|
||||
extern struct MOTOR_CONTROL_DATA motctrl[MOTOR_COUNT];
|
||||
extern struct MOTOR_CONTROL_DATA motctrl[MAX_MOTOR_COUNT];
|
||||
|
||||
struct CAN_INTERFACE_DATA
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user