mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2024-12-03 11:24:10 +01:00
LP-182 Set telemetry port baudrate settings or still to default 57600.
This commit is contained in:
parent
8c3beaa28c
commit
705bd2a483
@ -122,8 +122,8 @@ static channelContext localChannel;
|
|||||||
static int32_t transmitLocalData(uint8_t *data, int32_t length);
|
static int32_t transmitLocalData(uint8_t *data, int32_t length);
|
||||||
static void registerLocalObject(UAVObjHandle obj);
|
static void registerLocalObject(UAVObjHandle obj);
|
||||||
static uint32_t localPort();
|
static uint32_t localPort();
|
||||||
static void updateSettings(channelContext *channel);
|
|
||||||
#endif
|
#endif
|
||||||
|
static void updateSettings(channelContext *channel);
|
||||||
|
|
||||||
// OPLink telemetry channel
|
// OPLink telemetry channel
|
||||||
static channelContext radioChannel;
|
static channelContext radioChannel;
|
||||||
@ -298,9 +298,13 @@ int32_t TelemetryInitialize(void)
|
|||||||
localChannel.uavTalkCon = UAVTalkInitialize(&transmitLocalData);
|
localChannel.uavTalkCon = UAVTalkInitialize(&transmitLocalData);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif /* ifdef HAS_RADIO */
|
||||||
// Set channel port handlers
|
// Set channel port handlers
|
||||||
radioChannel.getPort = radioPort;
|
radioChannel.getPort = radioPort;
|
||||||
|
|
||||||
|
// Set the channel port baud rate
|
||||||
|
updateSettings(&radioChannel);
|
||||||
|
|
||||||
// Initialise channel
|
// Initialise channel
|
||||||
TelemetryInitializeChannel(&radioChannel);
|
TelemetryInitializeChannel(&radioChannel);
|
||||||
// Initialise UAVTalk
|
// Initialise UAVTalk
|
||||||
@ -333,7 +337,8 @@ static void registerLocalObject(UAVObjHandle obj)
|
|||||||
EV_NONE);
|
EV_NONE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif /* ifdef HAS_RADIO */
|
||||||
|
|
||||||
static void registerRadioObject(UAVObjHandle obj)
|
static void registerRadioObject(UAVObjHandle obj)
|
||||||
{
|
{
|
||||||
if (UAVObjIsMetaobject(obj)) {
|
if (UAVObjIsMetaobject(obj)) {
|
||||||
@ -650,7 +655,7 @@ static uint32_t localPort()
|
|||||||
{
|
{
|
||||||
return PIOS_COM_TELEM_RF;
|
return PIOS_COM_TELEM_RF;
|
||||||
}
|
}
|
||||||
#endif
|
#endif /* ifdef HAS_RADIO */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Determine the port to be used for communication on the radio channel
|
* Determine the port to be used for communication on the radio channel
|
||||||
@ -688,7 +693,7 @@ static int32_t transmitLocalData(uint8_t *data, int32_t length)
|
|||||||
|
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
#endif
|
#endif /* ifdef HAS_RADIO */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Transmit data buffer to the radioport.
|
* Transmit data buffer to the radioport.
|
||||||
@ -895,7 +900,6 @@ static void updateTelemetryStats()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef HAS_RADIO
|
|
||||||
/**
|
/**
|
||||||
* Update the telemetry settings, called on startup.
|
* Update the telemetry settings, called on startup.
|
||||||
* FIXME: This should be in the TelemetrySettings object. But objects
|
* FIXME: This should be in the TelemetrySettings object. But objects
|
||||||
@ -939,7 +943,6 @@ static void updateSettings(channelContext *channel)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* ifdef HAS_RADIO */
|
|
||||||
/**
|
/**
|
||||||
* @}
|
* @}
|
||||||
* @}
|
* @}
|
||||||
|
Loading…
Reference in New Issue
Block a user