Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Sending sms using LabVIEW

Hii all,

I am working on a GSM Modem project in which I need to send a SMS using LabVIEW.

 

I have USB GSM Modem which works perfectly with HyperTerminal using AT commands. I know there are many post regarding the same issues, but after reading and trying those I decided to post my query.

 

I am trying to communicate using LabVIEW, but am receiving same string as transmitted one. If am sending “AT”, I am expecting reply to be “OK” but am getting “AT” only. It is same for every AT commands. Not only for AT commands, it is simply performing a loopback test.

 

There is no termination character used for my modem. I am using “End of Line Constant”.

 

Thanks & Regards,

Manisha

0 Kudos
Message 1 of 18
(8,727 Views)

Hi Man_Can

 

You need to read the "OK" responses back.  Take a look at the Basic Serial Write and Read.vi example:

 

Basic Serial Write and Read.png

 

Regards,

 

-SS



0 Kudos
Message 2 of 18
(8,719 Views)

Hiiii ShotSimon,

 

Thanks for your reply.

 

I have tried the same example, in which also am getting the same reply. I have kept the echo off using ATE0 command in hyperterminal. I am attaching the screenshot of the basic read write vi, which shows the reply. Where am going wrong?

 

Please help me out with this. 

 

Thanks & Regards,

Manisha

0 Kudos
Message 3 of 18
(8,710 Views)

Hiii,

 

Now I have try https://sites.google.com/site/tstalevski/labview-send---receive-sms-message this link and trying to communicate using subvi mentioned in this. Am getting error as "Error (AT Command which am sending)". Why is it so?

 

Please reply me if am making any mistake.

 

Thanks & Regards,

Manisha

0 Kudos
Message 4 of 18
(8,708 Views)

Hi Man_Can,

 

What is your hardware setup and voltage level of your receiving hardware?  Looks to me like in your first picture pin 2 and 3 on your com port are looped on the TX and RX pin.  Also you need to make sure you have a ground connection on pin 5.  Also if your com port is not closed properly it could be hanging, easiest solution is to reboot your PC in this case.

 

Regards,

 

-SS



0 Kudos
Message 5 of 18
(8,697 Views)

Hi Manisha,

 

you got error ""AT+CMGF Error" from subVI "GSM command CMGF.vi" because this subVI didn't read expected answer from modem "<CR><LF>OK<CR><LF>". It seems that your modem doesn't work properly. I've tested all my subVIs with Wavecom RS-232 modem M1306B and all subVIs and main program were worked correctly. Tell me the vendor end model of your modem and I'll try to help you. Also, you can contact me by mail.

 

regards

 

Trajan

 

trajan@vinca.rs

 

 

0 Kudos
Message 6 of 18
(8,673 Views)

Hii ShotSimon,

 

I have P300U Edge/GPRS USB Modem. Am attaching product manual for the same. Port is working fine, no issues with the port, I have checked that properly. Because it is giving output with Hyper. 

 

Thanks & Regards,

Manisha

0 Kudos
Message 7 of 18
(8,668 Views)

Hi MAN_CAN,

 

I was guessing that you were trying to communicate via RS232 but from this manual it looks like you are actually using USB.  Please take a look at the forums regarding USB, for example: https://forums.ni.com/t5/LabVIEW/Nugget-1-of-n-GEtting-started-with-USB-communication-via-VISA/m-p/7...

 

Are you using some type of USB-Serial converter on Hyperterminal?  What operating system are you running?

 

Thanks,

 

-SS

 

 

 

 



0 Kudos
Message 8 of 18
(8,655 Views)

Hiii ShotSimon,

 

I have already mentioned that, am using USB GSM modem. No am not using any converter for testing it on hyper but still it is working perfectly and not giving me any error. I can send as well as receive sms using hyper. I am using windows 7 OS.

 

I will go through that thread. Hopefully it will solve my problem. 

 

Thanks & Regards,

Manisha

0 Kudos
Message 9 of 18
(8,640 Views)

Hiii ShotSimon,

 

I have already mentioned that, am using USB GSM modem. No am not using any converter for testing it on hyper but still it is working perfectly and not giving me any error. I can send as well as receive sms using hyper. I am using windows 7 OS.

 

I will go through that thread. Hopefully it will solve my problem. 

 

Thanks & Regards,

Manisha

0 Kudos
Message 10 of 18
(8,640 Views)