“优化了一下”
This commit is contained in:
@@ -25,12 +25,16 @@ void my_code();
|
||||
#define READ_MOT_IN1 HAL_GPIO_ReadPin(MOT_IN1_GPIO_Port, MOT_IN1_Pin)
|
||||
#define READ_MOT_IN2 HAL_GPIO_ReadPin(MOT_IN2_GPIO_Port, MOT_IN2_Pin)
|
||||
|
||||
#define EEPROM_BEGIN_ADD 32
|
||||
#define CONFIG_EFF_CODE 0xab
|
||||
|
||||
typedef struct
|
||||
{
|
||||
|
||||
char key_code[2];
|
||||
char begin;
|
||||
int time;
|
||||
long countdown_set;
|
||||
}config_setting;
|
||||
|
||||
struct display_penal
|
||||
@@ -49,4 +53,32 @@ struct display_penal
|
||||
char moto2b;
|
||||
}dis_buff;
|
||||
|
||||
#define set_filtering_times 50
|
||||
struct
|
||||
{
|
||||
//ADC_HandleTypeDef *device;
|
||||
int filtering_times;
|
||||
unsigned long adc_filtering[2];
|
||||
int adc_value[2];
|
||||
}ADCC;
|
||||
|
||||
|
||||
struct
|
||||
{
|
||||
uint32_t moto_run;
|
||||
int pwm_run;
|
||||
|
||||
|
||||
char moto1a;
|
||||
char moto1b;
|
||||
char moto2a;
|
||||
char moto2b;
|
||||
|
||||
char moto1a_;
|
||||
char moto1b_;
|
||||
char moto2a_;
|
||||
char moto2b_;
|
||||
|
||||
}moto;
|
||||
|
||||
#endif /* MY_CODE_H_ */
|
||||
|
||||
Reference in New Issue
Block a user