This commit is contained in:
Ben V. Brown
2022-08-03 20:35:28 +10:00
parent 6cc9b29058
commit 47c1792024
5 changed files with 15 additions and 18 deletions

View File

@@ -175,11 +175,11 @@
* @retval None * @retval None
*/ */
void HAL_GPIO_Init(GPIO_TypeDef *GPIOx, GPIO_InitTypeDef *GPIO_Init) { void HAL_GPIO_Init(GPIO_TypeDef *GPIOx, GPIO_InitTypeDef *GPIO_Init) {
uint32_t position = 0x00u; uint32_t position = 0x00u;
uint32_t ioposition; uint32_t ioposition;
uint32_t iocurrent; uint32_t iocurrent;
uint32_t temp; uint32_t temp;
uint32_t config = 0x00u; uint32_t config = 0x00u;
__IO uint32_t *configregister; /* Store the address of CRL or CRH register based on pin number */ __IO uint32_t *configregister; /* Store the address of CRL or CRH register based on pin number */
uint32_t registeroffset; /* offset used during computation of CNF and MODE bits placement inside CRL or CRH register */ uint32_t registeroffset; /* offset used during computation of CNF and MODE bits placement inside CRL or CRH register */
@@ -326,9 +326,9 @@ void HAL_GPIO_Init(GPIO_TypeDef *GPIOx, GPIO_InitTypeDef *GPIO_Init) {
* @retval None * @retval None
*/ */
void HAL_GPIO_DeInit(GPIO_TypeDef *GPIOx, uint32_t GPIO_Pin) { void HAL_GPIO_DeInit(GPIO_TypeDef *GPIOx, uint32_t GPIO_Pin) {
uint32_t position = 0x00u; uint32_t position = 0x00u;
uint32_t iocurrent; uint32_t iocurrent;
uint32_t tmp; uint32_t tmp;
__IO uint32_t *configregister; /* Store the address of CRL or CRH register based on pin number */ __IO uint32_t *configregister; /* Store the address of CRL or CRH register based on pin number */
uint32_t registeroffset; uint32_t registeroffset;

View File

@@ -151,8 +151,8 @@ static uint32_t usbh_int_pipe(usb_core_driver *pudev) {
\retval operation status \retval operation status
*/ */
static uint32_t usbh_int_txfifoempty(usb_core_driver *pudev, usb_pipe_mode pp_mode) { static uint32_t usbh_int_txfifoempty(usb_core_driver *pudev, usb_pipe_mode pp_mode) {
uint8_t pp_num = 0U; uint8_t pp_num = 0U;
uint16_t word_count = 0U, len = 0U; uint16_t word_count = 0U, len = 0U;
__IO uint32_t *txfiforeg = 0U, txfifostate = 0U; __IO uint32_t *txfiforeg = 0U, txfifostate = 0U;
if (PIPE_NON_PERIOD == pp_mode) { if (PIPE_NON_PERIOD == pp_mode) {

View File

@@ -221,7 +221,7 @@ void OLED::maskScrollIndicatorOnOLED() {
// it from the screen buffer which is updated by `OLED::setRotation`. // it from the screen buffer which is updated by `OLED::setRotation`.
uint8_t rightmostColumn = screenBuffer[7]; uint8_t rightmostColumn = screenBuffer[7];
uint8_t maskCommands[] = { uint8_t maskCommands[] = {
// Set column address: // Set column address:
// A[6:0] - Column start address = rightmost column // A[6:0] - Column start address = rightmost column
// B[6:0] - Column end address = rightmost column // B[6:0] - Column end address = rightmost column
0x80, 0x80,

View File

@@ -46,7 +46,7 @@ void USBPowerDelivery::IRQOccured() { pe.IRQOccured(); }
bool USBPowerDelivery::negotiationHasWorked() { return pe.pdHasNegotiated(); } bool USBPowerDelivery::negotiationHasWorked() { return pe.pdHasNegotiated(); }
uint8_t USBPowerDelivery::getStateNumber() { return pe.currentStateCode(true); } uint8_t USBPowerDelivery::getStateNumber() { return pe.currentStateCode(true); }
void USBPowerDelivery::step() { void USBPowerDelivery::step() {
while (pe.thread()) {} while (pe.thread()) {}
} }
void USBPowerDelivery::PPSTimerCallback() { pe.TimersCallback(); } void USBPowerDelivery::PPSTimerCallback() { pe.TimersCallback(); }

View File

@@ -42,7 +42,7 @@ void showWarnings();
#define BUTTON_INACTIVITY_TIME (60 * configTICK_RATE_HZ) #define BUTTON_INACTIVITY_TIME (60 * configTICK_RATE_HZ)
static TickType_t lastHallEffectSleepStart = 0; static TickType_t lastHallEffectSleepStart = 0;
static uint16_t min(uint16_t a, uint16_t b) { static uint16_t min(uint16_t a, uint16_t b) {
if (a > b) if (a > b)
return b; return b;
else else
return a; return a;
@@ -997,10 +997,8 @@ void startGUITask(void const *argument) {
#endif #endif
#endif #endif
// If the boot logo is enabled (but it times out) and the autostart mode is enabled (but not set to sleep w/o heat), start heating during boot logo // If the boot logo is enabled (but it times out) and the autostart mode is enabled (but not set to sleep w/o heat), start heating during boot logo
if (getSettingValue(SettingsOptions::LOGOTime) > 0 && if (getSettingValue(SettingsOptions::LOGOTime) > 0 && getSettingValue(SettingsOptions::LOGOTime) < 5 && getSettingValue(SettingsOptions::AutoStartMode) > 0
getSettingValue(SettingsOptions::LOGOTime) < 5 && && getSettingValue(SettingsOptions::AutoStartMode) < 3) {
getSettingValue(SettingsOptions::AutoStartMode) > 0 &&
getSettingValue(SettingsOptions::AutoStartMode) < 3) {
uint16_t sleepTempDegC; uint16_t sleepTempDegC;
if (getSettingValue(SettingsOptions::TemperatureInF)) { if (getSettingValue(SettingsOptions::TemperatureInF)) {
sleepTempDegC = TipThermoModel::convertFtoC(getSettingValue(SettingsOptions::SleepTemp)); sleepTempDegC = TipThermoModel::convertFtoC(getSettingValue(SettingsOptions::SleepTemp));
@@ -1011,7 +1009,6 @@ void startGUITask(void const *argument) {
currentTempTargetDegC = min(sleepTempDegC, 75); currentTempTargetDegC = min(sleepTempDegC, 75);
} }
BootLogo::handleShowingLogo((uint8_t *)FLASH_LOGOADDR); BootLogo::handleShowingLogo((uint8_t *)FLASH_LOGOADDR);
showWarnings(); showWarnings();