You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
1.8 KiB
39 lines
1.8 KiB
#pragma once
|
|
#define VERSION(main, sub, fix) (main << 16 | sub << 8 | fix << 0)
|
|
|
|
#define VERSION_MAIN(version) ((version >> 16) & 0xFF)
|
|
#define VERSION_SUB(version) ((version >> 8) & 0xFF)
|
|
#define VERSION_FIX(version) ((version >> 0) & 0xFF)
|
|
|
|
/***********************************************************************************************************************
|
|
* PROJECT_CONFIG *
|
|
***********************************************************************************************************************/
|
|
|
|
/**
|
|
* @brief 基础配置
|
|
*
|
|
*/
|
|
#define PC_VERSION VERSION(1, 0, 0)
|
|
#define PROJECT "dbdb_liquid_path_control"
|
|
#define SN_HEADER "SN"
|
|
#define DEVICE_ID (2)
|
|
#define DEBUG_UART huart1 // 调试串口
|
|
#define DEBUG_LIGHT_GPIO PE8 // 调试指示灯
|
|
|
|
/**
|
|
* @brief 驱动器配置
|
|
*/
|
|
#define MOTOR_SPI hspi1
|
|
#define MOTOR_CH(n) (n)
|
|
#define MOTOR2_CSN PA4 //
|
|
#define MOTOR2_ENN PE11
|
|
#define MOTOR1_CSN PC4 //
|
|
#define MOTOR1_ENN PE12
|
|
|
|
/***********************************************************************************************************************
|
|
* SDK_CONFIG *
|
|
***********************************************************************************************************************/
|
|
#define SDK_DELAY_US_TIMER htim6 // 微秒延迟定时器,注意该延时定时器需要按照以下文档进行配置 http://192.168.1.3:3000/zwikipedia/iflytop_wikipedia/src/branch/master/doc/stm32cubemx_us_timer.md
|
|
#define SDK_IRQ_PREEMPTPRIORITY_DEFAULT 5 // IO中断默认中断等级
|
|
#define SDK_CFG__CFG_FLASH_ADDR 0x080C0000 //
|
|
#define SDK_CFG__SN_FLASH_ADDR 0x080E0000 //
|