mirror of
https://github.com/opentx/opentx.git
synced 2025-07-23 16:25:16 +03:00
Warnings removed
This commit is contained in:
parent
85f3bd4ed0
commit
e900ad6c49
5 changed files with 29 additions and 25 deletions
|
@ -2592,7 +2592,7 @@ void opentxInit(OPENTX_INIT_ARGS)
|
|||
|
||||
startPulses();
|
||||
|
||||
wdt_enable(WDT_500MS);
|
||||
wdt_enable(WDTO_500MS);
|
||||
}
|
||||
|
||||
#if defined(SIMU)
|
||||
|
|
|
@ -1756,6 +1756,4 @@ extern JitterMeter<uint16_t> avgJitter[NUMBER_ANALOG];
|
|||
#endif
|
||||
#endif
|
||||
|
||||
#define WDT_500MS 500
|
||||
|
||||
#endif // _OPENTX_H_
|
||||
|
|
|
@ -292,8 +292,12 @@ void SERIAL_Init(void) {
|
|||
// set 8N1
|
||||
UCSR0B = 0 | (0 << RXCIE0) | (0 << TXCIE0) | (0 << UDRIE0) | (0 << RXEN0) | (0 << TXEN0) | (0 << UCSZ02);
|
||||
UCSR0C = 0 | (1 << UCSZ01) | (1 << UCSZ00);
|
||||
while (UCSR0A & (1 << RXC0))
|
||||
|
||||
#if !defined(SIMU)
|
||||
while (UCSR0A & (1 << RXC0)) {
|
||||
UDR0; // flush receive buffer
|
||||
}
|
||||
#endif
|
||||
|
||||
SERIAL_EnableTXD();
|
||||
SERIAL_EnableRXD();
|
||||
|
|
|
@ -175,6 +175,7 @@ extern uint32_t rotencSpeed;
|
|||
void checkRotaryEncoder(void);
|
||||
|
||||
// WDT driver
|
||||
#define WDTO_500MS 500
|
||||
#define wdt_disable()
|
||||
void watchdogInit(unsigned int duration);
|
||||
#if defined(WATCHDOG_DISABLED) || defined(SIMU)
|
||||
|
|
|
@ -234,6 +234,7 @@ void checkRotaryEncoder(void);
|
|||
#endif
|
||||
|
||||
// WDT driver
|
||||
#define WDTO_500MS 500
|
||||
#if defined(WATCHDOG_DISABLED) || defined(SIMU)
|
||||
#define wdt_enable(x)
|
||||
#define wdt_reset()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue