Adding a FIXME regarding changing serialrx_provider at runtime.
This commit is contained in:
parent
a2b232e805
commit
bcedbd77fb
|
@ -172,7 +172,15 @@ void serialRxInit(rxConfig_t *rxConfig)
|
||||||
|
|
||||||
bool isSerialRxFrameComplete(rxConfig_t *rxConfig)
|
bool isSerialRxFrameComplete(rxConfig_t *rxConfig)
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* FIXME: Each of the xxxxFrameComplete() methods MUST be able to survive being called without the
|
||||||
|
* corresponding xxxInit() method having been called first.
|
||||||
|
*
|
||||||
|
* This situation arises when the cli or the msp changes the value of rxConfig->serialrx_provider
|
||||||
|
*
|
||||||
|
* A solution is for the ___Init() to configure the serialRxFrameComplete function pointer which
|
||||||
|
* should be used instead of the switch statement below.
|
||||||
|
*/
|
||||||
switch (rxConfig->serialrx_provider) {
|
switch (rxConfig->serialrx_provider) {
|
||||||
case SERIALRX_SPEKTRUM1024:
|
case SERIALRX_SPEKTRUM1024:
|
||||||
case SERIALRX_SPEKTRUM2048:
|
case SERIALRX_SPEKTRUM2048:
|
||||||
|
|
Loading…
Reference in New Issue