RockBLOCK 9603 sends a message but get No Data

Good evening. I am working on this project for my bachelor's thesis, but it is quite different from what I have learnt in my degree and that is why it is being quite challenging and I am asking for help. I want to use a RockBLOCK 9603, a GPS and a OLED display to send a message showing the latitude and longitude. However, I am first learning to use the RockBLOCK 9603 modem by trying to send a simple text message without GPS or OLED. This is the code I have.

#include <SoftwareSerial.h>

SoftwareSerial rockBlockSerial(2, 3); // RX, TX (Arduino <-> RockBLOCK)

void setup() {
    Serial.begin(9600);  // Monitor output
    rockBlockSerial.begin(19200); // RockBLOCK communication

    Serial.println("Initializing RockBLOCK 9603...");

    delay(2000); // Allow RockBLOCK to initialize

    checkSignalStrength();  // Ensure satellite signal is available
    sendMessage("Hello from Arduino Uno!"); // Send test message

}

void loop() {
    // Listen for responses from RockBLOCK
    while (rockBlockSerial.available()) {
        Serial.write(rockBlockSerial.read()); // Print response to Serial Monitor
    }
}

void checkSignalStrength() {
    Serial.println("Checking signal strength...");
    rockBlockSerial.println("AT+CSQ");
    delay(2000);
    readResponse();
}

void sendMessage(String msg) {
    Serial.println("Sending message: " + msg);

    // Send the command to start writing the message
    rockBlockSerial.println("AT+SBDRT=" + msg); //rockBlockSerial.println("AT+SBDWB=" + String(msg.length())) this is originally, but did not work properly
    delay(5000);  // Give RockBLBOCK more time to respond
    rockBlockSerial.println("AT+SBDIX");
delay(5000);  // Give it time to transmit

// Read and print the response
while (rockBlockSerial.available()) {
  Serial.write(rockBlockSerial.read());
}


    // Wait for RockBLOCK to respond with "READY"
    if (!waitForResponse("READY")) return;

    // Send the message byte-by-byte
    // for (int i = 0; i < msg.length(); i++) {
    //     rockBlockSerial.write(msg[i]);
    // }

    // // Compute the checksum and send it
    // uint16_t checksum = 0;
    // for (int i = 0; i < msg.length(); i++) {
    //     checksum += msg[i];
    // }
    // rockBlockSerial.write((byte)(checksum >> 8));  // High byte
    // rockBlockSerial.write((byte)(checksum & 0xFF)); // Low byte

    delay(5000);  // Wait for RockBLOCK to process

    // Wait for confirmation "OK"
    if (!waitForResponse("OK")) return;

    Serial.println("Message sent successfully!");
}



bool waitForResponse(String expected) { //this function waits for a specific response, called expected
    unsigned long startTime = millis();
    String response = ""; // Store full response

    while (millis() - startTime < 5000) { // 5-second timeout
        while (rockBlockSerial.available()) {
            char c = rockBlockSerial.read();
            response += c; // Collect response fron rockBlockserial.read
        }
        if (response.length() > 0) {
            Serial.println("RockBLOCK response: " + response); // Debug print
            if (response.indexOf(expected) != -1) return true; // Check for expected response
        }
    }
    Serial.println("Error: '" + expected + "' not received. Got: " + response);
    return false;
}



void readResponse() {
    while (rockBlockSerial.available()) {
        Serial.write(rockBlockSerial.read()); // Print RockBLOCK response
    }
    Serial.println();
}

And this is what I get in the Serial Monitor.

Initializing RockBLOCK 9603...
Checking signal strength...
AT+CSQ

+CSQ:5

OK

Sending message: Hello from Arduino Uno!

Օ(*'Y[����Arduino Uno!

+SBDRT:

ERROR
AT+SBDIX
RockBLOCK response: 

RockBLOCK response: 
+SBDIX: 0, 7, 0, 0, 0, 0

O
RockBLOCK response: 
+SBDIX: 0, 7, 0, 0, 0, 0

OK

Regarding the specific documentation and data sheets from RockBLOCK developer guide and Ground Control Documentation and User Guides, the first 0 means "MO message, if any, transferred successfully." Nevertheless, the third number, which is 0, means "No SBD message to receive from the GSS." I get the message in RockBLOCK Admin and in my email but what I get is this (I have erased any important and irrelevant information)
IMEI: 3014340xxxxxx
MOMSN: 7
Transmit Time: 2025-02-05T13:36:09Z UTC
Iridium Latitude: xxxxxxx
Iridium Longitude: xxxxxxx
Iridium CEP: 2.0
Iridium Session Status: 0
No Data

To sum up, even though it seems that the modem communicates with the satellite, but it does not receive the proper text message from the Arduino and, therefore, can not send the text message to the satellite. At least, this is my theory, but I have never used something like this before nor used Arduino at this level in complexity. If anyone has an idea to solve this or can explain to me what is happening, please let me know.

Excuse me if I made any mistakes or did not express myself properly, English is not my native language. Also, this is my first time posting in this forum so if I made any mistake including the code or whatever, please let me know :slight_smile:

While working on it, I changed the code to.

#include <SoftwareSerial.h>

SoftwareSerial rockBlockSerial(2, 3); // RX, TX (Arduino <-> RockBLOCK)

void setup() {
    Serial.begin(9600);  // Monitor output
    rockBlockSerial.begin(19200); // RockBLOCK communication

    Serial.println("Initializing RockBLOCK 9603...");

    delay(2000); // Allow RockBLOCK to initialize

    checkSignalStrength();  // Ensure satellite signal is available
    sendMessage("Hello from Arduino Uno!"); // Send test message

}

void loop() {
    // Listen for responses from RockBLOCK
    while (rockBlockSerial.available()) {
        Serial.write(rockBlockSerial.read()); // Print response to Serial Monitor
    }
}

void checkSignalStrength() {
    Serial.println("Checking signal strength...");
    rockBlockSerial.println("AT+CSQ");
    delay(2000);
    readResponse();
}

void sendMessage(String msg) {
    Serial.println("Sending message: " + msg);

    // Send the command to start writing the message
    rockBlockSerial.println("AT+SBDWT=" + msg); //rockBlockSerial.println("AT+SBDWB=" + String(msg.length())) this is originally, but did not work properly
    delay(5000);  // Give RockBLBOCK more time to respond
    rockBlockSerial.println("AT+SBDIX");
delay(5000);  // Give it time to transmit

// Read and print the response
while (rockBlockSerial.available()) {
  Serial.write(rockBlockSerial.read());
}


    // Wait for RockBLOCK to respond with "READY"
    if (!waitForResponse("READY")) return;

    // Send the message byte-by-byte
    // for (int i = 0; i < msg.length(); i++) {
    //     rockBlockSerial.write(msg[i]);
    // }

    // // Compute the checksum and send it
    // uint16_t checksum = 0;
    // for (int i = 0; i < msg.length(); i++) {
    //     checksum += msg[i];
    // }
    // rockBlockSerial.write((byte)(checksum >> 8));  // High byte
    // rockBlockSerial.write((byte)(checksum & 0xFF)); // Low byte

    delay(5000);  // Wait for RockBLOCK to process

    // Wait for confirmation "OK"
    if (!waitForResponse("OK")) return;

    Serial.println("Message sent successfully!");
}



bool waitForResponse(String expected) { //this function waits for a specific response, called expected
    unsigned long startTime = millis();
    String response = ""; // Store full response

    while (millis() - startTime < 5000) { // 5-second timeout
        while (rockBlockSerial.available()) {
            char c = rockBlockSerial.read();
            response += c; // Collect response fron rockBlockserial.read
        }
        if (response.length() > 0) {
            Serial.println("RockBLOCK response: " + response); // Debug print
            if (response.indexOf(expected) != -1) return true; // Check for expected response
        }
    }
    Serial.println("Error: '" + expected + "' not received. Got: " + response);
    return false;
}



void readResponse() {
    while (rockBlockSerial.available()) {
        Serial.write(rockBlockSerial.read()); // Print RockBLOCK response
    }
    Serial.println();
}

And what I get is

Initializing RockBLOCK 9603...
Checking signal strength...
AT+CSQ

+CSQ:3

OK

Sending message: Hello from Arduino Uno!
�(OY[����Arduino Uno!

OK
AT+SBDIX
Error: 'READY' not received. Got: 

+SBDIX: 32, 8, 2, 0, 0, 0

OK

Now it seems it is not communicating with the satellite, but I am not sure how to know if the message is now properly saved in Iridium modem or what is the problem.

I got it. In case anyone is trying the same, here is the code I used

#include <SoftwareSerial.h>

SoftwareSerial rockBlockSerial(10, 11); // RX, TX (Arduino <-> RockBLOCK)

void setup() {
    Serial.begin(9600);  // Monitor output
    rockBlockSerial.begin(19200); // RockBLOCK communication

    Serial.println("Initializing RockBLOCK 9603...");

    delay(2000); // Allow RockBLOCK to initialize

    checkSignalStrength();  // Ensure satellite signal is available
    sendMessage("Hello from Arduino Uno!"); // Send test message

}

void loop() {
    // Listen for responses from RockBLOCK
    while (rockBlockSerial.available()) {
        Serial.write(rockBlockSerial.read()); // Print response to Serial Monitor
    }
}

void checkSignalStrength() {
    Serial.println("Checking signal strength...");
    clearSerialBuffer(); //clears any leftover data from the serial buffer to avoid interference
    rockBlockSerial.println("AT+CSQ"); //sends the AT command to the RockBLOCK
    delay(2000);
    readResponse();
}

void sendMessage(String msg) {
    Serial.println("Sending message: " + msg);

    // Send the command to store the message
    clearSerialBuffer();
    rockBlockSerial.print("AT+SBDWT="); 
    rockBlockSerial.println(msg);
    delay(2000);  // Wait for RockBLOCK response

    // Wait for confirmation "OK"
    if (!waitForResponse("OK")) {
        Serial.println("Error writing message to buffer.");
        return;
    }


    // Initiate message transmission
    clearSerialBuffer(); //clears buffer
    rockBlockSerial.println("AT+SBDIX");
    delay(8000);  // Give it time to transmit

    // Read and print the response
    readResponse();

    Serial.println("Message sent successfully!");
}




bool waitForResponse(String expected) { //this function waits for a specific response, called expected
    unsigned long startTime = millis();
    String response = ""; // Store full response

    while (millis() - startTime < 5000) { // 5-second timeout
        while (rockBlockSerial.available()) {
            char c = rockBlockSerial.read();
            response += c; // Collect response fron rockBlockserial.read
        }
        if (response.length() > 0) {
            Serial.println("RockBLOCK response: " + response); // Debug print
            if (response.indexOf(expected) != -1) return true; // Check for expected response
        }
    }
    Serial.println("Error: '" + expected + "' not received. Got: " + response);
    return false;
}

void clearSerialBuffer() {
    while (rockBlockSerial.available()) {
        rockBlockSerial.read();
    }
}


void readResponse() {
    while (rockBlockSerial.available()) {
        char c = rockBlockSerial.read();
        Serial.write(c);
        delay(5);  // Small delay to prevent buffer overflow
    }
    Serial.println();
}

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.