serout


Closed Thread
Results 1 to 11 of 11

Thread: serout

Hybrid View

  1. #1
    Join Date
    Jun 2006
    Posts
    40


    Did you find this post helpful? Yes | No

    Default

    modedefs.bas is included but still doesn't work...

    i also tried :
    1. inverted TTL N300 to N2400
    2. change Define Char_pacing 1000 to 10000

    however it still not working...

  2. #2
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,612


    Did you find this post helpful? Yes | No

    Default

    Hi,
    What is the clock frequency and what do you use as the clock source? For serial communication to be reliable you really should use a X-tal. What baudrate did you set Hyperterminal to when testing the modem? 300baud?

    /Henrik Olsson.

  3. #3
    Join Date
    Jun 2006
    Posts
    40


    Did you find this post helpful? Yes | No

    Default

    I use 4MHz resonator. i did use the same type of resonator before when i did a serial comm project between 2 remote PIC 16F84 at 1200baud.

    In Hyperterminal, i tried 300 baud, 1200 baud and 2400 baud. All working fine. The only difference i noticed with this baud rates is the speed and it is obvious when i type AT&V.
    A modem should detect the baud rate automatical isn't ?

    mychangl

  4. #4
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,612


    Did you find this post helpful? Yes | No

    Default

    Hi,
    Generally you should be fine with the resonator. Are you sure that the PIC is running? Blink a LED a few times at the beginning of the program to make sure. And if you can, try with a X-tal just to be sure.

    You do have the PIC's ground and the modems ground connected don't you? The modem ground should be on PIN 5 in the DB9 but you didn't mention that in your original post.
    I have no knowledge of AT commands so I can't help with that but assuming it's correct have you tried:
    Code:
    SerOut Tx,t300,["ATH1"] ' Off Hook ATH1
    Also, is it possible that the modem needs a linefeed and/or carrage return at the end of the command?

    /Henrik Olsson.

  5. #5
    Join Date
    Jun 2006
    Posts
    40


    Did you find this post helpful? Yes | No

    Default

    the LED is blinking. i even put LED to monitor the serial output, it is flickering. Modem ground is connected to PIC gnd.

    neither
    SerOut Tx,t300,["ATH1"]
    SerOut Tx,t300,["ATH0"]
    SerOut Tx,t1200,["ATH1"]
    SerOut Tx,t2400,["ATH1"]
    SerOut Tx,t9600,["ATH1"]

    work, i not sure about line feed or carriage.There is no information about linefeed and carriage found in any modem articles, even hyperterminal doue not require that..

    Anyway, let me try

  6. #6
    Join Date
    Feb 2003
    Location
    Salt Lake City, Utah USA
    Posts
    517


    Did you find this post helpful? Yes | No

    Smile

    Something to try - see if you can get your pic to talk to hyperterminal (using your max232 setup as is). This might help you determine if the problem is closer to the PIC side or closer to the modem side.
    Paul Borgmeier
    Salt Lake City, UT
    USA
    __________________

  7. #7
    Join Date
    Jun 2006
    Posts
    40


    Did you find this post helpful? Yes | No

    Thumbs up

    Thanks guys. i got the code....

    it should has carriage return ( 13 ) after the command.

    SerOut Tx,t9600,[65,84,72,49] ' Off Hook ATH1'
    SerOut Tx,t9600,[13]

    now i am looking into more functions eg connect to other modem...

    Thx a lot !
    Cheeeeers

Similar Threads

  1. A Serial GLCD 128x64 Simple Project
    By Oldspring in forum Off Topic
    Replies: 0
    Last Post: - 8th March 2010, 20:58
  2. Serout to serial servo
    By azmax100 in forum mel PIC BASIC Pro
    Replies: 20
    Last Post: - 12th August 2009, 16:46
  3. Advice-scrutiny for my serial controller
    By kevlar129bp in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 13th December 2008, 17:11
  4. Keypad unlock (as in garage door possibly)
    By Fred in forum Code Examples
    Replies: 5
    Last Post: - 2nd April 2006, 04:26
  5. Replies: 11
    Last Post: - 13th July 2005, 19:26

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