mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-18 03:52:11 +01:00
Merge remote-tracking branch 'raid/Brian-PipXtreme-V2' into Brian-PipXtreme-V2
This commit is contained in:
commit
a38e6eda5d
@ -80,10 +80,7 @@ typedef struct {
|
||||
xTaskHandle sendPacketTaskHandle;
|
||||
xTaskHandle sendDataTaskHandle;
|
||||
xTaskHandle radioStatusTaskHandle;
|
||||
|
||||
// The com ports
|
||||
uint32_t com_port;
|
||||
uint32_t radio_port;
|
||||
xTaskHandle transparentCommTaskHandle;
|
||||
|
||||
// The UAVTalk connection on the com side.
|
||||
UAVTalkConnection inUAVTalkCon;
|
||||
@ -100,6 +97,10 @@ typedef struct {
|
||||
uint32_t radioTxErrors;
|
||||
uint32_t radioTxRetries;
|
||||
uint32_t radioRxErrors;
|
||||
uint32_t UAVTalkErrors;
|
||||
uint32_t packetErrors;
|
||||
uint16_t txBytes;
|
||||
uint16_t rxBytes;
|
||||
|
||||
// The destination ID
|
||||
uint32_t destination_id;
|
||||
@ -128,6 +129,7 @@ static void comUAVTalkTask(void *parameters);
|
||||
static void radioReceiveTask(void *parameters);
|
||||
static void sendPacketTask(void *parameters);
|
||||
static void sendDataTask(void *parameters);
|
||||
static void transparentCommTask(void * parameters);
|
||||
static void radioStatusTask(void *parameters);
|
||||
static int32_t transmitData(uint8_t * data, int32_t length);
|
||||
static int32_t transmitPacket(PHPacketHandle packet);
|
||||
@ -137,6 +139,7 @@ static void PPMHandler(uint16_t *channels);
|
||||
static BufferedReadHandle BufferedReadInit(uint32_t com_port, uint16_t buffer_length);
|
||||
static bool BufferedRead(BufferedReadHandle h, uint8_t *value, uint32_t timeout_ms);
|
||||
static void BufferedReadSetCom(BufferedReadHandle h, uint32_t com_port);
|
||||
static void updateSettings();
|
||||
|
||||
// ****************
|
||||
// Private variables
|
||||
@ -153,12 +156,16 @@ static int32_t RadioComBridgeStart(void)
|
||||
if(data) {
|
||||
// Start the tasks
|
||||
xTaskCreate(comUAVTalkTask, (signed char *)"ComUAVTalk", STACK_SIZE_BYTES/2, NULL, TASK_PRIORITY + 2, &(data->comUAVTalkTaskHandle));
|
||||
if(PIOS_COM_TRANS_COM)
|
||||
xTaskCreate(transparentCommTask, (signed char *)"transparentComm", STACK_SIZE_BYTES/2, NULL, TASK_PRIORITY + 2, &(data->transparentCommTaskHandle));
|
||||
xTaskCreate(radioReceiveTask, (signed char *)"RadioReceive", STACK_SIZE_BYTES/2, NULL, TASK_PRIORITY, &(data->radioReceiveTaskHandle));
|
||||
xTaskCreate(sendPacketTask, (signed char *)"SendPacketTask", STACK_SIZE_BYTES/2, NULL, TASK_PRIORITY, &(data->sendPacketTaskHandle));
|
||||
xTaskCreate(sendDataTask, (signed char *)"SendDataTask", STACK_SIZE_BYTES/2, NULL, TASK_PRIORITY, &(data->sendDataTaskHandle));
|
||||
xTaskCreate(radioStatusTask, (signed char *)"RadioStatus", STACK_SIZE_BYTES/2, NULL, TASK_PRIORITY, &(data->radioStatusTaskHandle));
|
||||
#ifdef PIOS_INCLUDE_WDG
|
||||
PIOS_WDG_RegisterFlag(PIOS_WDG_COMUAVTALK);
|
||||
if(PIOS_COM_TRANS_COM)
|
||||
PIOS_WDG_RegisterFlag(PIOS_WDG_TRANSCOMM);
|
||||
PIOS_WDG_RegisterFlag(PIOS_WDG_RADIORECEIVE);
|
||||
PIOS_WDG_RegisterFlag(PIOS_WDG_SENDPACKET);
|
||||
PIOS_WDG_RegisterFlag(PIOS_WDG_SENDDATA);
|
||||
@ -186,14 +193,7 @@ static int32_t RadioComBridgeInitialize(void)
|
||||
GCSReceiverInitialize();
|
||||
PipXStatusInitialize();
|
||||
ObjectPersistenceInitialize();
|
||||
|
||||
// Get the settings.
|
||||
PipXSettingsData pipxSettings;
|
||||
PipXSettingsGet(&pipxSettings);
|
||||
|
||||
// TODO: Get from settings object
|
||||
data->com_port = PIOS_COM_BRIDGE_COM;
|
||||
data->radio_port = PIOS_COM_BRIDGE_RADIO;
|
||||
updateSettings();
|
||||
|
||||
// Initialise UAVTalk
|
||||
data->inUAVTalkCon = UAVTalkInitialize(0);
|
||||
@ -203,10 +203,6 @@ static int32_t RadioComBridgeInitialize(void)
|
||||
data->sendPacketQueue = xQueueCreate(PACKET_QUEUE_SIZE, sizeof(PHPacketHandle));
|
||||
data->objEventQueue = xQueueCreate(PACKET_QUEUE_SIZE, sizeof(UAVObjEvent));
|
||||
|
||||
// Initialize the destination ID
|
||||
data->destination_id = pipxSettings.PairID ? pipxSettings.PairID : 0xffffffff;
|
||||
DEBUG_PRINTF(2, "PairID: %x\n\r", data->destination_id);
|
||||
|
||||
// Initialize the statistics.
|
||||
data->radioTxErrors = 0;
|
||||
data->radioTxRetries = 0;
|
||||
@ -214,6 +210,8 @@ static int32_t RadioComBridgeInitialize(void)
|
||||
data->comTxErrors = 0;
|
||||
data->comTxRetries = 0;
|
||||
data->comRxErrors = 0;
|
||||
data->UAVTalkErrors = 0;
|
||||
data->packetErrors = 0;
|
||||
|
||||
// Register the callbacks with the packet handler
|
||||
PHRegisterOutputStream(pios_packet_handler, transmitPacket);
|
||||
@ -236,6 +234,7 @@ static int32_t RadioComBridgeInitialize(void)
|
||||
// Configure our UAVObjects for updates.
|
||||
UAVObjConnectQueue(UAVObjGetByName("PipXStatus"), data->objEventQueue, EV_UPDATED | EV_UPDATED_MANUAL | EV_UPDATE_REQ);
|
||||
UAVObjConnectQueue(UAVObjGetByName("GCSReceiver"), data->objEventQueue, EV_UPDATED | EV_UPDATED_MANUAL | EV_UPDATE_REQ);
|
||||
UAVObjConnectQueue(UAVObjGetByName("ObjectPersistence"), data->objEventQueue, EV_UPDATED | EV_UPDATED_MANUAL);
|
||||
|
||||
return 0;
|
||||
}
|
||||
@ -249,7 +248,7 @@ static void comUAVTalkTask(void *parameters)
|
||||
PHPacketHandle p = NULL;
|
||||
|
||||
// Create the buffered reader.
|
||||
BufferedReadHandle f = BufferedReadInit(data->com_port, TEMP_BUFFER_SIZE);
|
||||
BufferedReadHandle f = BufferedReadInit(PIOS_COM_UAVTALK, TEMP_BUFFER_SIZE);
|
||||
|
||||
while (1) {
|
||||
|
||||
@ -258,18 +257,25 @@ static void comUAVTalkTask(void *parameters)
|
||||
PIOS_WDG_UpdateFlag(PIOS_WDG_COMUAVTALK);
|
||||
#endif /* PIOS_INCLUDE_WDG */
|
||||
|
||||
// Receive from USB HID if available, otherwise UAVTalk com if it's available.
|
||||
#if defined(PIOS_INCLUDE_USB)
|
||||
// Determine input port (USB takes priority over telemetry port)
|
||||
if (PIOS_USB_CheckAvailable(0) && PIOS_COM_TELEM_USB)
|
||||
BufferedReadSetCom(f, PIOS_COM_TELEM_USB);
|
||||
if (PIOS_USB_CheckAvailable(0) && PIOS_COM_USB_HID)
|
||||
BufferedReadSetCom(f, PIOS_COM_USB_HID);
|
||||
else
|
||||
#endif /* PIOS_INCLUDE_USB */
|
||||
BufferedReadSetCom(f, data->com_port);
|
||||
{
|
||||
if (PIOS_COM_UAVTALK)
|
||||
BufferedReadSetCom(f, PIOS_COM_UAVTALK);
|
||||
else
|
||||
vTaskDelay(5);
|
||||
}
|
||||
|
||||
// Read the next byte
|
||||
uint8_t rx_byte;
|
||||
if(!BufferedRead(f, &rx_byte, MAX_PORT_DELAY))
|
||||
continue;
|
||||
data->txBytes++;
|
||||
|
||||
// Get a TX packet from the packet handler if required.
|
||||
if (p == NULL)
|
||||
@ -287,7 +293,7 @@ static void comUAVTalkTask(void *parameters)
|
||||
if (p == NULL)
|
||||
{
|
||||
DEBUG_PRINTF(2, "Packet dropped!\n\r");
|
||||
return;
|
||||
continue;
|
||||
}
|
||||
|
||||
// Initialize the packet.
|
||||
@ -307,61 +313,76 @@ static void comUAVTalkTask(void *parameters)
|
||||
UAVTalkRxState state = UAVTalkProcessInputStreamQuiet(data->inUAVTalkCon, rx_byte);
|
||||
UAVTalkConnectionData *connection = (UAVTalkConnectionData*)(data->inUAVTalkCon);
|
||||
UAVTalkInputProcessor *iproc = &(connection->iproc);
|
||||
|
||||
if (state == UAVTALK_STATE_COMPLETE) {
|
||||
|
||||
// Is this a local UAVObject?
|
||||
if (iproc->obj != NULL)
|
||||
{
|
||||
// We treat the ObjectPersistance object differently
|
||||
// We treat the ObjectPersistence object differently
|
||||
if(iproc->objId == OBJECTPERSISTENCE_OBJID)
|
||||
{
|
||||
// Unpack object, if the instance does not exist it will be created!
|
||||
UAVObjUnpack(iproc->obj, iproc->instId, connection->rxBuffer);
|
||||
|
||||
// Get the ObjectPersistance object.
|
||||
// Get the ObjectPersistence object.
|
||||
ObjectPersistenceData obj_per;
|
||||
ObjectPersistenceGet(&obj_per);
|
||||
|
||||
// Is this concerning or setting object?
|
||||
if (obj_per.ObjectID == PIPXSETTINGS_OBJID)
|
||||
{
|
||||
// Queue up the ACK.
|
||||
UAVObjEvent ev;
|
||||
ev.obj = iproc->obj;
|
||||
ev.instId = 0;
|
||||
ev.instId = iproc->instId;
|
||||
ev.event = EV_SEND_ACK;
|
||||
xQueueSend(data->objEventQueue, &ev, MAX_PORT_DELAY);
|
||||
|
||||
// Is this a save, load, or delete?
|
||||
bool success = true;
|
||||
switch (obj_per.Operation)
|
||||
{
|
||||
case OBJECTPERSISTENCE_OPERATION_LOAD:
|
||||
DEBUG_PRINTF(2, "Load\n\r");
|
||||
break;
|
||||
case OBJECTPERSISTENCE_OPERATION_SAVE:
|
||||
#if defined(PIOS_INCLUDE_FLASH_EEPROM)
|
||||
{
|
||||
#if defined(PIOS_INCLUDE_FLASH_EEPROM)
|
||||
// Load the settings.
|
||||
PipXSettingsData pipxSettings;
|
||||
if (PIOS_EEPROM_Load((uint8_t*)&pipxSettings, sizeof(PipXSettingsData)) == 0)
|
||||
PipXSettingsSet(&pipxSettings);
|
||||
else
|
||||
success = false;
|
||||
#endif
|
||||
break;
|
||||
}
|
||||
case OBJECTPERSISTENCE_OPERATION_SAVE:
|
||||
{
|
||||
#if defined(PIOS_INCLUDE_FLASH_EEPROM)
|
||||
// Save the settings.
|
||||
PipXSettingsData pipxSettings;
|
||||
PipXSettingsGet(&pipxSettings);
|
||||
if (PIOS_EEPROM_Save((uint8_t*)&pipxSettings, sizeof(PipXSettingsData)) != 0)
|
||||
ev.event = EV_SEND_NACK;
|
||||
int32_t ret = PIOS_EEPROM_Save((uint8_t*)&pipxSettings, sizeof(PipXSettingsData));
|
||||
if (ret != 0)
|
||||
success = false;
|
||||
#endif
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
case OBJECTPERSISTENCE_OPERATION_DELETE:
|
||||
DEBUG_PRINTF(2, "Delete\n\r");
|
||||
break;
|
||||
default:
|
||||
DEBUG_PRINTF(2, "Other\n\r");
|
||||
break;
|
||||
}
|
||||
if (success == true)
|
||||
{
|
||||
obj_per.Operation = OBJECTPERSISTENCE_OPERATION_COMPLETED;
|
||||
ObjectPersistenceSet(&obj_per);
|
||||
}
|
||||
|
||||
// Queue up the ACK/NACK
|
||||
xQueueSend(data->objEventQueue, &ev, MAX_PORT_DELAY);
|
||||
// Release the packet, since we don't need it.
|
||||
PHReleaseTXPacket(pios_packet_handler, p);
|
||||
}
|
||||
else {
|
||||
else
|
||||
{
|
||||
// Otherwise, queue the packet for transmission.
|
||||
xQueueSend(data->sendPacketQueue, &p, MAX_PORT_DELAY);
|
||||
p = NULL;
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -381,36 +402,48 @@ static void comUAVTalkTask(void *parameters)
|
||||
xQueueSend(data->objEventQueue, &ev, MAX_PORT_DELAY);
|
||||
break;
|
||||
case UAVTALK_TYPE_OBJ_ACK:
|
||||
// Queue up an ACK
|
||||
ev.event = EV_SEND_ACK;
|
||||
UAVObjUnpack(iproc->obj, iproc->instId, connection->rxBuffer);
|
||||
if (UAVObjUnpack(iproc->obj, iproc->instId, connection->rxBuffer) == 0)
|
||||
{
|
||||
// Queue up an ACK
|
||||
ev.event = EV_SEND_ACK;
|
||||
xQueueSend(data->objEventQueue, &ev, MAX_PORT_DELAY);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
// Release the packet, since we don't need it.
|
||||
PHReleaseTXPacket(pios_packet_handler, p);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Queue the packet for transmission.
|
||||
xQueueSend(data->sendPacketQueue, &p, MAX_PORT_DELAY);
|
||||
p = NULL;
|
||||
}
|
||||
p = NULL;
|
||||
|
||||
} else if(state == UAVTALK_STATE_ERROR) {
|
||||
DEBUG_PRINTF(1, "UAVTalk FAILED!\n\r");
|
||||
|
||||
// Release the packet and start over again.
|
||||
PHReleaseTXPacket(pios_packet_handler, p);
|
||||
p = NULL;
|
||||
data->UAVTalkErrors++;
|
||||
|
||||
// Send a NACK if required.
|
||||
if((iproc->obj) && (iproc->type == UAVTALK_TYPE_ACK))
|
||||
if((iproc->obj) && (iproc->type == UAVTALK_TYPE_OBJ_ACK))
|
||||
{
|
||||
// Queue up a NACK
|
||||
UAVObjEvent ev;
|
||||
ev.obj = iproc->obj;
|
||||
// Queue up a NACK
|
||||
ev.event = EV_SEND_NACK;
|
||||
xQueueSend(data->objEventQueue, &ev, MAX_PORT_DELAY);
|
||||
|
||||
// Release the packet and start over again.
|
||||
PHReleaseTXPacket(pios_packet_handler, p);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Transmit the packet anyway...
|
||||
xQueueSend(data->sendPacketQueue, &p, MAX_PORT_DELAY);
|
||||
}
|
||||
p = NULL;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -442,9 +475,10 @@ static void radioReceiveTask(void *parameters)
|
||||
}
|
||||
|
||||
// Receive data from the radio port
|
||||
rx_bytes = PIOS_COM_ReceiveBuffer(data->radio_port, (uint8_t*)p, PIOS_PH_MAX_PACKET, MAX_PORT_DELAY);
|
||||
rx_bytes = PIOS_COM_ReceiveBuffer(PIOS_COM_RADIO, (uint8_t*)p, PIOS_PH_MAX_PACKET, MAX_PORT_DELAY);
|
||||
if(rx_bytes == 0)
|
||||
continue;
|
||||
data->rxBytes += rx_bytes;
|
||||
|
||||
// Verify that the packet is valid and pass it on.
|
||||
if(PHVerifyPacket(pios_packet_handler, p, rx_bytes) > 0) {
|
||||
@ -453,7 +487,10 @@ static void radioReceiveTask(void *parameters)
|
||||
ev.event = EV_PACKET_RECEIVED;
|
||||
xQueueSend(data->objEventQueue, &ev, portMAX_DELAY);
|
||||
} else
|
||||
{
|
||||
data->packetErrors++;
|
||||
PHReceivePacket(pios_packet_handler, p, false);
|
||||
}
|
||||
p = NULL;
|
||||
}
|
||||
}
|
||||
@ -523,44 +560,51 @@ static void sendDataTask(void *parameters)
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef NEVER
|
||||
/**
|
||||
* The com to radio bridge task.
|
||||
*/
|
||||
static void com2RadioBridgeTask(void * parameters)
|
||||
static void transparentCommTask(void * parameters)
|
||||
{
|
||||
uint32_t rx_bytes = 0;
|
||||
portTickType packet_start_time = 0;
|
||||
uint32_t timeout = 250;
|
||||
uint32_t inputPort;
|
||||
PHPacketHandle p = NULL;
|
||||
|
||||
/* Handle usart/usb -> radio direction */
|
||||
while (1) {
|
||||
|
||||
#if defined(PIOS_INCLUDE_USB)
|
||||
// Determine input port (USB takes priority over telemetry port)
|
||||
if (PIOS_USB_CheckAvailable(0) && PIOS_COM_TELEM_USB)
|
||||
inputPort = PIOS_COM_TELEM_USB;
|
||||
else
|
||||
#endif /* PIOS_INCLUDE_USB */
|
||||
inputPort = data->com_port;
|
||||
|
||||
#ifdef PIOS_INCLUDE_WDG
|
||||
// Update the watchdog timer.
|
||||
PIOS_WDG_UpdateFlag(PIOS_WDG_COMRADIO);
|
||||
PIOS_WDG_UpdateFlag(PIOS_WDG_TRANSCOMM);
|
||||
#endif /* PIOS_INCLUDE_WDG */
|
||||
|
||||
// Receive data from the com port
|
||||
uint32_t cur_rx_bytes = PIOS_COM_ReceiveBuffer(inputPort, data->com2radio_buf +
|
||||
rx_bytes, BRIDGE_BUF_LEN - rx_bytes, timeout);
|
||||
// Get a TX packet from the packet handler if required.
|
||||
if (p == NULL)
|
||||
{
|
||||
p = PHGetTXPacket(pios_packet_handler);
|
||||
|
||||
// Pass the new data through UAVTalk
|
||||
for (uint8_t i = 0; i < cur_rx_bytes; i++)
|
||||
UAVTalkProcessInputStreamQuiet(data->inUAVTalkCon, *(data->com2radio_buf + i + rx_bytes));
|
||||
// No packets available?
|
||||
if (p == NULL)
|
||||
{
|
||||
// Wait a bit for a packet to come available.
|
||||
vTaskDelay(5);
|
||||
continue;
|
||||
}
|
||||
|
||||
// Initialize the packet.
|
||||
p->header.destination_id = data->destination_id;
|
||||
p->header.source_id = PIOS_RFM22B_DeviceID(pios_rfm22b_id);
|
||||
//p->header.type = PACKET_TYPE_ACKED_DATA;
|
||||
p->header.type = PACKET_TYPE_DATA;
|
||||
p->header.data_size = 0;
|
||||
}
|
||||
|
||||
// Receive data from the com port
|
||||
uint32_t cur_rx_bytes = PIOS_COM_ReceiveBuffer(PIOS_COM_TRANS_COM, p->data + p->header.data_size,
|
||||
PH_MAX_DATA - p->header.data_size, timeout);
|
||||
|
||||
// Do we have an data to send?
|
||||
rx_bytes += cur_rx_bytes;
|
||||
if (rx_bytes > 0) {
|
||||
p->header.data_size += cur_rx_bytes;
|
||||
if (p->header.data_size > 0) {
|
||||
|
||||
// Check how long since last update
|
||||
portTickType cur_sys_time = xTaskGetTickCount();
|
||||
@ -581,36 +625,22 @@ static void com2RadioBridgeTask(void * parameters)
|
||||
}
|
||||
|
||||
// Also send the packet if the size is over the minimum.
|
||||
send_packet |= (rx_bytes > data->min_packet_size);
|
||||
send_packet |= (p->header.data_size > data->min_packet_size);
|
||||
|
||||
// Should we send this packet?
|
||||
if (send_packet)
|
||||
{
|
||||
// Get a TX packet from the packet handler
|
||||
PHPacketHandle p = PHGetTXPacket(pios_packet_handler);
|
||||
|
||||
// Initialize the packet.
|
||||
//p->header.type = PACKET_TYPE_ACKED_DATA;
|
||||
p->header.destination_id = data->destination_id;
|
||||
p->header.source_id = PIOS_RFM22B_DeviceID(pios_rfm22b_id);
|
||||
p->header.type = PACKET_TYPE_DATA;
|
||||
p->header.data_size = rx_bytes;
|
||||
|
||||
// Copy the data into the packet.
|
||||
memcpy(p->data, data->com2radio_buf, rx_bytes);
|
||||
|
||||
// Transmit the packet
|
||||
PHTransmitPacket(pios_packet_handler, p);
|
||||
|
||||
// Reset the timeout
|
||||
timeout = 500;
|
||||
rx_bytes = 0;
|
||||
p = NULL;
|
||||
packet_start_time = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* The stats update task.
|
||||
@ -632,6 +662,12 @@ static void radioStatusTask(void *parameters)
|
||||
pipxStatus.DeviceID = PIOS_RFM22B_DeviceID(pios_rfm22b_id);
|
||||
pipxStatus.RSSI = PIOS_RFM22B_RSSI(pios_rfm22b_id);
|
||||
pipxStatus.Resets = PIOS_RFM22B_Resets(pios_rfm22b_id);
|
||||
pipxStatus.Errors = data->packetErrors;
|
||||
pipxStatus.UAVTalkErrors = data->UAVTalkErrors;
|
||||
pipxStatus.TXRate = (uint16_t)((float)(data->txBytes * 1000) / STATS_UPDATE_PERIOD_MS);
|
||||
data->txBytes = 0;
|
||||
pipxStatus.RXRate = (uint16_t)((float)(data->rxBytes * 1000) / STATS_UPDATE_PERIOD_MS);
|
||||
data->rxBytes = 0;
|
||||
|
||||
// Update the potential pairing contacts
|
||||
for (uint8_t i = 0; i < PIPXSTATUS_PAIRIDS_NUMELEM; ++i)
|
||||
@ -672,13 +708,13 @@ static void radioStatusTask(void *parameters)
|
||||
*/
|
||||
static int32_t transmitData(uint8_t *buf, int32_t length)
|
||||
{
|
||||
uint32_t outputPort = data->com_port;
|
||||
uint32_t outputPort = PIOS_COM_UAVTALK;
|
||||
#if defined(PIOS_INCLUDE_USB)
|
||||
// Determine output port (USB takes priority over telemetry port)
|
||||
if (PIOS_USB_CheckAvailable(0) && PIOS_COM_TELEM_USB)
|
||||
outputPort = PIOS_COM_TELEM_USB;
|
||||
if (PIOS_USB_CheckAvailable(0) && PIOS_COM_USB_HID)
|
||||
outputPort = PIOS_COM_USB_HID;
|
||||
#endif /* PIOS_INCLUDE_USB */
|
||||
return PIOS_COM_SendBufferNonBlocking(outputPort, buf, length);
|
||||
return PIOS_COM_SendBuffer(outputPort, buf, length);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -690,7 +726,7 @@ static int32_t transmitData(uint8_t *buf, int32_t length)
|
||||
*/
|
||||
static int32_t transmitPacket(PHPacketHandle p)
|
||||
{
|
||||
return PIOS_COM_SendBuffer(data->radio_port, (uint8_t*)p, PH_PACKET_SIZE(p));
|
||||
return PIOS_COM_SendBuffer(PIOS_COM_RADIO, (uint8_t*)p, PH_PACKET_SIZE(p));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -700,12 +736,20 @@ static int32_t transmitPacket(PHPacketHandle p)
|
||||
*/
|
||||
static void receiveData(uint8_t *buf, uint8_t len)
|
||||
{
|
||||
uint32_t outputPort = data->com_port;
|
||||
// Packet data should to to transparent com if it's configured,
|
||||
// USB HID if it's connected, otherwise, UAVTalk com if it's configured.
|
||||
uint32_t outputPort = PIOS_COM_TRANS_COM;
|
||||
if (!outputPort)
|
||||
{
|
||||
outputPort = PIOS_COM_UAVTALK;
|
||||
#if defined(PIOS_INCLUDE_USB)
|
||||
// Determine output port (USB takes priority over telemetry port)
|
||||
if (PIOS_USB_CheckAvailable(0) && PIOS_COM_TELEM_USB)
|
||||
outputPort = PIOS_COM_TELEM_USB;
|
||||
if (PIOS_USB_CheckAvailable(0) && PIOS_COM_USB_HID)
|
||||
outputPort = PIOS_COM_USB_HID;
|
||||
#endif /* PIOS_INCLUDE_USB */
|
||||
}
|
||||
if (!outputPort)
|
||||
return;
|
||||
|
||||
// Send the received data to the com port
|
||||
if (PIOS_COM_SendBuffer(outputPort, buf, len) != len)
|
||||
@ -822,3 +866,98 @@ static void BufferedReadSetCom(BufferedReadHandle h, uint32_t com_port)
|
||||
{
|
||||
h->com_port = com_port;
|
||||
}
|
||||
|
||||
/**
|
||||
* Update the telemetry settings, called on startup.
|
||||
* FIXME: This should be in the TelemetrySettings object. But objects
|
||||
* have too much overhead yet. Also the telemetry has no any specific
|
||||
* settings, etc. Thus the HwSettings object which contains the
|
||||
* telemetry port speed is used for now.
|
||||
*/
|
||||
static void updateSettings()
|
||||
{
|
||||
|
||||
// Get the settings.
|
||||
PipXSettingsData pipxSettings;
|
||||
PipXSettingsGet(&pipxSettings);
|
||||
|
||||
// Initialize the destination ID
|
||||
data->destination_id = pipxSettings.PairID ? pipxSettings.PairID : 0xffffffff;
|
||||
DEBUG_PRINTF(2, "PairID: %x\n\r", data->destination_id);
|
||||
|
||||
if (PIOS_COM_TELEMETRY) {
|
||||
switch (pipxSettings.TelemetrySpeed) {
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_2400:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_TELEMETRY, 2400);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_4800:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_TELEMETRY, 4800);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_9600:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_TELEMETRY, 9600);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_19200:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_TELEMETRY, 19200);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_38400:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_TELEMETRY, 38400);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_57600:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_TELEMETRY, 57600);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_115200:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_TELEMETRY, 115200);
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (PIOS_COM_FLEXI) {
|
||||
switch (pipxSettings.FlexiSpeed) {
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_2400:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_FLEXI, 2400);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_4800:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_FLEXI, 4800);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_9600:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_FLEXI, 9600);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_19200:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_FLEXI, 19200);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_38400:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_FLEXI, 38400);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_57600:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_FLEXI, 57600);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_115200:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_FLEXI, 115200);
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (PIOS_COM_VCP) {
|
||||
switch (pipxSettings.VCPSpeed) {
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_2400:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_VCP, 2400);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_4800:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_VCP, 4800);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_9600:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_VCP, 9600);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_19200:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_VCP, 19200);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_38400:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_VCP, 38400);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_57600:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_VCP, 57600);
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYSPEED_115200:
|
||||
PIOS_COM_ChangeBaud(PIOS_COM_VCP, 115200);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -75,6 +75,7 @@ TIM4 | RC In 1 | Servo 3 | Servo 2 | Servo 1
|
||||
#define PIOS_WDG_RADIORECEIVE 0x0002
|
||||
#define PIOS_WDG_SENDPACKET 0x0004
|
||||
#define PIOS_WDG_SENDDATA 0x0008
|
||||
#define PIOS_WDG_TRANSCOMM 0x0010
|
||||
|
||||
//------------------------
|
||||
// TELEMETRY
|
||||
@ -150,23 +151,26 @@ extern uint32_t pios_spi_port_id;
|
||||
//-------------------------
|
||||
#define PIOS_COM_MAX_DEVS 5
|
||||
|
||||
extern uint32_t pios_com_telem_usb_id;
|
||||
extern uint32_t pios_com_vcp_usb_id;
|
||||
extern uint32_t pios_com_usart1_id;
|
||||
extern uint32_t pios_com_usart3_id;
|
||||
extern uint32_t pios_com_usb_hid_id;
|
||||
extern uint32_t pios_com_telemetry_id;
|
||||
extern uint32_t pios_com_flexi_id;
|
||||
extern uint32_t pios_com_vcp_id;
|
||||
extern uint32_t pios_com_uavtalk_com_id;
|
||||
extern uint32_t pios_com_trans_com_id;
|
||||
extern uint32_t pios_com_debug_id;
|
||||
extern uint32_t pios_com_rfm22b_id;
|
||||
#define PIOS_COM_TELEM_SERIAL (pios_com_usart1_id)
|
||||
#define PIOS_COM_FLEXI (pios_com_usart3_id)
|
||||
#define PIOS_COM_TELEM_USB (pios_com_telem_usb_id)
|
||||
#define PIOS_COM_VCP_USB (pios_com_vcp_usb_id)
|
||||
#define PIOS_COM_RFM22B_RF (pios_com_rfm22b_id)
|
||||
#define PIOS_COM_BRIDGE_RADIO PIOS_COM_RFM22B_RF
|
||||
#define PIOS_COM_DEBUG PIOS_COM_FLEXI
|
||||
#define PIOS_COM_BRIDGE_COM PIOS_COM_TELEM_SERIAL
|
||||
#define PIOS_COM_USB_HID (pios_com_usb_hid_id)
|
||||
#define PIOS_COM_TELEMETRY (pios_com_telemetry_id)
|
||||
#define PIOS_COM_FLEXI (pios_com_flexi_id)
|
||||
#define PIOS_COM_VCP (pios_com_vcp_id)
|
||||
#define PIOS_COM_UAVTALK (pios_com_uavtalk_com_id)
|
||||
#define PIOS_COM_TRANS_COM (pios_com_trans_com_id)
|
||||
#define PIOS_COM_DEBUG (pios_com_debug_id)
|
||||
#define PIOS_COM_RADIO (pios_com_rfm22b_id)
|
||||
|
||||
#define DEBUG_LEVEL 2
|
||||
#if DEBUG_LEVEL > 0
|
||||
#define DEBUG_PRINTF(level, ...) if(level <= DEBUG_LEVEL) { PIOS_COM_SendFormattedStringNonBlocking(PIOS_COM_DEBUG, __VA_ARGS__); }
|
||||
#define DEBUG_PRINTF(level, ...) {if(level <= DEBUG_LEVEL && PIOS_COM_DEBUG > 0) { PIOS_COM_SendFormattedStringNonBlocking(PIOS_COM_DEBUG, __VA_ARGS__); }}
|
||||
#else
|
||||
#define DEBUG_PRINTF(...)
|
||||
#endif
|
||||
|
@ -73,7 +73,7 @@ int32_t PIOS_EEPROM_Save(uint8_t *data, uint32_t len)
|
||||
|
||||
// See if we have to write the data.
|
||||
if ((memcmp(data, (uint8_t*)config.base_address, len) == 0) &&
|
||||
(memcmp((uint8_t*)crc, (uint8_t*)config.base_address + size - 4, 4) == 0))
|
||||
(memcmp((uint8_t*)&crc, (uint8_t*)config.base_address + size - 4, 4) == 0))
|
||||
return 0;
|
||||
|
||||
// TODO: Check that the area isn't already erased
|
||||
|
@ -48,12 +48,15 @@
|
||||
#define PIOS_COM_RFM22B_RF_RX_BUF_LEN 192
|
||||
#define PIOS_COM_RFM22B_RF_TX_BUF_LEN 192
|
||||
|
||||
uint32_t pios_com_telem_usb_id;
|
||||
uint32_t pios_com_vcp_usb_id;
|
||||
uint32_t pios_com_usart1_id;
|
||||
uint32_t pios_com_usart3_id;
|
||||
uint32_t pios_com_rfm22b_id;
|
||||
uint32_t pios_rfm22b_id;
|
||||
uint32_t pios_com_usb_hid_id = 0;
|
||||
uint32_t pios_com_telemetry_id;
|
||||
uint32_t pios_com_flexi_id;
|
||||
uint32_t pios_com_vcp_id;
|
||||
uint32_t pios_com_uavtalk_com_id = 0;
|
||||
uint32_t pios_com_trans_com_id = 0;
|
||||
uint32_t pios_com_debug_id = 0;
|
||||
uint32_t pios_com_rfm22b_id = 0;
|
||||
uint32_t pios_rfm22b_id = 0;
|
||||
|
||||
/**
|
||||
* PIOS_Board_Init()
|
||||
@ -136,6 +139,10 @@ void PIOS_Board_Init(void) {
|
||||
#if defined(PIOS_INCLUDE_USB_CDC)
|
||||
|
||||
#if defined(PIOS_INCLUDE_COM)
|
||||
switch (pipxSettings.VCPConfig)
|
||||
{
|
||||
case PIPXSETTINGS_VCPCONFIG_SERIAL:
|
||||
case PIPXSETTINGS_VCPCONFIG_DEBUG:
|
||||
{
|
||||
uint32_t pios_usb_cdc_id;
|
||||
if (PIOS_USB_CDC_Init(&pios_usb_cdc_id, &pios_usb_cdc_cfg, pios_usb_id)) {
|
||||
@ -145,11 +152,27 @@ void PIOS_Board_Init(void) {
|
||||
uint8_t * tx_buffer = (uint8_t *) pvPortMalloc(PIOS_COM_VCP_USB_TX_BUF_LEN);
|
||||
PIOS_Assert(rx_buffer);
|
||||
PIOS_Assert(tx_buffer);
|
||||
if (PIOS_COM_Init(&pios_com_vcp_usb_id, &pios_usb_cdc_com_driver, pios_usb_cdc_id,
|
||||
if (PIOS_COM_Init(&pios_com_vcp_id, &pios_usb_cdc_com_driver, pios_usb_cdc_id,
|
||||
rx_buffer, PIOS_COM_VCP_USB_RX_BUF_LEN,
|
||||
tx_buffer, PIOS_COM_VCP_USB_TX_BUF_LEN)) {
|
||||
PIOS_Assert(0);
|
||||
}
|
||||
switch (pipxSettings.TelemetryConfig)
|
||||
{
|
||||
case PIPXSETTINGS_VCPCONFIG_SERIAL:
|
||||
pios_com_trans_com_id = pios_com_vcp_id;
|
||||
break;
|
||||
case PIPXSETTINGS_VCPCONFIG_UAVTALK:
|
||||
pios_com_uavtalk_com_id = pios_com_vcp_id;
|
||||
break;
|
||||
case PIPXSETTINGS_VCPCONFIG_DEBUG:
|
||||
pios_com_debug_id = pios_com_vcp_id;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case PIPXSETTINGS_VCPCONFIG_DISABLED:
|
||||
break;
|
||||
}
|
||||
#endif /* PIOS_INCLUDE_COM */
|
||||
|
||||
@ -168,7 +191,7 @@ void PIOS_Board_Init(void) {
|
||||
uint8_t * tx_buffer = (uint8_t *) pvPortMalloc(PIOS_COM_TELEM_USB_TX_BUF_LEN);
|
||||
PIOS_Assert(rx_buffer);
|
||||
PIOS_Assert(tx_buffer);
|
||||
if (PIOS_COM_Init(&pios_com_telem_usb_id, &pios_usb_hid_com_driver, pios_usb_hid_id,
|
||||
if (PIOS_COM_Init(&pios_com_usb_hid_id, &pios_usb_hid_com_driver, pios_usb_hid_id,
|
||||
rx_buffer, PIOS_COM_TELEM_USB_RX_BUF_LEN,
|
||||
tx_buffer, PIOS_COM_TELEM_USB_TX_BUF_LEN)) {
|
||||
PIOS_Assert(0);
|
||||
@ -180,25 +203,53 @@ void PIOS_Board_Init(void) {
|
||||
|
||||
#endif /* PIOS_INCLUDE_USB */
|
||||
|
||||
/* Configure USART1 */
|
||||
/* Configure USART1 (telemetry port) */
|
||||
switch (pipxSettings.TelemetryConfig)
|
||||
{
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_SERIAL:
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_UAVTALK:
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_DEBUG:
|
||||
{
|
||||
uint32_t pios_usart1_id;
|
||||
if (PIOS_USART_Init(&pios_usart1_id, &pios_usart_serial_cfg)) {
|
||||
PIOS_Assert(0);
|
||||
}
|
||||
|
||||
uint8_t * rx_buffer = (uint8_t *) pvPortMalloc(PIOS_COM_SERIAL_RX_BUF_LEN);
|
||||
uint8_t * tx_buffer = (uint8_t *) pvPortMalloc(PIOS_COM_SERIAL_TX_BUF_LEN);
|
||||
PIOS_Assert(rx_buffer);
|
||||
PIOS_Assert(tx_buffer);
|
||||
if (PIOS_COM_Init(&pios_com_usart1_id, &pios_usart_com_driver, pios_usart1_id,
|
||||
if (PIOS_COM_Init(&pios_com_telemetry_id, &pios_usart_com_driver, pios_usart1_id,
|
||||
rx_buffer, PIOS_COM_SERIAL_RX_BUF_LEN,
|
||||
tx_buffer, PIOS_COM_SERIAL_TX_BUF_LEN)) {
|
||||
PIOS_Assert(0);
|
||||
}
|
||||
switch (pipxSettings.TelemetryConfig)
|
||||
{
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_SERIAL:
|
||||
pios_com_trans_com_id = pios_com_telemetry_id;
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_UAVTALK:
|
||||
pios_com_uavtalk_com_id = pios_com_telemetry_id;
|
||||
break;
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_DEBUG:
|
||||
pios_com_debug_id = pios_com_telemetry_id;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_PPM_IN:
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_PPM_OUT:
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_RSSI:
|
||||
case PIPXSETTINGS_TELEMETRYCONFIG_DISABLED:
|
||||
break;
|
||||
}
|
||||
|
||||
/* Configure USART3 */
|
||||
switch (pipxSettings.FlexiConfig)
|
||||
{
|
||||
case PIPXSETTINGS_FLEXICONFIG_SERIAL:
|
||||
case PIPXSETTINGS_FLEXICONFIG_UAVTALK:
|
||||
case PIPXSETTINGS_FLEXICONFIG_DEBUG:
|
||||
{
|
||||
uint32_t pios_usart3_id;
|
||||
if (PIOS_USART_Init(&pios_usart3_id, &pios_usart_telem_flexi_cfg)) {
|
||||
@ -208,11 +259,30 @@ void PIOS_Board_Init(void) {
|
||||
uint8_t * tx_buffer = (uint8_t *) pvPortMalloc(PIOS_COM_FLEXI_TX_BUF_LEN);
|
||||
PIOS_Assert(rx_buffer);
|
||||
PIOS_Assert(tx_buffer);
|
||||
if (PIOS_COM_Init(&pios_com_usart3_id, &pios_usart_com_driver, pios_usart3_id,
|
||||
if (PIOS_COM_Init(&pios_com_flexi_id, &pios_usart_com_driver, pios_usart3_id,
|
||||
rx_buffer, PIOS_COM_FLEXI_RX_BUF_LEN,
|
||||
tx_buffer, PIOS_COM_FLEXI_TX_BUF_LEN)) {
|
||||
PIOS_Assert(0);
|
||||
}
|
||||
switch (pipxSettings.FlexiConfig)
|
||||
{
|
||||
case PIPXSETTINGS_FLEXICONFIG_SERIAL:
|
||||
pios_com_trans_com_id = pios_com_flexi_id;
|
||||
break;
|
||||
case PIPXSETTINGS_FLEXICONFIG_UAVTALK:
|
||||
pios_com_uavtalk_com_id = pios_com_flexi_id;
|
||||
break;
|
||||
case PIPXSETTINGS_FLEXICONFIG_DEBUG:
|
||||
pios_com_debug_id = pios_com_flexi_id;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case PIPXSETTINGS_FLEXICONFIG_PPM_IN:
|
||||
case PIPXSETTINGS_FLEXICONFIG_PPM_OUT:
|
||||
case PIPXSETTINGS_FLEXICONFIG_RSSI:
|
||||
case PIPXSETTINGS_FLEXICONFIG_DISABLED:
|
||||
break;
|
||||
}
|
||||
|
||||
#if defined(PIOS_INCLUDE_RFM22B)
|
||||
|
@ -1389,13 +1389,13 @@ margin:1px;</string>
|
||||
<property name="autoFillBackground">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3" stretch="0">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_31" stretch="0">
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_6">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_61">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_31">
|
||||
<item>
|
||||
<widget class="QLabel" name="label_5">
|
||||
<widget class="QLabel" name="label_51">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
@ -1417,7 +1417,7 @@ margin:1px;</string>
|
||||
<widget class="QComboBox" name="groundVehicleType"/>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_3">
|
||||
<spacer name="horizontalSpacer_31">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
@ -1432,7 +1432,7 @@ margin:1px;</string>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_23">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_33">
|
||||
<item>
|
||||
<widget class="QLabel" name="label_7">
|
||||
<property name="font">
|
||||
@ -1462,9 +1462,9 @@ margin:1px;</string>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_41">
|
||||
<item>
|
||||
<widget class="QGroupBox" name="groupBox_2">
|
||||
<widget class="QGroupBox" name="groupBox_7">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
@ -1480,7 +1480,7 @@ margin:1px;</string>
|
||||
<property name="title">
|
||||
<string>Output channel asignmets</string>
|
||||
</property>
|
||||
<layout class="QFormLayout" name="formLayout_3">
|
||||
<layout class="QFormLayout" name="formLayout_5">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="gvEngineLabel">
|
||||
<property name="minimumSize">
|
||||
@ -1644,11 +1644,11 @@ margin:1px;</string>
|
||||
<property name="title">
|
||||
<string>Differential Steering Mix</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_13">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_33">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_8">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_30">
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_14">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_34">
|
||||
<item>
|
||||
<widget class="QLabel" name="differentialSteeringLabel1">
|
||||
<property name="minimumSize">
|
||||
@ -1685,7 +1685,7 @@ margin:1px;</string>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_15">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_35">
|
||||
<item>
|
||||
<widget class="QLabel" name="differentialSteeringLabel2">
|
||||
<property name="minimumSize">
|
||||
@ -1727,7 +1727,7 @@ margin:1px;</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_4">
|
||||
<spacer name="horizontalSpacer_24">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
@ -1750,7 +1750,7 @@ margin:1px;</string>
|
||||
<property name="title">
|
||||
<string>Front throttle curve</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_16">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_36">
|
||||
<item>
|
||||
<widget class="MixerCurveWidget" name="groundVehicleThrottle1" native="true">
|
||||
<property name="sizePolicy">
|
||||
@ -1807,7 +1807,7 @@ margin:1px;</string>
|
||||
<property name="title">
|
||||
<string>Rear throttle curve</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_17">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_37">
|
||||
<item>
|
||||
<widget class="MixerCurveWidget" name="groundVehicleThrottle2" native="true">
|
||||
<property name="sizePolicy">
|
||||
@ -1850,7 +1850,7 @@ margin:1px;</string>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<spacer name="verticalSpacer_1">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
@ -1863,9 +1863,9 @@ margin:1px;</string>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_13">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_28">
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_11">
|
||||
<spacer name="horizontalSpacer_21">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
|
109
ground/openpilotgcs/src/plugins/config/configpipxtremewidget.cpp
Executable file → Normal file
109
ground/openpilotgcs/src/plugins/config/configpipxtremewidget.cpp
Executable file → Normal file
@ -45,9 +45,49 @@ ConfigPipXtremeWidget::ConfigPipXtremeWidget(QWidget *parent) : ConfigTaskWidget
|
||||
qDebug() << "Error: Object is unknown (PipXStatus).";
|
||||
}
|
||||
|
||||
// Connect to the PipXSettings object updates
|
||||
pipxSettingsObj = dynamic_cast<UAVDataObject*>(objManager->getObject("PipXSettings"));
|
||||
if (pipxSettingsObj != NULL ) {
|
||||
connect(pipxSettingsObj, SIGNAL(objectUpdated(UAVObject*)), this, SLOT(updateSettings(UAVObject*)));
|
||||
} else {
|
||||
qDebug() << "Error: Object is unknown (PipXSettings).";
|
||||
}
|
||||
|
||||
addApplySaveButtons(m_pipx->Apply, m_pipx->Save);
|
||||
connect(m_pipx->Apply, SIGNAL(clicked()), this, SLOT(applySettings()));
|
||||
connect(m_pipx->Save, SIGNAL(clicked()), this, SLOT(saveSettings()));
|
||||
//connect(m_pipx->Apply, SIGNAL(clicked()), this, SLOT(applySettings()));
|
||||
//connect(m_pipx->Save, SIGNAL(clicked()), this, SLOT(saveSettings()));
|
||||
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "TelemetryConfig", m_pipx->TelemPortConfig);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "TelemetrySpeed", m_pipx->TelemPortSpeed);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "FlexiConfig", m_pipx->FlexiPortConfig);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "FlexiSpeed", m_pipx->FlexiPortSpeed);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "VCPConfig", m_pipx->VCPConfig);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "VCPSpeed", m_pipx->VCPSpeed);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "RFSpeed", m_pipx->MaxRFDatarate);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "MaxRFPower", m_pipx->MaxRFTxPower);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "SendTimeout", m_pipx->SendTimeout);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "MinPacketSize", m_pipx->MinPacketSize);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "FrequencyCalibration", m_pipx->FrequencyCalibration);
|
||||
addUAVObjectToWidgetRelation("PipXSettings", "Frequency", m_pipx->Frequency);
|
||||
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "MinFrequency", m_pipx->MinFrequency);
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "MaxFrequency", m_pipx->MaxFrequency);
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "FrequencyStepSize", m_pipx->FrequencyStepSize);
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "AFC", m_pipx->RxAFC);
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "Retries", m_pipx->Retries);
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "Errors", m_pipx->Errors);
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "UAVTalkErrors", m_pipx->UAVTalkErrors);
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "Resets", m_pipx->Resets);
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "RXRate", m_pipx->RXRate);
|
||||
addUAVObjectToWidgetRelation("PipXStatus", "TXRate", m_pipx->TXRate);
|
||||
|
||||
// Create the timer that is used to timeout the connection to the PipX.
|
||||
timeOut = new QTimer(this);
|
||||
connect(timeOut, SIGNAL(timeout()),this,SLOT(disconnected()));
|
||||
|
||||
// Request and update of the setting object.
|
||||
settingsUpdated = false;
|
||||
pipxSettingsObj->requestUpdate();
|
||||
}
|
||||
|
||||
ConfigPipXtremeWidget::~ConfigPipXtremeWidget()
|
||||
@ -81,7 +121,7 @@ void ConfigPipXtremeWidget::applySettings()
|
||||
|
||||
void ConfigPipXtremeWidget::saveSettings()
|
||||
{
|
||||
applySettings();
|
||||
//applySettings();
|
||||
UAVObject *obj = PipXSettings::GetInstance(getObjectManager());
|
||||
saveObjectToSD(obj);
|
||||
}
|
||||
@ -89,11 +129,15 @@ void ConfigPipXtremeWidget::saveSettings()
|
||||
/*!
|
||||
\brief Called by updates to @PipXStatus
|
||||
*/
|
||||
void ConfigPipXtremeWidget::updateStatus(UAVObject *object) {
|
||||
void ConfigPipXtremeWidget::updateStatus(UAVObject *object)
|
||||
{
|
||||
|
||||
// Get the settings object.
|
||||
PipXSettings *pipxSettings = PipXSettings::GetInstance(getObjectManager());
|
||||
PipXSettings::DataFields pipxSettingsData = pipxSettings->getData();
|
||||
// Restart the disconnection timer.
|
||||
timeOut->start(5000);
|
||||
|
||||
// Request and update of the setting object if we haven't received it yet.
|
||||
if (!settingsUpdated)
|
||||
pipxSettingsObj->requestUpdate();
|
||||
|
||||
// Update the detected devices.
|
||||
UAVObjectField* pairIdField = object->getField("PairIDs");
|
||||
@ -101,22 +145,22 @@ void ConfigPipXtremeWidget::updateStatus(UAVObject *object) {
|
||||
quint32 pairid1 = pairIdField->getValue(0).toUInt();
|
||||
m_pipx->PairID1->setText(QString::number(pairid1, 16).toUpper());
|
||||
m_pipx->PairID1->setEnabled(false);
|
||||
m_pipx->PairSelect1->setChecked(pipxSettingsData.PairID == pairid1);
|
||||
m_pipx->PairSelect1->setChecked(pairID == pairid1);
|
||||
m_pipx->PairSelect1->setEnabled(pairid1);
|
||||
quint32 pairid2 = pairIdField->getValue(1).toUInt();
|
||||
m_pipx->PairID2->setText(QString::number(pairIdField->getValue(1).toUInt(), 16).toUpper());
|
||||
m_pipx->PairID2->setEnabled(false);
|
||||
m_pipx->PairSelect2->setChecked(pipxSettingsData.PairID == pairid2);
|
||||
m_pipx->PairSelect2->setChecked(pairID == pairid2);
|
||||
m_pipx->PairSelect2->setEnabled(pairid2);
|
||||
quint32 pairid3 = pairIdField->getValue(2).toUInt();
|
||||
m_pipx->PairID3->setText(QString::number(pairIdField->getValue(2).toUInt(), 16).toUpper());
|
||||
m_pipx->PairID3->setEnabled(false);
|
||||
m_pipx->PairSelect3->setChecked(pipxSettingsData.PairID == pairid3);
|
||||
m_pipx->PairSelect3->setChecked(pairID == pairid3);
|
||||
m_pipx->PairSelect3->setEnabled(pairid3);
|
||||
quint32 pairid4 = pairIdField->getValue(3).toUInt();
|
||||
m_pipx->PairID4->setText(QString::number(pairIdField->getValue(3).toUInt(), 16).toUpper());
|
||||
m_pipx->PairID4->setEnabled(false);
|
||||
m_pipx->PairSelect4->setChecked(pipxSettingsData.PairID == pairid4);
|
||||
m_pipx->PairSelect4->setChecked(pairID == pairid4);
|
||||
m_pipx->PairSelect4->setEnabled(pairid4);
|
||||
} else {
|
||||
qDebug() << "PipXtremeGadgetWidget: Count not read PairID field.";
|
||||
@ -187,32 +231,27 @@ void ConfigPipXtremeWidget::updateStatus(UAVObject *object) {
|
||||
} else {
|
||||
qDebug() << "PipXtremeGadgetWidget: Count not read link state field.";
|
||||
}
|
||||
|
||||
// Update the Retries field
|
||||
UAVObjectField* retriesField = object->getField("Retries");
|
||||
if (retriesField) {
|
||||
m_pipx->Retries->setText(QString::number(retriesField->getValue().toUInt()));
|
||||
} else {
|
||||
qDebug() << "PipXtremeGadgetWidget: Count not read Retries field.";
|
||||
}
|
||||
|
||||
// Update the Errors field
|
||||
UAVObjectField* errorsField = object->getField("Errors");
|
||||
if (errorsField) {
|
||||
m_pipx->Errors->setText(QString::number(errorsField->getValue().toUInt()));
|
||||
} else {
|
||||
qDebug() << "PipXtremeGadgetWidget: Count not read Errors field.";
|
||||
}
|
||||
|
||||
// Update the Resets field
|
||||
UAVObjectField* resetsField = object->getField("Resets");
|
||||
if (resetsField) {
|
||||
m_pipx->Retries->setText(QString::number(resetsField->getValue().toUInt()));
|
||||
} else {
|
||||
qDebug() << "PipXtremeGadgetWidget: Count not read Resets field.";
|
||||
}
|
||||
}
|
||||
|
||||
/*!
|
||||
\brief Called by updates to @PipXSettings
|
||||
*/
|
||||
void ConfigPipXtremeWidget::updateSettings(UAVObject *object)
|
||||
{
|
||||
settingsUpdated = true;
|
||||
enableControls(true);
|
||||
|
||||
// Get the settings object.
|
||||
PipXSettings *pipxSettings = PipXSettings::GetInstance(getObjectManager());
|
||||
PipXSettings::DataFields pipxSettingsData = pipxSettings->getData();
|
||||
pairID = pipxSettingsData.PairID;
|
||||
}
|
||||
|
||||
void ConfigPipXtremeWidget::disconnected()
|
||||
{
|
||||
settingsUpdated = false;
|
||||
enableControls(false);
|
||||
}
|
||||
|
||||
/**
|
||||
@}
|
||||
|
@ -40,6 +40,7 @@ public:
|
||||
|
||||
public slots:
|
||||
void updateStatus(UAVObject *object1);
|
||||
void updateSettings(UAVObject *object1);
|
||||
|
||||
private:
|
||||
Ui_PipXtremeWidget *m_pipx;
|
||||
@ -47,10 +48,20 @@ private:
|
||||
// The PipXtreme status UAVObject
|
||||
UAVDataObject* pipxStatusObj;
|
||||
|
||||
// The PipXtreme ssettins UAVObject
|
||||
UAVDataObject* pipxSettingsObj;
|
||||
|
||||
bool settingsUpdated;
|
||||
quint32 pairID;
|
||||
|
||||
// A timer that timesout the connction to the PipX.
|
||||
QTimer *timeOut;
|
||||
|
||||
private slots:
|
||||
void refreshValues();
|
||||
void applySettings();
|
||||
void saveSettings();
|
||||
void disconnected();
|
||||
};
|
||||
|
||||
#endif // CONFIGTXPIDWIDGET_H
|
||||
|
@ -119,7 +119,7 @@ ConfigVehicleTypeWidget::ConfigVehicleTypeWidget(QWidget *parent) : ConfigTaskWi
|
||||
QStringList airframeTypes;
|
||||
airframeTypes << "Fixed Wing" << "Multirotor" << "Helicopter" << "Ground" << "Custom";
|
||||
m_aircraft->aircraftType->addItems(airframeTypes);
|
||||
m_aircraft->aircraftType->setCurrentIndex(1);
|
||||
m_aircraft->aircraftType->setCurrentIndex(0); //Set default vehicle to Fixed Wing
|
||||
|
||||
QStringList fixedWingTypes;
|
||||
fixedWingTypes << "Elevator aileron rudder" << "Elevon" << "Vtail";
|
||||
@ -655,7 +655,8 @@ void ConfigVehicleTypeWidget::setupAirframeUI(QString frameType)
|
||||
frameType == "HexaCoax" || frameType == "Hexacopter Y6" ||
|
||||
frameType == "Octo" || frameType == "Octocopter" ||
|
||||
frameType == "OctoV" || frameType == "Octocopter V" ||
|
||||
frameType == "OctoCoaxP" || frameType == "Octo Coax +" ) {
|
||||
frameType == "OctoCoaxP" || frameType == "Octo Coax +" ||
|
||||
frameType == "OctoCoaxX" || frameType == "Octo Coax X" ) {
|
||||
|
||||
//Call multi-rotor setup UI
|
||||
setupMultiRotorUI(frameType);
|
||||
|
@ -270,16 +270,6 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QLabel" name="label_10">
|
||||
<property name="text">
|
||||
<string>Frequency Band</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<widget class="QLabel" name="label_3">
|
||||
<property name="text">
|
||||
<string>Min Frequency</string>
|
||||
@ -289,7 +279,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="1">
|
||||
<item row="4" column="1">
|
||||
<widget class="QLineEdit" name="MinFrequency">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
@ -330,7 +320,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="0">
|
||||
<item row="5" column="0">
|
||||
<widget class="QLabel" name="label_4">
|
||||
<property name="text">
|
||||
<string>Max Frequency</string>
|
||||
@ -340,7 +330,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="1">
|
||||
<item row="5" column="1">
|
||||
<widget class="QLineEdit" name="MaxFrequency">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
@ -381,7 +371,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="0">
|
||||
<item row="6" column="0">
|
||||
<widget class="QLabel" name="label_12">
|
||||
<property name="text">
|
||||
<string>Frequency Step Size</string>
|
||||
@ -391,7 +381,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="1">
|
||||
<item row="6" column="1">
|
||||
<widget class="QLineEdit" name="FrequencyStepSize">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
@ -432,7 +422,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="8" column="0">
|
||||
<item row="7" column="0">
|
||||
<widget class="QLabel" name="label_11">
|
||||
<property name="text">
|
||||
<string>Link State</string>
|
||||
@ -442,7 +432,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="8" column="1">
|
||||
<item row="7" column="1">
|
||||
<widget class="QLineEdit" name="LinkState">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
@ -483,7 +473,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="9" column="0">
|
||||
<item row="8" column="0">
|
||||
<widget class="QLabel" name="label_17">
|
||||
<property name="text">
|
||||
<string>Rx AFC</string>
|
||||
@ -493,7 +483,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="9" column="1">
|
||||
<item row="8" column="1">
|
||||
<widget class="QLineEdit" name="RxAFC">
|
||||
<property name="font">
|
||||
<font>
|
||||
@ -516,7 +506,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="10" column="0">
|
||||
<item row="9" column="0">
|
||||
<widget class="QLabel" name="label_18">
|
||||
<property name="text">
|
||||
<string>Retries</string>
|
||||
@ -526,7 +516,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="10" column="1">
|
||||
<item row="9" column="1">
|
||||
<widget class="QLineEdit" name="Retries">
|
||||
<property name="font">
|
||||
<font>
|
||||
@ -552,48 +542,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<widget class="QLineEdit" name="FrequencyBand">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>The modems frequency band</string>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">QLineEdit {
|
||||
border: none;
|
||||
border-radius: 1px;
|
||||
padding: 0 8px;
|
||||
background: rgba(0, 0, 0, 16);
|
||||
/* background: transparent; */
|
||||
/* selection-background-color: darkgray;*/
|
||||
}</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="11" column="1">
|
||||
<item row="10" column="1">
|
||||
<widget class="QLineEdit" name="Errors">
|
||||
<property name="font">
|
||||
<font>
|
||||
@ -619,7 +568,7 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="11" column="0">
|
||||
<item row="10" column="0">
|
||||
<widget class="QLabel" name="label_19">
|
||||
<property name="text">
|
||||
<string>Errors</string>
|
||||
@ -629,6 +578,150 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="11" column="0">
|
||||
<widget class="QLabel" name="UAVTalkErrorsLabel">
|
||||
<property name="text">
|
||||
<string>UAVTalk Errors</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="11" column="1">
|
||||
<widget class="QLineEdit" name="UAVTalkErrors">
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">QLineEdit {
|
||||
border: none;
|
||||
border-radius: 1px;
|
||||
padding: 0 8px;
|
||||
background: rgba(0, 0, 0, 16);
|
||||
/* background: transparent; */
|
||||
/* selection-background-color: darkgray;*/
|
||||
}</string>
|
||||
</property>
|
||||
<property name="frame">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="12" column="0">
|
||||
<widget class="QLabel" name="ResetsLabel">
|
||||
<property name="text">
|
||||
<string>Resets</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="12" column="1">
|
||||
<widget class="QLineEdit" name="Resets">
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">QLineEdit {
|
||||
border: none;
|
||||
border-radius: 1px;
|
||||
padding: 0 8px;
|
||||
background: rgba(0, 0, 0, 16);
|
||||
/* background: transparent; */
|
||||
/* selection-background-color: darkgray;*/
|
||||
}</string>
|
||||
</property>
|
||||
<property name="frame">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="13" column="0">
|
||||
<widget class="QLabel" name="TXRateLabel">
|
||||
<property name="text">
|
||||
<string>TX Rate (B/s)</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="13" column="1">
|
||||
<widget class="QLineEdit" name="TXRate">
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">QLineEdit {
|
||||
border: none;
|
||||
border-radius: 1px;
|
||||
padding: 0 8px;
|
||||
background: rgba(0, 0, 0, 16);
|
||||
/* background: transparent; */
|
||||
/* selection-background-color: darkgray;*/
|
||||
}</string>
|
||||
</property>
|
||||
<property name="frame">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="14" column="0">
|
||||
<widget class="QLabel" name="RXRateLabel">
|
||||
<property name="text">
|
||||
<string>RX Rate (B/s)</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="14" column="1">
|
||||
<widget class="QLineEdit" name="RXRate">
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">QLineEdit {
|
||||
border: none;
|
||||
border-radius: 1px;
|
||||
padding: 0 8px;
|
||||
background: rgba(0, 0, 0, 16);
|
||||
/* background: transparent; */
|
||||
/* selection-background-color: darkgray;*/
|
||||
}</string>
|
||||
</property>
|
||||
<property name="frame">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="QLineEdit" name="DeviceID">
|
||||
<property name="font">
|
||||
@ -683,10 +776,235 @@
|
||||
<string>Configuration</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_2">
|
||||
<item row="9" column="0">
|
||||
<widget class="QLabel" name="label_5">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="TelemPortConfigLabel">
|
||||
<property name="text">
|
||||
<string>Frequency (MHz)</string>
|
||||
<string>Telemetry Port Configuration</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QComboBox" name="TelemPortConfig">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the telemetry port configuration</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="TelemPortSpeedLabel">
|
||||
<property name="text">
|
||||
<string>Telemetry Port Speed</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QComboBox" name="TelemPortSpeed">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the telemetry port speed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="FlexiPortConfigLabel">
|
||||
<property name="text">
|
||||
<string>Flexi Port Configuration</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QComboBox" name="FlexiPortConfig">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the flexi port configuration</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="FlexiPortSpeedConfig">
|
||||
<property name="text">
|
||||
<string>Flexi Port Speed</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="QComboBox" name="FlexiPortSpeed">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the flexi port speed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0">
|
||||
<widget class="QLabel" name="VCPConfigLabel">
|
||||
<property name="text">
|
||||
<string>VCP Configuration</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="1">
|
||||
<widget class="QComboBox" name="VCPConfig">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the virtual serial port configuration</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<widget class="QLabel" name="VCPSpeedLabel">
|
||||
<property name="text">
|
||||
<string>VCP Speed</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="1">
|
||||
<widget class="QComboBox" name="VCPSpeed">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the virtual serial port speed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="0">
|
||||
<widget class="QLabel" name="MaxRFDatarateLabel">
|
||||
<property name="text">
|
||||
<string>Max RF Datarate (bits/s)</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="1">
|
||||
<widget class="QComboBox" name="MaxRFDatarate">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the maximum RF datarate/channel bandwidth the modem will use</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="0">
|
||||
<widget class="QLabel" name="MaxRFTxPowerLabel">
|
||||
<property name="text">
|
||||
<string>Max RF Tx Power(mW)</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="1">
|
||||
<widget class="QComboBox" name="MaxRFTxPower">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the maximum TX output power the modem will use</string>
|
||||
</property>
|
||||
<property name="layoutDirection">
|
||||
<enum>Qt::LeftToRight</enum>
|
||||
</property>
|
||||
<property name="modelColumn">
|
||||
<number>0</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="8" column="0">
|
||||
<widget class="QLabel" name="SendTimeoutLabel">
|
||||
<property name="text">
|
||||
<string>Send Timeout (ms)</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="8" column="1">
|
||||
<widget class="QSpinBox" name="SendTimeout">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Calibrate the modems RF carrier frequency</string>
|
||||
</property>
|
||||
<property name="accelerated">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="9" column="0">
|
||||
<widget class="QLabel" name="MinPacketSizeLabel">
|
||||
<property name="text">
|
||||
<string>Min Packet Size</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
@ -694,7 +1012,77 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item row="9" column="1">
|
||||
<widget class="QDoubleSpinBox" name="Frequency">
|
||||
<widget class="QSpinBox" name="MinPacketSize">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Calibrate the modems RF carrier frequency</string>
|
||||
</property>
|
||||
<property name="accelerated">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="10" column="0">
|
||||
<widget class="QLabel" name="FreqCalLabel">
|
||||
<property name="text">
|
||||
<string>Frequency Calibration</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="10" column="1">
|
||||
<widget class="QSpinBox" name="FrequencyCalibration">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Calibrate the modems RF carrier frequency</string>
|
||||
</property>
|
||||
<property name="accelerated">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="11" column="0">
|
||||
<widget class="QLabel" name="label_5">
|
||||
<property name="text">
|
||||
<string>Frequency (Hz)</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="11" column="1">
|
||||
<widget class="QSpinBox" name="Frequency">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -716,148 +1104,14 @@
|
||||
<property name="accelerated">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="decimals">
|
||||
<number>8</number>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<double>0.000000000000000</double>
|
||||
<double>0</double>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<double>1000.000000000000000</double>
|
||||
<double>1000000000</double>
|
||||
</property>
|
||||
<property name="singleStep">
|
||||
<double>0.000001000000000</double>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QComboBox" name="SerialPortSpeed">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the modems serial port speed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label_8">
|
||||
<property name="text">
|
||||
<string>Serial Port Speed</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1">
|
||||
<widget class="QComboBox" name="MaxRFDatarate">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the maximum RF datarate/channel bandwidth the modem will use</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0">
|
||||
<widget class="QLabel" name="label_6">
|
||||
<property name="text">
|
||||
<string>Max RF Datarate (bits/s)</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="1">
|
||||
<widget class="QComboBox" name="MaxRFTxPower">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the maximum TX output power the modem will use</string>
|
||||
</property>
|
||||
<property name="layoutDirection">
|
||||
<enum>Qt::LeftToRight</enum>
|
||||
</property>
|
||||
<property name="modelColumn">
|
||||
<number>0</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0">
|
||||
<widget class="QLabel" name="label_7">
|
||||
<property name="text">
|
||||
<string>Max RF Tx Power(mW)</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="0">
|
||||
<widget class="QLabel" name="label_16">
|
||||
<property name="text">
|
||||
<string>Send Timeout (ms)</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="label_14">
|
||||
<property name="text">
|
||||
<string>Flexi Port Configuration</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1">
|
||||
<widget class="QComboBox" name="FlexiPortSpeed">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the modems serial port speed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QComboBox" name="FlexiPortConfig">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Set the modems serial port speed</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_15">
|
||||
<property name="text">
|
||||
<string>Flexi Port Speed</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
<double>100000</double>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@ -953,101 +1207,6 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="1">
|
||||
<widget class="QSpinBox" name="SendTimeout">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Calibrate the modems RF carrier frequency</string>
|
||||
</property>
|
||||
<property name="accelerated">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="0">
|
||||
<widget class="QLabel" name="label_21">
|
||||
<property name="text">
|
||||
<string>Min Packet Size</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="7" column="1">
|
||||
<widget class="QSpinBox" name="MinPacketSize">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Calibrate the modems RF carrier frequency</string>
|
||||
</property>
|
||||
<property name="accelerated">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="8" column="1">
|
||||
<widget class="QSpinBox" name="FrequencyCalibration">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Calibrate the modems RF carrier frequency</string>
|
||||
</property>
|
||||
<property name="accelerated">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>255</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="8" column="0">
|
||||
<widget class="QLabel" name="label_13">
|
||||
<property name="text">
|
||||
<string>Frequency Calibration</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
|
@ -3383,6 +3383,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Slowly raise Proportional until you start seeing clear oscillations when you fly.
|
||||
Then lower the value by 5 or so.</string>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true"/>
|
||||
</property>
|
||||
@ -3433,6 +3437,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Slowly raise Proportional until you start seeing clear oscillations when you fly.
|
||||
Then lower the value by 5 or so.</string>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>200</number>
|
||||
</property>
|
||||
@ -3484,6 +3492,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Slowly raise Proportional until you start seeing clear oscillations when you fly.
|
||||
Then lower the value by 5 or so.</string>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true"/>
|
||||
</property>
|
||||
@ -3531,6 +3543,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Slowly raise Proportional until you start seeing clear oscillations when you fly.
|
||||
Then lower the value by 5 or so.</string>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>200</number>
|
||||
</property>
|
||||
@ -3582,6 +3598,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Slowly raise Proportional until you start seeing clear oscillations when you fly.
|
||||
Then lower the value by 5 or so.</string>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true"/>
|
||||
</property>
|
||||
@ -3629,6 +3649,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Slowly raise Proportional until you start seeing clear oscillations when you fly.
|
||||
Then lower the value by 5 or so.</string>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>200</number>
|
||||
</property>
|
||||
@ -3683,6 +3707,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>As a rule of thumb, you can set the Integral at roughly the same
|
||||
value as the Kp.</string>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true"/>
|
||||
</property>
|
||||
@ -3730,6 +3758,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>As a rule of thumb, you can set the Integral at roughly the same
|
||||
value as the Kp.</string>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>200</number>
|
||||
</property>
|
||||
@ -3765,6 +3797,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>As a rule of thumb, you can set the Integral at roughly the same
|
||||
value as the Kp.</string>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true"/>
|
||||
</property>
|
||||
@ -3812,6 +3848,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>As a rule of thumb, you can set the Integral at roughly the same
|
||||
value as the Kp.</string>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>200</number>
|
||||
</property>
|
||||
@ -3847,6 +3887,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>As a rule of thumb, you can set the Integral at roughly the same
|
||||
value as the Kp.</string>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true"/>
|
||||
</property>
|
||||
@ -3894,6 +3938,10 @@ border-radius: 5;</string>
|
||||
<property name="focusPolicy">
|
||||
<enum>Qt::StrongFocus</enum>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>As a rule of thumb, you can set the Integral at roughly the same
|
||||
value as the Kp.</string>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>200</number>
|
||||
</property>
|
||||
@ -11709,6 +11757,10 @@ automatically every 300ms, which will help for fast tuning.</string>
|
||||
<pointsize>8</pointsize>
|
||||
</font>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Reloads the saved settings into GCS.
|
||||
Useful if you have accidentally changed some settings.</string>
|
||||
</property>
|
||||
<property name="styleSheet">
|
||||
<string notr="true">QPushButton {
|
||||
border: 1px outset #999;
|
||||
|
@ -531,7 +531,7 @@ void UAVObject::SetGcsAccess(UAVObject::Metadata& metadata, UAVObject::AccessMod
|
||||
* \param[in] metadata The metadata object
|
||||
* \return the telemetry acked boolean
|
||||
*/
|
||||
uint8_t UAVObject::GetFlightTelemetryAcked(const UAVObject::Metadata& metadata) {
|
||||
quint8 UAVObject::GetFlightTelemetryAcked(const UAVObject::Metadata& metadata) {
|
||||
return (metadata.flags >> UAVOBJ_TELEMETRY_ACKED_SHIFT) & 1;
|
||||
}
|
||||
|
||||
@ -540,7 +540,7 @@ uint8_t UAVObject::GetFlightTelemetryAcked(const UAVObject::Metadata& metadata)
|
||||
* \param[in] metadata The metadata object
|
||||
* \param[in] val The telemetry acked boolean
|
||||
*/
|
||||
void UAVObject::SetFlightTelemetryAcked(UAVObject::Metadata& metadata, uint8_t val) {
|
||||
void UAVObject::SetFlightTelemetryAcked(UAVObject::Metadata& metadata, quint8 val) {
|
||||
SET_BITS(metadata.flags, UAVOBJ_TELEMETRY_ACKED_SHIFT, val, 1);
|
||||
}
|
||||
|
||||
@ -549,7 +549,7 @@ void UAVObject::SetFlightTelemetryAcked(UAVObject::Metadata& metadata, uint8_t v
|
||||
* \param[in] metadata The metadata object
|
||||
* \return the telemetry acked boolean
|
||||
*/
|
||||
uint8_t UAVObject::GetGcsTelemetryAcked(const UAVObject::Metadata& metadata) {
|
||||
quint8 UAVObject::GetGcsTelemetryAcked(const UAVObject::Metadata& metadata) {
|
||||
return (metadata.flags >> UAVOBJ_GCS_TELEMETRY_ACKED_SHIFT) & 1;
|
||||
}
|
||||
|
||||
@ -558,7 +558,7 @@ uint8_t UAVObject::GetGcsTelemetryAcked(const UAVObject::Metadata& metadata) {
|
||||
* \param[in] metadata The metadata object
|
||||
* \param[in] val The GCS telemetry acked boolean
|
||||
*/
|
||||
void UAVObject::SetGcsTelemetryAcked(UAVObject::Metadata& metadata, uint8_t val) {
|
||||
void UAVObject::SetGcsTelemetryAcked(UAVObject::Metadata& metadata, quint8 val) {
|
||||
SET_BITS(metadata.flags, UAVOBJ_GCS_TELEMETRY_ACKED_SHIFT, val, 1);
|
||||
}
|
||||
|
||||
|
@ -90,10 +90,10 @@ public:
|
||||
* 6-7 gcsTelemetryUpdateMode Update mode used by the GCS (UAVObjUpdateMode)
|
||||
*/
|
||||
typedef struct {
|
||||
uint8_t flags; /** Defines flags for update and logging modes and whether an update should be ACK'd (bits defined above) */
|
||||
uint16_t flightTelemetryUpdatePeriod; /** Update period used by the telemetry module (only if telemetry mode is PERIODIC) */
|
||||
uint16_t gcsTelemetryUpdatePeriod; /** Update period used by the GCS (only if telemetry mode is PERIODIC) */
|
||||
uint16_t loggingUpdatePeriod; /** Update period used by the logging module (only if logging mode is PERIODIC) */
|
||||
quint8 flags; /** Defines flags for update and logging modes and whether an update should be ACK'd (bits defined above) */
|
||||
quint16 flightTelemetryUpdatePeriod; /** Update period used by the telemetry module (only if telemetry mode is PERIODIC) */
|
||||
quint16 gcsTelemetryUpdatePeriod; /** Update period used by the GCS (only if telemetry mode is PERIODIC) */
|
||||
quint16 loggingUpdatePeriod; /** Update period used by the logging module (only if logging mode is PERIODIC) */
|
||||
} __attribute__((packed)) Metadata;
|
||||
|
||||
|
||||
@ -132,10 +132,10 @@ public:
|
||||
static void SetFlightAccess(Metadata& meta, AccessMode mode);
|
||||
static AccessMode GetGcsAccess(const Metadata& meta);
|
||||
static void SetGcsAccess(Metadata& meta, AccessMode mode);
|
||||
static uint8_t GetFlightTelemetryAcked(const Metadata& meta);
|
||||
static void SetFlightTelemetryAcked(Metadata& meta, uint8_t val);
|
||||
static uint8_t GetGcsTelemetryAcked(const Metadata& meta);
|
||||
static void SetGcsTelemetryAcked(Metadata& meta, uint8_t val);
|
||||
static quint8 GetFlightTelemetryAcked(const Metadata& meta);
|
||||
static void SetFlightTelemetryAcked(Metadata& meta, quint8 val);
|
||||
static quint8 GetGcsTelemetryAcked(const Metadata& meta);
|
||||
static void SetGcsTelemetryAcked(Metadata& meta, quint8 val);
|
||||
static UpdateMode GetFlightTelemetryUpdateMode(const Metadata& meta);
|
||||
static void SetFlightTelemetryUpdateMode(Metadata& meta, UpdateMode val);
|
||||
static UpdateMode GetGcsTelemetryUpdateMode(const Metadata& meta);
|
||||
|
@ -150,7 +150,7 @@ void UAVObjectUtilManager::objectPersistenceTransactionCompleted(UAVObject* obj,
|
||||
// the queue:
|
||||
saveState = AWAITING_COMPLETED;
|
||||
disconnect(obj, SIGNAL(transactionCompleted(UAVObject*,bool)), this, SLOT(objectPersistenceTransactionCompleted(UAVObject*,bool)));
|
||||
failureTimer.start(1000); // Create a timeout
|
||||
failureTimer.start(2000); // Create a timeout
|
||||
} else {
|
||||
// Can be caused by timeout errors on sending. Forget it and send next.
|
||||
qDebug() << "objectPersistenceTranscationCompleted (error)";
|
||||
|
@ -26,6 +26,7 @@
|
||||
*/
|
||||
#include "configtaskwidget.h"
|
||||
#include <QtGui/QWidget>
|
||||
#include <QtGui/QLineEdit>
|
||||
#include "uavsettingsimportexport/uavsettingsimportexportfactory.h"
|
||||
|
||||
/**
|
||||
@ -126,7 +127,7 @@ void ConfigTaskWidget::addUAVObjectToWidgetRelation(QString object, QString fiel
|
||||
Q_ASSERT(obj);
|
||||
objectUpdates.insert(obj,true);
|
||||
connect(obj, SIGNAL(objectUpdated(UAVObject*)),this, SLOT(objectUpdated(UAVObject*)));
|
||||
connect(obj, SIGNAL(objectUpdated(UAVObject*)), this, SLOT(refreshWidgetsValues()));
|
||||
connect(obj, SIGNAL(objectUpdated(UAVObject*)), this, SLOT(refreshWidgetsValues(UAVObject*)));
|
||||
}
|
||||
if(!field.isEmpty() && obj)
|
||||
_field = obj->getField(QString(field));
|
||||
@ -251,7 +252,7 @@ void ConfigTaskWidget::populateWidgets()
|
||||
* object field added to the framework pool
|
||||
* Overwrite this if you need to change the default behavior
|
||||
*/
|
||||
void ConfigTaskWidget::refreshWidgetsValues()
|
||||
void ConfigTaskWidget::refreshWidgetsValues(UAVObject * obj)
|
||||
{
|
||||
bool dirtyBack=dirty;
|
||||
emit refreshWidgetsValuesRequested();
|
||||
@ -263,8 +264,8 @@ void ConfigTaskWidget::refreshWidgetsValues()
|
||||
}
|
||||
else
|
||||
{
|
||||
setWidgetFromField(ow->widget,ow->field,ow->index,ow->scale,ow->isLimited);
|
||||
|
||||
if(ow->object==obj || obj==NULL)
|
||||
setWidgetFromField(ow->widget,ow->field,ow->index,ow->scale,ow->isLimited);
|
||||
}
|
||||
|
||||
}
|
||||
@ -461,7 +462,7 @@ void ConfigTaskWidget::enableObjUpdates()
|
||||
foreach(objectToWidget * obj,objOfInterest)
|
||||
{
|
||||
if(obj->object)
|
||||
connect(obj->object, SIGNAL(objectUpdated(UAVObject*)), this, SLOT(refreshWidgetsValues()));
|
||||
connect(obj->object, SIGNAL(objectUpdated(UAVObject*)), this, SLOT(refreshWidgetsValues(UAVObject*)));
|
||||
}
|
||||
}
|
||||
/**
|
||||
@ -991,6 +992,14 @@ bool ConfigTaskWidget::setWidgetFromVariant(QWidget *widget, QVariant value, dou
|
||||
cb->setChecked(bvalue);
|
||||
return true;
|
||||
}
|
||||
else if(QLineEdit * cb=qobject_cast<QLineEdit *>(widget))
|
||||
{
|
||||
if(scale==0)
|
||||
cb->setText(value.toString());
|
||||
else
|
||||
cb->setText(QString::number((value.toDouble()/scale)));
|
||||
return true;
|
||||
}
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
@ -170,7 +170,7 @@ protected slots:
|
||||
virtual void clearDirty();
|
||||
virtual void widgetsContentsChanged();
|
||||
virtual void populateWidgets();
|
||||
virtual void refreshWidgetsValues();
|
||||
virtual void refreshWidgetsValues(UAVObject * obj=NULL);
|
||||
virtual void updateObjectsFromWidgets();
|
||||
virtual void helpButtonPressed();
|
||||
protected:
|
||||
|
@ -87,7 +87,7 @@ void smartSaveButton::processOperation(QPushButton * button,bool save)
|
||||
connect(obj,SIGNAL(transactionCompleted(UAVObject*,bool)),this,SLOT(transaction_finished(UAVObject*, bool)));
|
||||
connect(&timer,SIGNAL(timeout()),&loop,SLOT(quit()));
|
||||
obj->updated();
|
||||
timer.start(1000);
|
||||
timer.start(3000);
|
||||
//qDebug()<<"begin loop";
|
||||
loop.exec();
|
||||
//qDebug()<<"end loop";
|
||||
@ -113,7 +113,7 @@ void smartSaveButton::processOperation(QPushButton * button,bool save)
|
||||
connect(utilMngr,SIGNAL(saveCompleted(int,bool)),this,SLOT(saving_finished(int,bool)));
|
||||
connect(&timer,SIGNAL(timeout()),&loop,SLOT(quit()));
|
||||
utilMngr->saveObjectToSD(obj);
|
||||
timer.start(1000);
|
||||
timer.start(3000);
|
||||
loop.exec();
|
||||
timer.stop();
|
||||
disconnect(utilMngr,SIGNAL(saveCompleted(int,bool)),this,SLOT(saving_finished(int,bool)));
|
||||
|
@ -27,6 +27,8 @@
|
||||
|
||||
#include "telemetry.h"
|
||||
#include "qxtlogger.h"
|
||||
#include "pipxsettings.h"
|
||||
#include "objectpersistence.h"
|
||||
#include <QTime>
|
||||
#include <QtGlobal>
|
||||
#include <stdlib.h>
|
||||
@ -393,7 +395,7 @@ void Telemetry::processObjectQueue()
|
||||
if ( gcsStats.Status != GCSTelemetryStats::STATUS_CONNECTED )
|
||||
{
|
||||
objQueue.clear();
|
||||
if ( objInfo.obj->getObjID() != GCSTelemetryStats::OBJID )
|
||||
if ( objInfo.obj->getObjID() != GCSTelemetryStats::OBJID && objInfo.obj->getObjID() != PipXSettings::OBJID && objInfo.obj->getObjID() != ObjectPersistence::OBJID )
|
||||
{
|
||||
objInfo.obj->emitTransactionCompleted(false);
|
||||
return;
|
||||
|
@ -404,10 +404,12 @@ void deviceWidget::uploadFirmware()
|
||||
status("Starting firmware upload", STATUSICON_RUNNING);
|
||||
// We don't know which device was used previously, so we
|
||||
// are cautious and reenter DFU for this deviceID:
|
||||
emit uploadStarted();
|
||||
if(!m_dfu->enterDFU(deviceID))
|
||||
{
|
||||
status("Error:Could not enter DFU mode", STATUSICON_FAIL);
|
||||
myDevice->updateButton->setEnabled(true);
|
||||
emit uploadEnded(false);
|
||||
return;
|
||||
}
|
||||
OP_DFU::Status ret=m_dfu->StatusRequest();
|
||||
@ -421,6 +423,7 @@ void deviceWidget::uploadFirmware()
|
||||
if(!retstatus ) {
|
||||
status("Could not start upload", STATUSICON_FAIL);
|
||||
myDevice->updateButton->setEnabled(true);
|
||||
emit uploadEnded(false);
|
||||
return;
|
||||
}
|
||||
status("Uploading, please wait...", STATUSICON_RUNNING);
|
||||
@ -480,6 +483,7 @@ void deviceWidget::uploadFinished(OP_DFU::Status retstatus)
|
||||
disconnect(m_dfu, SIGNAL(operationProgress(QString)), this, SLOT(dfuStatus(QString)));
|
||||
if(retstatus != OP_DFU::Last_operation_Success) {
|
||||
status(QString("Upload failed with code: ") + m_dfu->StatusToString(retstatus).toLatin1().data(), STATUSICON_FAIL);
|
||||
emit uploadEnded(false);
|
||||
return;
|
||||
} else
|
||||
if (!descriptionArray.isEmpty()) {
|
||||
@ -489,6 +493,7 @@ void deviceWidget::uploadFinished(OP_DFU::Status retstatus)
|
||||
retstatus = m_dfu->UploadDescription(descriptionArray);
|
||||
if( retstatus != OP_DFU::Last_operation_Success) {
|
||||
status(QString("Upload failed with code: ") + m_dfu->StatusToString(retstatus).toLatin1().data(), STATUSICON_FAIL);
|
||||
emit uploadEnded(false);
|
||||
return;
|
||||
}
|
||||
|
||||
@ -499,10 +504,12 @@ void deviceWidget::uploadFinished(OP_DFU::Status retstatus)
|
||||
retstatus = m_dfu->UploadDescription(myDevice->description->text());
|
||||
if( retstatus != OP_DFU::Last_operation_Success) {
|
||||
status(QString("Upload failed with code: ") + m_dfu->StatusToString(retstatus).toLatin1().data(), STATUSICON_FAIL);
|
||||
emit uploadEnded(false);
|
||||
return;
|
||||
}
|
||||
}
|
||||
populate();
|
||||
emit uploadEnded(true);
|
||||
status("Upload successful", STATUSICON_OK);
|
||||
|
||||
}
|
||||
|
@ -72,7 +72,8 @@ private:
|
||||
bool populateLoadedStructuredDescription(QByteArray arr);
|
||||
|
||||
signals:
|
||||
|
||||
void uploadStarted();
|
||||
void uploadEnded(bool success);
|
||||
public slots:
|
||||
void uploadFirmware();
|
||||
void loadFirmware();
|
||||
|
@ -116,6 +116,12 @@ QString UploaderGadgetWidget::getPortDevice(const QString &friendName)
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
void UploaderGadgetWidget::connectSignalSlot(QWidget *widget)
|
||||
{
|
||||
connect(qobject_cast<deviceWidget *>(widget),SIGNAL(uploadStarted()),this,SLOT(uploadStarted()));
|
||||
connect(qobject_cast<deviceWidget *>(widget),SIGNAL(uploadEnded(bool)),this,SLOT(uploadEnded(bool)));
|
||||
}
|
||||
void UploaderGadgetWidget::onPhisicalHWConnect()
|
||||
{
|
||||
m_config->bootButton->setEnabled(false);
|
||||
@ -305,6 +311,7 @@ void UploaderGadgetWidget::goToBootloader(UAVObject* callerObj, bool success)
|
||||
}
|
||||
for(int i=0;i<dfu->numberOfDevices;i++) {
|
||||
deviceWidget* dw = new deviceWidget(this);
|
||||
connectSignalSlot(dw);
|
||||
dw->setDeviceID(i);
|
||||
dw->setDfu(dfu);
|
||||
dw->populate();
|
||||
@ -540,6 +547,7 @@ void UploaderGadgetWidget::systemRescue()
|
||||
}
|
||||
for(int i=0;i<dfu->numberOfDevices;i++) {
|
||||
deviceWidget* dw = new deviceWidget(this);
|
||||
connectSignalSlot(dw);
|
||||
dw->setDeviceID(i);
|
||||
dw->setDfu(dfu);
|
||||
dw->populate();
|
||||
@ -567,6 +575,19 @@ void UploaderGadgetWidget::cancel()
|
||||
m_eventloop.exit();
|
||||
}
|
||||
|
||||
void UploaderGadgetWidget::uploadStarted()
|
||||
{
|
||||
m_config->bootButton->setEnabled(false);
|
||||
m_config->safeBootButton->setEnabled(false);
|
||||
}
|
||||
|
||||
void UploaderGadgetWidget::uploadEnded(bool succeed)
|
||||
{
|
||||
Q_UNUSED(succeed);
|
||||
m_config->bootButton->setEnabled(true);
|
||||
m_config->safeBootButton->setEnabled(true);
|
||||
}
|
||||
|
||||
/**
|
||||
Update log entry
|
||||
*/
|
||||
|
@ -88,6 +88,7 @@ private:
|
||||
QLineEdit* openFileNameLE;
|
||||
QEventLoop m_eventloop;
|
||||
QErrorMessage * msg;
|
||||
void connectSignalSlot(QWidget * widget);
|
||||
private slots:
|
||||
void onPhisicalHWConnect();
|
||||
void versionMatchCheck();
|
||||
@ -102,6 +103,8 @@ private slots:
|
||||
void getSerialPorts();
|
||||
void perform();
|
||||
void cancel();
|
||||
void uploadStarted();
|
||||
void uploadEnded(bool succeed);
|
||||
|
||||
};
|
||||
|
||||
|
@ -2,14 +2,14 @@
|
||||
<object name="PipXSettings" singleinstance="true" settings="true">
|
||||
<description>PipXtreme configurations options.</description>
|
||||
<field name="PairID" units="" type="uint32" elements="1" defaultvalue="0"/>
|
||||
<field name="TelemetryConfig" units="function" type="enum" elements="1" options="Disabled,Serial,UAVTalk,RSSI" defaultvalue="UAVTalk"/>
|
||||
<field name="TelemetryConfig" units="function" type="enum" elements="1" options="Disabled,Serial,UAVTalk,PPM_In,PPM_Out,RSSI,Debug" defaultvalue="UAVTalk"/>
|
||||
<field name="TelemetrySpeed" units="bps" type="enum" elements="1" options="2400,4800,9600,19200,38400,57600,115200" defaultvalue="57600"/>
|
||||
<field name="FlexiConfig" units="function" type="enum" elements="1" options="Disabled,Serial,UAVTalk,PPM,RSSI" defaultvalue="Disabled"/>
|
||||
<field name="FlexiConfig" units="function" type="enum" elements="1" options="Disabled,Serial,UAVTalk,PPM_In,PPM_Out,RSSI,Debug" defaultvalue="Disabled"/>
|
||||
<field name="FlexiSpeed" units="bps" type="enum" elements="1" options="2400,4800,9600,19200,38400,57600,115200" defaultvalue="57600"/>
|
||||
<field name="VCPConfig" units="function" type="enum" elements="1" options="Disabled,Serial,UAVTalk" defaultvalue="Disabled"/>
|
||||
<field name="VCPConfig" units="function" type="enum" elements="1" options="Disabled,Serial,UAVTalk,Debug" defaultvalue="Disabled"/>
|
||||
<field name="VCPSpeed" units="bps" type="enum" elements="1" options="2400,4800,9600,19200,38400,57600,115200" defaultvalue="57600"/>
|
||||
<field name="RFSpeed" units="bps" type="enum" elements="1" options="2400,4800,9600,19200,38400,57600,115200" defaultvalue="115200"/>
|
||||
<field name="MaxRFPower" units="mW" type="enum" elements="1" options="1.25,1.6,3.16,6.3,12.6,25,50,100" defaultvalue="1.25"/>
|
||||
<field name="MaxRFPower" units="mW" type="enum" elements="1" options="1.25,1.6,3.16,6.3,12.6,25,50,100" defaultvalue="100"/>
|
||||
<field name="SendTimeout" units="ms" type="uint16" elements="1" defaultvalue="50"/>
|
||||
<field name="MinPacketSize" units="bytes" type="uint8" elements="1" defaultvalue="50"/>
|
||||
<field name="FrequencyCalibration" units="" type="uint8" elements="1" defaultvalue="127"/>
|
||||
|
@ -13,7 +13,10 @@
|
||||
<field name="AFC" units="" type="int32" elements="1" defaultvalue="0"/>
|
||||
<field name="Retries" units="" type="uint16" elements="1" defaultvalue="0"/>
|
||||
<field name="Errors" units="" type="uint16" elements="1" defaultvalue="0"/>
|
||||
<field name="UAVTalkErrors" units="" type="uint16" elements="1" defaultvalue="0"/>
|
||||
<field name="Resets" units="" type="uint16" elements="1" defaultvalue="0"/>
|
||||
<field name="TXRate" units="Bps" type="uint16" elements="1" defaultvalue="0"/>
|
||||
<field name="RXRate" units="Bps" type="uint16" elements="1" defaultvalue="0"/>
|
||||
<field name="RSSI" units="dBm" type="int8" elements="1" defaultvalue="0"/>
|
||||
<field name="LinkState" units="function" type="enum" elements="1" options="Disconnected,Connecting,Connected" defaultvalue="Disconnected"/>
|
||||
<field name="PairIDs" units="" type="uint32" elements="4" defaultvalue="0"/>
|
||||
|
Loading…
x
Reference in New Issue
Block a user