Rs485 Using Hserin/hserout


Closed Thread
Results 1 to 28 of 28

Hybrid View

  1. #1


    Did you find this post helpful? Yes | No

    Default

    Here is my updated code.
    Still getting..
    <b>
    WAITING FOR REPLY..
    WAITING FOR REPLY..
    WAITING FOR REPLY..
    WAITING FOR REPLY..
    WAITING FOR REPLY..
    </b>


    Hope I am not missing something?


    Slave
    <img src="http://www.picbasic.co.uk/forum/attachment.php?attachmentid=2316&stc=1&d=120172226 9">


    Master
    <img src="http://www.picbasic.co.uk/forum/attachment.php?attachmentid=2317&stc=1&d=120172226 9">
    Attached Images Attached Images   

  2. #2
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    You've got LEDs on both modules, Yes?
    Well, use them!
    Make them blink whenever they 'receive a message' or whatever.
    Forget about a specific message format for now, just get the things to recognize data in general.
    And again, lose the SEROUT debug messages, make the LEDs blink or something.

    Unless of course your TX and RX lines are backwards or something...

  3. #3
    Join Date
    Jan 2006
    Location
    Istanbul
    Posts
    1,185


    Did you find this post helpful? Yes | No

    Default

    1. I would put a 1 second pause to Master at initial startup (no pause to slave)
    2. I would also make a minor modification as below:

    Instead of HSEROUT ["S0"] I would use HSEROUT ["XYZ","0"]

    and then
    instead of hserin 10,MAIN,[WAIT ("S"),DATARECEIVED] ' Looking for "S0"

    I would use HSERIN 10,MAIN,[WAIT ("XYZ"),DATARECEIVED] ' Looking for "0"


    ------------------
    "If the Earth were a single state, Istanbul would be its capital." Napoleon Bonaparte

  4. #4
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default

    Where is the interrupt routine? I see if rcif in the early code and it is now missing,
    look at this thread especially posts 8, 16.
    http://www.picbasic.co.uk/forum/showthread.php?t=4972
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

Similar Threads

  1. RS485 splitter
    By The Master in forum Off Topic
    Replies: 0
    Last Post: - 30th August 2009, 06:04
  2. RS485 Vs Wireless (TWS-434A)
    By koossa in forum Off Topic
    Replies: 3
    Last Post: - 11th April 2009, 12:40
  3. Using 16f676 with comms
    By Peter1960 in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 28th October 2005, 20:01
  4. RS485 - ibutton network
    By ccsparky in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 6th June 2005, 21:48
  5. RS485 Extender
    By SergioRM in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 28th December 2004, 00:09

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