Siemens c55 sms control help please


Closed Thread
Results 1 to 40 of 86

Hybrid View

  1. #1

    Default Siemens c55 sms control help please

    Hi,

    I cant put this simple sms sender to work in pic(the phone works pdu mode only on hterminal works all call and sms) . In my code you can see 2 parts 1 is the dailing that works fine the other was to be a sms sender but i cant put it to work can you please helpp me on that thans a lot.

    By by

    Code:
    @ Device HS_OSC         ' High Speed Crystal
    define OSC 20    
            
    Include "modedefs.bas" ' Include serial modes
    
    ' Define LCD registers and bits this time not use it for later apps..
    Define	LCD_DREG	PORTB           'Lcd D 4-bit parallel register starts at PortB.4 to PortB.7
    Define	LCD_DBIT	4              
    Define	LCD_RSREG	PORTB
    Define	LCD_RSBIT	2
    Define	LCD_EREG	PORTB
    Define	LCD_EBIT	3
    Define  LCD_COMMANDUS   2000	      ' Command Delay (uS)
    Define  LCD_DATAUS      50 	     ' Data Delay (uS)
    DEFINE  OSC         20                'Define oscilator frequency
    DEFINE LCD_LINES 4 'Number lines on LCD 
    
    DEFINE HSER_RCSTA 90h ' Enable serial port & continuous receive
    DEFINE HSER_TXSTA 24h ' Enable transmit, BRGH = 1
    DEFINE HSER_SPBRG 129 ' 9600 Baud @ 20MHz, 0.16%
    DEFINE HSER_CLROERR 1 ' Clear overflow automatically
            
    TrisC.5=0
    TrisC.6=0
    TrisC.7=1
    B0 var byte
    
    High portC.5 ' Led flashing to see if wardware are ok
    Pause 500
    Low portC.5
    Pause 500
    High portC.5
    Pause 500
    Low portC.5
    Pause 500
    
    
    HSEROUT ["AT", 13]
    HSEROUT ["ATD+351xxxx31210;", 13] 'phone dials to number no problem here
    pause 5000   
                                          
    ' Now were is the problem is when i thange the dialing line command for the sms to send a sms and the phone do nothing.. :(
    'HSEROUT ["AT", 13]  
    'HSEROUT ["AT+CMGS=16", 13]
    'HSEROUT ["079153912601000011000C915391663921010000AA02EF35",13]
    STOP
    end
    Last edited by camolas; - 28th June 2008 at 18:31. Reason: more things to add

  2. #2


    Did you find this post helpful? Yes | No

    Default

    On my searchs i find more info now i can send the sms from hterminal but not from the pic i read that "Hserout [20]" is the Ctrl+z end command but some thing is still missing for me i belave the problem must be on the sending command..... plz give ne some hellp.Thanks


    Hserout ["at", 13]
    Hserout ["at+cmgs=16", 13]
    Hserout ["079153912601000011000c915391663921010000aa02ef35" ,13]
    Hserout [20]

  3. #3
    Join Date
    Dec 2007
    Location
    Cd. Juarez, Mexico
    Posts
    8


    Did you find this post helpful? Yes | No

    Default

    Here is a section from my program to send a sms. I'm using a WAVECOM modem, but I think the AT commans are the same for all brands.

    sms:
    HSerout ["AT",13]
    HSERIN 5000, SMS,[WAIT("OK")] ' wait for response ok for 5 seconds
    HSerout ["AT+CMGF=1",13] 'Set Text Mode
    HSERIN 5000, SMS,[WAIT("OK")] ' wait for response ok for 5 seconds
    HSerout ["AT+CMGS=",str tel\14,13] ' dial the phone number
    HSERIN 5000 , SMS, [WAIT(">")] 'wait for a response to send the message
    HSerout ["Esto es solo una prueba",13] 'write the message
    HSerout [26] 'exit message mode
    Pause 500
    GOTO ESPERA 'exit sms rutine

    and it works great!!!!!!!

    I hope it can help you

  4. #4


    Did you find this post helpful? Yes | No

    Default

    Hi,

    thanks for caring, but de siemens c55 do not have text sms only pdu. I think i need in the pdu array some send command... like i have used in hterminal the ctrl+z.
    (Mi problema esta en comandar la trama pdu)

    Gracias

    Thanks,

  5. #5
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,132


    Did you find this post helpful? Yes | No

    Default

    Hi Norbac. Are you sure it is working? After AT+CMGS= there is a need for " character. Maybe your module does not needed.

    Here is an older post I gave as an example:

    Code:
    HSerout ["AT+CMGS=",34,your numbers here,34,13]
    hserin 2000,noresp,[wait(">")]
    HSerout ["your message here",26]
    hSerin 5000,noresp,[wait("OK")]
    LCDOut com,1,"Sent OK":Pause 1000
    GoTo .....
    noresp:
    LCDOut com,1,"Message not sent...":Pause 1000
    GoTo....
    34 is " character
    26 is Ctrl+Z character

    To Camolas: find another mobile with text. PDU is difficult format. Does not worth it. You may find cheap phones and modules to try.

    Ioannis
    Last edited by Ioannis; - 30th June 2008 at 19:09.

  6. #6
    Join Date
    Dec 2007
    Location
    Cd. Juarez, Mexico
    Posts
    8


    Did you find this post helpful? Yes | No

    Default

    You are rigth, according with the standard, the CMGS command needs a " for the phone number. But for some reason on my modem does not need it. I will change just to follow the standard.

    Thanks for your feedback.

  7. #7


    Did you find this post helpful? Yes | No

    Default

    Hi,

    Thanks for caring, i have one nokia 6230 but i have tried for one month to connect it to pc but no sucess then i moved to siemens c55 and made it. Can you please just tell me how i have to do (pbp code, because my pdu array works fine in pc connection) to end my pdu array and send the send command (ctrl+z) ??

    Thanks

    By by


    Quote Originally Posted by Ioannis View Post
    Hi Norbac. Are you sure it is working? After AT+CMGS= there is a need for " character. Maybe your module does not needed.

    Here is an older post I gave as an example:

    Code:
    HSerout ["AT+CMGS=",34,your numbers here,34,13]
    hserin 2000,noresp,[wait(">")]
    HSerout ["your message here",26]
    hSerin 5000,noresp,[wait("OK")]
    LCDOut com,1,"Sent OK":Pause 1000
    GoTo .....
    noresp:
    LCDOut com,1,"Message not sent...":Pause 1000
    GoTo....
    34 is " character
    26 is Ctrl+Z character

    To Camolas: find another mobile with text. PDU is difficult format. Does not worth it. You may find cheap phones and modules to try.

    Ioannis

  8. #8
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,132


    Did you find this post helpful? Yes | No

    Default

    I gave you the code. You even quoted to the reply. Please read carefully. The ctrl-Z is there. As for the PDU I cannot help you, sorry.

    Ioannis

  9. #9
    Join Date
    May 2008
    Location
    Italy
    Posts
    825


    Did you find this post helpful? Yes | No

    Smile

    Hi, when you enter with a voice command then you have to close it with "ATH" otherwise you will never return to data mode.
    Regards

  10. #10


    Did you find this post helpful? Yes | No

    Default

    Hi,

    Please explain what you said.
    Now i want to read a sms line code HSEROUT ["AT+CMGR=1",13,10]
    but i do not now read it and compare with the IF SMS="pdu array" then .....
    Can you please hellp me on that?

    Thanks

  11. #11
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,132


    Did you find this post helpful? Yes | No

    Default

    pbp does not have string comparison commands (Hey Darrel, what about a macro for this??)

    So you have to compare one character at a time using nested if-then.

    Ioannis

  12. #12


    Did you find this post helpful? Yes | No

    Default

    Hi,

    Sow i can not store the sms full received pdu array as var word and then compar it with IF...THEN... ?
    Im very new at all this can you please give me a example sow i can see how to do?

    Thanks
    Last edited by camolas; - 7th July 2008 at 19:17.

  13. #13
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,132


    Did you find this post helpful? Yes | No

    Default

    You ca store in an array of bytes whatever you want, but cannot do this if myarray="1234567890" then do that.

    You have to do a nested if-then comparison like that:

    if myarray[1]="1" then
    if myarray[2]="2" then
    if myarray[3]="3" then
    ....
    if myarray[0]="0" then
    goto success
    endif
    ....
    endif
    endif
    endif

    no_success:


    success:


    Of course this can be done with a for-next loop more elegant, but for the sake of simplicity I left it like that.

    Ioannis

Similar Threads

  1. sms to control pic..pls help...
    By Ziki in forum mel PIC BASIC Pro
    Replies: 53
    Last Post: - 12th April 2010, 21:19
  2. Replies: 11
    Last Post: - 19th August 2009, 15:23
  3. SMS control for Relays
    By charudatt in forum Code Examples
    Replies: 15
    Last Post: - 2nd May 2009, 00:08
  4. Reading a SMS to an array
    By KA5MAL in forum GSM
    Replies: 3
    Last Post: - 17th June 2008, 17:24
  5. Control RC servo via Parallax Servo Control
    By cibotsan in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 17th September 2005, 08:18

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts