@@ -106,6 +106,8 @@ void uartPutPcmCrc(uint8_t port)
|
||||
}
|
||||
#endif
|
||||
|
||||
#if !defined(INTMODULE_USART) || !defined(EXTMODULE_USART)
|
||||
|
||||
#if defined(PPM_PIN_SERIAL)
|
||||
void pxxPutPcmSerialBit(uint8_t port, uint8_t bit)
|
||||
{
|
||||
@@ -180,7 +182,7 @@ void pxxInitPcmArray(uint8_t port)
|
||||
#if defined(PPM_PIN_SERIAL)
|
||||
modulePulsesData[port].pxx.pcmValue = 0;
|
||||
#else
|
||||
modulePulsesData[port].pxx.rest = 18000;
|
||||
modulePulsesData[port].pxx.rest = PXX_PERIOD_HALF_US;
|
||||
#endif
|
||||
|
||||
modulePulsesData[port].pxx.pcmOnesCount = 0;
|
||||
@@ -211,6 +213,15 @@ void pxxPutPcmCrc(uint8_t port)
|
||||
pxxPutPcmByte(port, pulseValue >> 8);
|
||||
pxxPutPcmByte(port, pulseValue);
|
||||
}
|
||||
#else
|
||||
// those functions should not be used, a link error will occur if wrong
|
||||
void pxxInitPcmArray(uint8_t port);
|
||||
void pxxInitPcmCrc(uint8_t port);
|
||||
void pxxPutPcmByte(uint8_t port, uint8_t byte);
|
||||
void pxxPutPcmHead(uint8_t port);
|
||||
void pxxPutPcmTail(uint8_t port);
|
||||
void pxxPutPcmCrc(uint8_t port);
|
||||
#endif
|
||||
|
||||
#if defined(INTMODULE_USART) || defined(EXTMODULE_USART)
|
||||
inline void initPcmArray(uint8_t port)
|
||||
|
||||
Reference in New Issue
Block a user