mirror of
https://github.com/Ralim/IronOS.git
synced 2025-02-26 07:53:55 +00:00
No movement pin
This commit is contained in:
@@ -81,23 +81,20 @@
|
|||||||
#define TIP_TEMP_ADC1_CHANNEL ADC_CHANNEL_5
|
#define TIP_TEMP_ADC1_CHANNEL ADC_CHANNEL_5
|
||||||
#define TIP_TEMP_ADC2_CHANNEL ADC_CHANNEL_5
|
#define TIP_TEMP_ADC2_CHANNEL ADC_CHANNEL_5
|
||||||
|
|
||||||
#define VIN_Pin GPIO_PIN_4
|
#define VIN_Pin GPIO_PIN_4
|
||||||
#define VIN_GPIO_Port GPIOA
|
#define VIN_GPIO_Port GPIOA
|
||||||
#define VIN_ADC1_CHANNEL ADC_CHANNEL_4
|
#define VIN_ADC1_CHANNEL ADC_CHANNEL_4
|
||||||
#define VIN_ADC2_CHANNEL ADC_CHANNEL_4
|
#define VIN_ADC2_CHANNEL ADC_CHANNEL_4
|
||||||
#define KEY_B_Pin GPIO_PIN_0
|
#define KEY_B_Pin GPIO_PIN_0
|
||||||
#define KEY_B_GPIO_Port GPIOB
|
#define KEY_B_GPIO_Port GPIOB
|
||||||
|
|
||||||
#define PWM_Out_Pin GPIO_PIN_8
|
#define PWM_Out_Pin GPIO_PIN_8
|
||||||
#define PWM_Out_GPIO_Port GPIOB
|
#define PWM_Out_GPIO_Port GPIOB
|
||||||
#define PWM_Out_CHANNEL TIM_CHANNEL_3 // Timer 4; channel 3
|
#define PWM_Out_CHANNEL TIM_CHANNEL_3 // Timer 4; channel 3
|
||||||
#define SCL2_Pin GPIO_PIN_6
|
#define SCL2_Pin GPIO_PIN_6
|
||||||
#define SCL2_GPIO_Port GPIOB
|
#define SCL2_GPIO_Port GPIOB
|
||||||
#define SDA2_Pin GPIO_PIN_7
|
#define SDA2_Pin GPIO_PIN_7
|
||||||
#define SDA2_GPIO_Port GPIOB
|
#define SDA2_GPIO_Port GPIOB
|
||||||
// Pin gets pulled high on movement
|
|
||||||
#define MOVEMENT_Pin GPIO_PIN_3
|
|
||||||
#define MOVEMENT_GPIO_Port GPIOA
|
|
||||||
|
|
||||||
#endif // MODEL_T55
|
#endif // MODEL_T55
|
||||||
|
|
||||||
|
|||||||
@@ -51,7 +51,8 @@ void Setup_HAL() {
|
|||||||
HAL_ADCEx_InjectedStart(&hadc1); // enable injected readings
|
HAL_ADCEx_InjectedStart(&hadc1); // enable injected readings
|
||||||
HAL_ADCEx_InjectedStart(&hadc2); // enable injected readings
|
HAL_ADCEx_InjectedStart(&hadc2); // enable injected readings
|
||||||
|
|
||||||
// Setup movement pin
|
// Setup movement pin
|
||||||
|
#ifdef MOVEMENT_Pin
|
||||||
{
|
{
|
||||||
GPIO_InitTypeDef GPIO_InitStruct;
|
GPIO_InitTypeDef GPIO_InitStruct;
|
||||||
GPIO_InitStruct.Pin = MOVEMENT_Pin;
|
GPIO_InitStruct.Pin = MOVEMENT_Pin;
|
||||||
@@ -60,6 +61,7 @@ void Setup_HAL() {
|
|||||||
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
|
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
|
||||||
HAL_GPIO_Init(MOVEMENT_GPIO_Port, &GPIO_InitStruct);
|
HAL_GPIO_Init(MOVEMENT_GPIO_Port, &GPIO_InitStruct);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
uint16_t getADCHandleTemp(uint8_t sample) {
|
uint16_t getADCHandleTemp(uint8_t sample) {
|
||||||
|
|||||||
@@ -237,14 +237,13 @@
|
|||||||
#define USB_PD_EPR_WATTAGE 0 /*No EPR*/
|
#define USB_PD_EPR_WATTAGE 0 /*No EPR*/
|
||||||
#define DEBUG_POWER_MENU_BUTTON_B 1
|
#define DEBUG_POWER_MENU_BUTTON_B 1
|
||||||
#define HAS_POWER_DEBUG_MENU
|
#define HAS_POWER_DEBUG_MENU
|
||||||
#define TEMP_NTC
|
|
||||||
#define NO_ACCEL 1
|
#define NO_ACCEL 1
|
||||||
#define I2C_SOFT_BUS_2 // For now we are doing software I2C to get around hardware chip issues
|
#define I2C_SOFT_BUS_2 // For now we are doing software I2C to get around hardware chip issues
|
||||||
#define OLED_I2CBB2
|
#define OLED_I2CBB2
|
||||||
#define FILTER_DISPLAYED_TIP_TEMP 4 // Filtering for GUI display
|
#define FILTER_DISPLAYED_TIP_TEMP 4 // Filtering for GUI display
|
||||||
|
|
||||||
#define MODEL_HAS_DCDC // We dont have DC/DC but have reallly fast PWM that gets us roughly the same place
|
#define MODEL_HAS_DCDC // We dont have DC/DC but have reallly fast PWM that gets us roughly the same place
|
||||||
#endif /* S60P */
|
#endif /* T55 */
|
||||||
|
|
||||||
#define FLASH_LOGOADDR (0x08000000 + (62 * 1024))
|
#define FLASH_LOGOADDR (0x08000000 + (62 * 1024))
|
||||||
#define SETTINGS_START_PAGE (0x08000000 + (63 * 1024))
|
#define SETTINGS_START_PAGE (0x08000000 + (63 * 1024))
|
||||||
|
|||||||
Reference in New Issue
Block a user