Communication between two PicChip


Closed Thread
Results 1 to 29 of 29

Hybrid View

  1. #1
    Join Date
    Sep 2006
    Posts
    747


    Did you find this post helpful? Yes | No

    Default Re: Communication between two PicChip

    i ADDed this after I sent the code yesterday.:
    TRISB = %00000000
    AND

    the other pic:
    TRISB =%11111111

    could it be in the include file?
    K

  2. #2
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default Re: Communication between two PicChip

    If you are talking about "modedefs.inc" no. You do not need that file for what you are doing so it is not doing any harm. It is for SERIN/SEROUT and a couple other commands.

    Have you tried sending/receiving to a PC?
    Dave
    Always wear safety glasses while programming.

  3. #3
    Join Date
    Sep 2006
    Posts
    747


    Did you find this post helpful? Yes | No

    Default Re: Communication between two PicChip

    nO DID NOT SEND TO pc. Actually never done that in my life....

  4. #4
    Join Date
    Sep 2005
    Location
    Campbell, CA
    Posts
    1,107


    Did you find this post helpful? Yes | No

    Default Re: Communication between two PicChip

    If you are using the hardware serial port (as I suggest), then the polarity will be wrong for a direct connection to a PC, so that won't work.

    If you issue HSEROUT [...] and the port doesn't even toggle, then you have some other problem.
    Charles Linquist

  5. #5
    Join Date
    Sep 2006
    Posts
    747


    Did you find this post helpful? Yes | No

    Default Re: Communication between two PicChip

    I can some steady activity on the HSEROUT port. Seems to me the receiving end is a problem. I used another picF88 chip in case it would be a hardwire pin problem, but still the LCD is not showing the input. I removed the First LCDOUT and juste the one after the HSERIN and the L:CD is showing blank...

  6. #6
    Join Date
    Sep 2005
    Location
    Campbell, CA
    Posts
    1,107


    Did you find this post helpful? Yes | No

    Default Re: Communication between two PicChip

    Are you using HSERIN for the receive side?

    Just do this -

    LCDOUT $FE,$1

    Topp:

    HSERIN [X]
    LCDOUT X

    Goto Topp
    Charles Linquist

  7. #7
    Join Date
    Sep 2006
    Posts
    747


    Did you find this post helpful? Yes | No

    Default Re: Communication between two PicChip

    this is what I have now. the tiny rail of the breadboard seems to be defective, although I tested it with my multimeter and it seems to be conducting, but then if I put the wire from the transmitting pic directly to the receiving chip leg then I could see something on the LCD. that fixed. I am sending 5 or 22 or 85 from the TX pic and I am always receiving 49 on the RX chip....
    Mainloop:

    Pause 50


    Hserin [encoded22]
    PAUSE 100

    lcdout $FE,1, "input ", bin encoded22
    pause 200


    goto Mainloop

    end

Members who have read this thread : 1

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