Skip to content

Commit d26ede0

Browse files
committed
Update Example 1
Remove "SARA" references to keep it generic Add "Beginning..." print message to aid user in case module doesn't connect, which results in no messages for a long time
1 parent 8fbe23f commit d26ede0

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

examples/Example1_DeviceIdentification/Example1_DeviceIdentification.ino

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ String simStateString[] =
3333
"Operational" // 6
3434
};
3535

36-
// processSIMstate is provided to the SARA-R5 library via a
36+
// processSIMstate is provided to the u-blox cellular library via a
3737
// callback setter -- setSIMstateReadCallback. (See setup())
3838
void processSIMstate(UBX_CELL_sim_states_t state)
3939
{
@@ -48,29 +48,31 @@ void setup()
4848
Serial.begin(115200); // Start the serial console
4949

5050
// Wait for user to press key to begin
51-
Serial.println(F("SARA-R5 Example"));
51+
Serial.println(F("u-blox Cellular Example 1 - Device Identification"));
5252
Serial.println(F("Press any key to begin"));
5353

5454
while (!Serial.available()) // Wait for the user to press a key (send any serial character)
5555
;
5656
while (Serial.available()) // Empty the serial RX buffer
5757
Serial.read();
5858

59-
//myModule.enableDebugging(); // Uncomment this line to enable helpful debug messages on Serial
59+
Serial.println(F("Beginning..."));
60+
61+
// myModule.enableDebugging(); // Uncomment this line to enable helpful debug messages on Serial
6062

6163
// For the MicroMod Asset Tracker, we need to invert the power pin so it pulls high instead of low
62-
// Comment the next line if required
63-
myModule.invertPowerPin(true);
64+
// Uncomment the next line if required
65+
// myModule.invertPowerPin(true);
6466

65-
// Initialize the SARA
67+
// Initialize the module
6668
if (myModule.begin(mySerial, UBX_CELL_DEFAULT_BAUD_RATE) )
6769
{
68-
Serial.println(F("SARA-R5 connected!"));
70+
Serial.println(F("Module connected!"));
6971
}
7072
else
7173
{
72-
Serial.println(F("Unable to communicate with the SARA."));
73-
Serial.println(F("Manually power-on (hold the SARA On button for 3 seconds) on and try again."));
74+
Serial.println(F("Unable to communicate with the module."));
75+
Serial.println(F("Manually power-on (hold the module's On button for 3 seconds) and try again."));
7476
while (1) ; // Loop forever on fail
7577
}
7678
Serial.println();
@@ -95,5 +97,5 @@ void setup()
9597

9698
void loop()
9799
{
98-
myModule.poll(); // Keep processing data from the SARA so we can extract the SIM status
100+
myModule.poll(); // Keep processing data from the module so we can extract the SIM status
99101
}

0 commit comments

Comments
 (0)