NI Home
Cart Cart | Help
Hello Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI
You are here: 
NI Home > NI Developer Zone > NI Discussion Forums


Reply
Member
Man_Can
Posts: 60
0 Kudos

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

Active Participant
ShotSimon
Posts: 532
0 Kudos

Re: Sending sms using LabVIEW

[ Edited ]

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



Member
Man_Can
Posts: 60
0 Kudos

Re: Sending sms using LabVIEW

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

Member
Man_Can
Posts: 60
0 Kudos

Re: Sending sms using LabVIEW

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

Active Participant
ShotSimon
Posts: 532
0 Kudos

Re: Sending sms using LabVIEW

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



Member
trajan
Posts: 24
0 Kudos

Re: Sending sms using LabVIEW

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

 

 

Member
Man_Can
Posts: 60
0 Kudos

Re: Sending sms using LabVIEW

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

Active Participant
ShotSimon
Posts: 532
0 Kudos

Re: Sending sms using LabVIEW

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: http://forums.ni.com/t5/LabVIEW/Nugget-1-of-n-GEtting-started-with-USB-communication-via-VISA/m-p/74...

 

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

 

Thanks,

 

-SS

 

 

 

 



Member
Man_Can
Posts: 60
0 Kudos

Re: Sending sms using LabVIEW

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

Member
Man_Can
Posts: 60
0 Kudos

Re: Sending sms using LabVIEW

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

By using this web site, you accept the Terms of Use for this web site. Please read these Terms of Use carefully before using any part of this site. Please go here for information on ni.com's copyright infringement policy.
My Profile | Privacy | Legal | Contact NI © 2011 National Instruments Corporation. All rights reserved.    |    E-Mail this Page E-Mail this Page