Skip to content

Commit edba7a8

Browse files
committed
BBB: Bring Back Beeper! Update lever arm.
1 parent 88b9007 commit edba7a8

File tree

2 files changed

+17
-7
lines changed

2 files changed

+17
-7
lines changed

Firmware/RTK_Everywhere/System.ino

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,14 +112,24 @@ void beepOn()
112112
{
113113
// Disallow beeper if setting is turned off
114114
if ((pin_beeper != PIN_UNDEFINED) && (settings.enableBeeper == true))
115-
digitalWrite(pin_beeper, HIGH);
115+
{
116+
if (productVariant == RTK_TORCH)
117+
digitalWrite(pin_beeper, HIGH);
118+
else if (productVariant == RTK_FLEX)
119+
tone(pin_beeper, 523); // NOTE_C5
120+
}
116121
}
117122

118123
void beepOff()
119124
{
120125
// Disallow beeper if setting is turned off
121126
if ((pin_beeper != PIN_UNDEFINED) && (settings.enableBeeper == true))
122-
digitalWrite(pin_beeper, LOW);
127+
{
128+
if (productVariant == RTK_TORCH)
129+
digitalWrite(pin_beeper, LOW);
130+
else if (productVariant == RTK_FLEX)
131+
noTone(pin_beeper);
132+
}
123133
}
124134

125135
// Only useful for pin_chargerLED on Facet mosaic
@@ -392,7 +402,7 @@ void settingsToDefaults()
392402
static const Settings defaultSettings;
393403
settings = defaultSettings;
394404

395-
checkArrayDefaults(); // This does not call recordSystemSettings
405+
checkArrayDefaults(); // This does not call recordSystemSettings
396406
checkGNSSArrayDefaults(); // This calls recordSystemSettings if any GNSS defaults are applied
397407
}
398408

@@ -898,13 +908,13 @@ void beginGpioExpanderSwitches()
898908
// PWRKILL is on pin 7. Driving it low will turn off the system
899909
for (int i = 0; i < 8; i++)
900910
{
901-
//Set all pins to low expect GNSS RESET and PWRKILL
911+
// Set all pins to low expect GNSS RESET and PWRKILL
902912
if (i == 5 || i == 7)
903913
gpioExpanderSwitches->digitalWrite(i, HIGH);
904914
else
905915
gpioExpanderSwitches->digitalWrite(i, LOW);
906916

907-
gpioExpanderSwitches->pinMode(i, OUTPUT);
917+
gpioExpanderSwitches->pinMode(i, OUTPUT);
908918
}
909919

910920
online.gpioExpanderSwitches = true;

Firmware/RTK_Everywhere/Tilt.ino

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,10 +299,10 @@ void beginTilt()
299299
result &= tiltSensor->sendCommand("LEVER_ARM=-0.00678,-0.01073,-0.0314"); // From stock firmware
300300
else if (productVariant == RTK_FLEX)
301301
{
302-
result &= tiltSensor->sendCommand("LEVER_ARM=-0.0282,-0.000,-0.0237"); // -28.2, 0. -23.7mm
302+
result &= tiltSensor->sendCommand("LEVER_ARM=0.03391,0.00272,0.02370"); // -28.2, 0. -23.7mm
303303

304304
//Send AT+INSTALL_ANGLE=180,0,0 if the IM19 module is mounted on the back of the GNSS receiver (so the IM19 faces downward instead of upward), before sending the save command.
305-
result &= tiltSensor->sendCommand("INSTALL_ANGLE=180,0,0"); //IMU is mounted facing down
305+
result &= tiltSensor->sendCommand("INSTALL_ANGLE=180,0,-90"); //IMU is mounted facing down
306306
}
307307

308308
// Set the overall length of the GNSS setup in meters: rod length 1800mm + internal length 96.45mm + antenna

0 commit comments

Comments
 (0)