Skip to content

Merge v4.0 changes #744

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Dec 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Firmware/RTK_Surveyor/Bluetooth.ino
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,10 @@ void bluetoothStart()
else if (systemState >= STATE_BASE_NOT_STARTED && systemState <= STATE_BASE_FIXED_TRANSMITTING)
strncpy(stateName, "Base-", sizeof(stateName) - 1);
else
{
strncpy(stateName, "Rover-", sizeof(stateName) - 1);
log_d("State out of range for Bluetooth Broadcast: %d", systemState);
}

char productName[50] = {0};
strncpy(productName, platformPrefix, sizeof(productName));
Expand Down
9 changes: 3 additions & 6 deletions Firmware/RTK_Surveyor/menuPP.ino
Original file line number Diff line number Diff line change
Expand Up @@ -613,26 +613,23 @@ bool pointperfectUpdateKeys()

systemPrintf("Attempting to connect to MQTT broker: %s\r\n", settings.pointPerfectBrokerHost);

if (mqttClient.connect(settings.pointPerfectClientID))
if (mqttClient.connect(settings.pointPerfectClientID) == true)
{
// Successful connection
systemPrintln("MQTT connected");

// Originally the provisioning process reported the '/pp/key/Lb' channel which fails to respond with
// keys. Looks like they fixed it to /pp/ubx/0236/Lb.
mqttClient.subscribe(settings.pointPerfectLBandTopic);
break;
}

// Check for connection failure
if (mqttClient.connected() == false)
else
{
systemPrintln("Failed to connect to MQTT Broker");

// MQTT does not provide good error reporting.
// Throw out everything and attempt to provision the device to get better error checking.
pointperfectProvisionDevice();
break;
break; //Skip the remaining MQTT checking, release resources
}

systemPrint("Waiting for keys");
Expand Down