Grove Serial Camera - Serial communication

Hi,
I’m using the example given in the wiki to communicate with the Grove Serial Camera through the serial port.

I reorganized the given example to the following:

#include <SoftwareSerial.h>


#define BAUDRATE 115200
#define LED_PIN  13

char length[] = {
  0x00,0x00,0x00,0x00};
char cmdRST[] = {
  0x56,0x00,0x26,0x00};//reset for at least 10ms (delay(10))
char cmdCAP[] = {      
  0x56,0x00,0x36,0x01,0x00};//take picture
char cmdGetLen[] = {
  0x56,0x00,0x34,0x01,0x00};//return:0x76 0x00 0x34 0x00 0x04 + 4bytes(image size) 
char cmdGetData[] = {        //get image data from the buffer of the camera ( 2 last byte * 0.01ms = interval time)
  0x56,0x00,0x32,0x0c,0x00,0x0a,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0a}; 
char cmdStop[] = {
  0x56, 0x00, 0x36, 0x01, 0x03};
char cmdConti[] = {
  0x56,0x00,0x36,0x01,0x02};//continue
char cmdPowSaf[] = {
  0x56, 0x00, 0x3e, 0x03, 0x00, 0x01, 0x01};
char cmdPowOn[] = {
  0x56, 0x00, 0x3e, 0x03, 0x00, 0x01, 0x00};
   

SoftwareSerial Camera(4,3); //rx,tx
  
void setup() {
  Serial.begin(BAUDRATE);
  Camera.begin(BAUDRATE);


}

void loop() {

  Camera.listen();
  Camera.flush();
  for(int i=0;i < 4;i ++){
    Camera.print(cmdRST[i]);//reset the camera
  }
  delay(10);

  while(Camera.available() > 0){
     int data = Camera.read();
     Serial.println(data,HEX);
  }
  
 
Serial.println("end");
   while(1) {
    if(Camera.available()>0) {
       int data = Camera.read();
       Serial.println(data,HEX);  
    } 
   }
}

I get the following output on my serial monitor

BA
C0
CB
40
E0
end
AA
34
F3
1B
59
83
C5
96
D8
CC
43
F1
E1
DA
5C
6B
64
3D
CF
CB
90
59
6E
AD
36
DB
48
7C
6D
B7
96
5B
99
AD
99
5A
AF
93
90
B6
B6
6F
BF
B9
85
C5
CF
4C
65
61
F1
A5
F7
6E
2E
B4
9B
8B
AD
AC
FE

I know this is a reaction from the camera, since when i disconnect it, no output is given.

The expected result is

76
0
26
0
end

Any help on this?
Thanks!

Dear customer,

Sorry we are not support with software.
Hope you can solve your problem.

Best regards,

Yuri