Modem Auto Answer-Hanging for 1 min...


Closed Thread
Results 1 to 22 of 22

Hybrid View

  1. #1
    Join Date
    Jul 2003
    Posts
    2,358


    Did you find this post helpful? Yes | No

    Default

    No, I don't think it's the PIC. I would place money on it being the modem.

    With a lot of modems with 'Hayes Style' command set, when you issue a command, the modem will reply (even if it's OK or just a plain CRLF).

    It is possible that during this reply the PIC has issued the next command (intercommand Pause too short)... and in so doing the modem has lost part of the next command string receiving a corrupted sequence which in turn has caused it to timeout.

    You could verify this by increasing the Pauses to something really long (eg PAUSE 5000 rather than 500) and see if it still hangs. If it doesn't, then that's the reason... your modem probably has poor firmware that can't simultaneously cope with a new command string whilst the reply to the previous one is still being processed.

    Don't quote me, but I think there's a command to suppress these responses from the modem... you could always issue that first. That might also stop the problem.

  2. #2
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,170


    Did you find this post helpful? Yes | No

    Default

    Hmm, how much would you bed on it?? **smiles**!

    The problem is still there. I just moved the sub's from top of program to the bottom of it and this part works OK now! Any explains? I usually put all sub's on top.

    It is weird...

    Ioannis

    P.S. Of course half of the sub's do not work!!!
    Attached Files Attached Files
    Last edited by Ioannis; - 16th August 2005 at 13:52.

  3. #3
    Join Date
    Jul 2003
    Posts
    2,358


    Did you find this post helpful? Yes | No

    Default

    Is that an invitation?

    Short of going through your program line by line I can't comment, but what version of PBP are you using? I do recall early versions of PBP did have some issues, and I do recall some strange things in 2.42... but ceratinly not now.

  4. #4


    Did you find this post helpful? Yes | No

    Default

    Just curious if when you send all commands at once are you certain that all commands are received and processed? The PIC might sending the info too fast and the modem is only responding to one of the commands when it replies "OK". This I think would be along the same lines as Melanie thoughts.

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


    Did you find this post helpful? Yes | No

    Default

    Thanks all. Well, Melanie of course it is! I do challenge you!

    By no means I asked to go through line by line. Just for reference the code was included.

    The version is latest. I had from time to time problems with subroutines and the way was to shorten the length of each one. Now, the symptom is quite strange and the program execution even more. As stated earlier the third Hserout executes to the point ats0= and then it stops for about a minute! This I saw with my eyes on a terminal program. By now there is no explanation as to what might happening.

    If the three commands are joined then the execution flows like calm water.

    About the modem, cocacolakid, the modem has no problem to process the commands, since the CR/LF has not arrived yet.

    Ioannis

  6. #6
    Join Date
    Oct 2004
    Location
    Italy
    Posts
    695


    Did you find this post helpful? Yes | No

    Default

    Download this free terminal program and try the
    modem with the serial port of your PC.
    (Just 3 wires, RX,TX,GND)

    The program is only an EXE file, no setup.

    With this program you can create 12 macros.

    Example of macro:

    AT#013#010
    This will send AT and "CR" + "LF" (cariage return + line feed)

    Terminal program home page:
    http://bray.velenje.cx/avr/terminal/

    File download link:
    http://bray.velenje.cx/avr/terminal/dl.php

    Luciano

  7. #7
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,170


    Did you find this post helpful? Yes | No

    Default

    Hi!

    The problem is not with the modem. It is with the PIC code executing up to a point then stops for a minute or so and then resumes.

    No interrupts or other source is envolved. The problem is on the 3 Hserout. If the 3 becomes 1 OR the LOCATION of the code changes, then it executes normally.

    This is the problem!

    I do not have to wait for the modem to respond. I just wait and give next command after a while.

    I believe it is a problem related with the "code crosses boundary @ ..." that shows up 3 times since the code is long enough.

    Ioannis

Similar Threads

  1. No Modem response
    By jimboho in forum mel PIC BASIC Pro
    Replies: 16
    Last Post: - 11th November 2004, 06:58

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