mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-29 14:52:12 +01:00
OP-932 Allows configuring the Revo as coordinator.
This commit is contained in:
parent
6386b12026
commit
bab69401b9
@ -737,6 +737,7 @@ void PIOS_Board_Init(void)
|
||||
oplinkStatus.BoardRevision = bdinfo->board_rev;
|
||||
|
||||
/* Is the radio turned on? */
|
||||
bool is_coordinator = (oplinkSettings.Coordinator == OPLINKSETTINGS_COORDINATOR_TRUE);
|
||||
bool is_oneway = (oplinkSettings.OneWay == OPLINKSETTINGS_ONEWAY_TRUE);
|
||||
bool ppm_mode = (oplinkSettings.PPM == OPLINKSETTINGS_PPM_TRUE);
|
||||
bool ppm_only = (oplinkSettings.PPMOnly == OPLINKSETTINGS_PPMONLY_TRUE);
|
||||
@ -783,7 +784,7 @@ void PIOS_Board_Init(void)
|
||||
}
|
||||
|
||||
/* Set the radio configuration parameters. */
|
||||
PIOS_RFM22B_SetChannelConfig(pios_rfm22b_id, datarate, oplinkSettings.MinChannel, oplinkSettings.MaxChannel, oplinkSettings.ChannelSet, false, is_oneway, ppm_mode, ppm_only);
|
||||
PIOS_RFM22B_SetChannelConfig(pios_rfm22b_id, datarate, oplinkSettings.MinChannel, oplinkSettings.MaxChannel, oplinkSettings.ChannelSet, is_coordinator, is_oneway, ppm_mode, ppm_only);
|
||||
PIOS_RFM22B_SetCoordinatorID(pios_rfm22b_id, oplinkSettings.CoordID);
|
||||
|
||||
/* Set the PPM callback if we should be receiving PPM. */
|
||||
|
@ -246,7 +246,6 @@ void ConfigPipXtremeWidget::updateSettings(UAVObject *object)
|
||||
m_oplink->VCPPortLabel->setVisible(false);
|
||||
m_oplink->FlexiIOPort->setVisible(false);
|
||||
m_oplink->FlexiIOPortLabel->setVisible(false);
|
||||
m_oplink->Coordinator->setVisible(false);
|
||||
m_oplink->PPM->setVisible(true);
|
||||
break;
|
||||
case 0x03: // OPLinkMini
|
||||
@ -258,7 +257,6 @@ void ConfigPipXtremeWidget::updateSettings(UAVObject *object)
|
||||
m_oplink->VCPPortLabel->setVisible(true);
|
||||
m_oplink->FlexiIOPort->setVisible(false);
|
||||
m_oplink->FlexiIOPortLabel->setVisible(false);
|
||||
m_oplink->Coordinator->setVisible(true);
|
||||
m_oplink->PPM->setVisible(false);
|
||||
break;
|
||||
case 0x0A:
|
||||
@ -270,7 +268,6 @@ void ConfigPipXtremeWidget::updateSettings(UAVObject *object)
|
||||
m_oplink->VCPPortLabel->setVisible(true);
|
||||
m_oplink->FlexiIOPort->setVisible(true);
|
||||
m_oplink->FlexiIOPortLabel->setVisible(true);
|
||||
m_oplink->Coordinator->setVisible(true);
|
||||
m_oplink->PPM->setVisible(false);
|
||||
break;
|
||||
default:
|
||||
|
Loading…
x
Reference in New Issue
Block a user