6 Replies Latest reply on Oct 19, 2016 9:43 AM by FGT

    SD file to be sent UART via GSM+AT commands

    lalo15894

      Im testing the intel Galileo 2 with GSM module SIM900, in this case im using MMS AT comands to send MMS before that I made it some test on Arduino and the code its works perfectly,but In intel Galileo I have a problem in one part of the code I need to send the file "copia.jpg" by Serial1 port the file copia.jpg its on SD card.

       

      Here my code on Arduino Sketch:

       

       

      codigo.JPG

       

      Codigo1.JPG

      Codigo2.JPG

       

      Codigo3.JPG

      The problem its on Serial1.write(data) because when the module GSM receive the instruction AT+CMMSDOWN its response with connect  command.

      Captura.JPG

      and after that I can send the picture by Serial and the module responses Ok if the file received its the same size of dataFile.size() in this case the module its not receiving the file and give me error response.

       

      Here the file that I need send to Serial1: "copia.jpg"

      Captura4.JPG

        • 1. Re: SD file to be sent UART via GSM+AT commands
          FGT

          Hi lalo15894,

           

          I don't have any GSM module to try, but maybe we can try something...

           

          lalo15894 wrote:

          ...

          Codigo3.JPG

          The problem its on Serial1.write(data) because when the module GSM receive the instruction AT+CMMSDOWN its response with connect command.

          Captura.JPG

          and after that I can send the picture by Serial and the module responses Ok if the file received its the same size of dataFile.size() in this case the module its not receiving the file and give me error response.

           

          What is the error response? please add reading Seral1, and if something is available, and report if something is sent from the GSM to the sketch

           

          What module is giving the error response? I assume it's the GSM, but maybe I'm losing something.

           

          HTH,

           

          Fernando.

          • 2. Re: SD file to be sent UART via GSM+AT commands
            lalo15894

            Sorry for late answer well, the error response its the GSM here the command on the Datasheet, Im using a Write command: Captura.JPG

            Im seeing the response module with hyperterminal because the GSM has a RS232 pins to debug it... I think that the galileo send incomplete data by serial, or maybe the library SD.h its making problems. For example making some test add this part of code:

            Captura.JPGand the file send it correctly but i dont know when I dont open the port Serial always the GSM dont receive the data correctly o maybe incomplete.

            • 3. Re: SD file to be sent UART via GSM+AT commands
              FGT

              lalo15894 wrote:

               

              I think that the galileo send incomplete data by serial, or maybe the library SD.h its making problems. For example making some test add this part of code:

              Captura.JPGand the file send it correctly but i dont know when I dont open the port Serial always the GSM dont receive the data correctly o maybe incomplete.

              Do you mean that if you open the Serial as shown in your code the file is sent without errors? If that's the case, maybe the problem is about communiatioin speed... try to use a minor value for bauds in the communication by Serial1... Maybe it's related and maybe not, but I've had some trouble with AT devices due to insufficient power the AT module, how is the GSM powered (a picture and schematic may help)?.

               

              Fernando.

              • 4. Re: SD file to be sent UART via GSM+AT commands
                Intel Corporation
                This message was posted on behalf of Intel Corporation

                Hi Lalo,

                Have you been able to check FGT’s post? I’m wondering if you’ve been working on this lately, or if you have any update.

                Regards,
                -Pablo

                • 5. Re: SD file to be sent UART via GSM+AT commands
                  lalo15894

                  Sorry for the late answer I´ve been bussy for now the project its working fine thanks for all, the solution was use minor value for baud rates. Greetings and thanks for all.

                  1 of 1 people found this helpful
                  • 6. Re: SD file to be sent UART via GSM+AT commands
                    FGT

                    lalo15894 wrote:

                     

                      the solution was use minor value for baud rates. Greetings and thanks for all.

                     

                    Great, thank you very much for sharing,

                     

                    Fernando.