Go Down

Topic: Original Arduino GSM Library - change RX / TX to Hardware Serial (Read 5065 times) previous topic - next topic

bastianth

Hej guys,

is anybody of you familiar with the original Arduino library gsm.h and can help me?

I need to change the rx tx pins from software serial to hardware serial (channel 2 on the Arduino Mega).

Is it possible?
I already tried the Rxpin / Txpin from GSM3Softserial.cpp to 16/17 (pins of Serial2 on the Mega) but it did not work.

Regards!

davidgoth

GSM3SoftSerial was designed for emulate a serial port by software, not for hardware native serial port. You have to modify it or create a new code for it.
If you can use a serial port emulate by software, RX pin must be a pin with support for interruptions.

bastianth


henry_C315

is it possible for me to use Original Arduino GSM Library with other GSM shield (not original GSM shield as well) for example from DFRobot? if it could, in which part i must adjust?

davidgoth

You can modify it. The most important things are software serial communication, commands compatibility, software flow control and responses times.

Matze2211

Could you solve the problem? I have got the same problem. I want to use hardwareserial.

davidgoth

In theory, you can replace all references to SoftwareSerial with Serial class.

nasirkhanmmd

the most important is that how to change pin software defined rx and tx (ardunio uno pins 2&3) gsm.h library to hardware 0&1 pins i mean what should we modify in that library to do so?

alessio31183

Dear all,
has anyone solved this issue on how to replace the software serial with the hardware one?

Because I've already designed a board that use the M10 GSM modem in order to communicate data on a IoT platform.

The problem is that the module is connected to the hardware serial pin instead of 2,3 as usual.

That was in order to save program space using HW pins since that I should not keep the hardware serial free.

Go Up
 


Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

Arduino
via Egeo 16
Torino, 10131
Italy