Serial Communication using 12F629


Closed Thread
Results 1 to 6 of 6

Hybrid View

  1. #1
    Join Date
    Sep 2003
    Location
    Vermont
    Posts
    373


    Did you find this post helpful? Yes | No

    Default

    [QUOTE=charudatt]Hello Ron,

    I think that is the case !. Because , its not that I am not getting anything out, but just that its Garbage.

    Can you suggest how to use the INTOSC Config in the code.

    An easier way to do it, is to find out if the rate is too fast or too slow. This can be done with a frequency meter. If it is, for arguement sake, too fast, I would do a for next loop incrementing the serin2 baud rate number by one, until the character or word coming out of the pin is the right one.

    Example: For A = 1 to 100
    Serout2 pin,32768 + A,[dec A, "test"]
    Next A

    On the receive side, you should get the right number and right date when the baud rate is correct. Just add the number ti the baud number and all will be right with the world. If you don't have access to a meter, then try it above and below the proper number.

  2. #2
    kattronics's Avatar
    kattronics Guest


    Did you find this post helpful? Yes | No

    Default

    First, Make sure u have a small Cap on the power supply! (.1uF) . If that dose not fix it then ,

    Add this after your "fuses"
    DEFINE OSCCAL_1K 1

    Change this:
    SEROUT2 SER, 16780,["TEST" , 10] '2400 BAUD RATE
    To
    SerOut GPIO.4,N2400,["Test" ,10]

  3. #3
    Join Date
    Sep 2003
    Location
    INDIA
    Posts
    161


    Did you find this post helpful? Yes | No

    Default

    Kattronics:

    I already tried what you said, with the DEFINE OSCCAL_1K 1 the PIC goes bonkers. Not sure what is wrong with it.

    I also tried the SerOut GPIO.4,N2400,["Test" ,10] but no luck,

    I think I would go with Ron's suggestion and try it out.

    Nevertheless I succeeded in decoding Sony IR codes using the PIC ,which was my end intentions anyway, but just for the sake of testing out serial communication , I would compelete this experiment and post my results.

    Thank you all.

Similar Threads

  1. Wireless serial communication question
    By Ahmadabuomar in forum Serial
    Replies: 3
    Last Post: - 21st December 2009, 04:49
  2. PIC to PIC "wired" serial one-way communication - SERIN2/SEROUT2
    By flotulopex in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 14th April 2008, 21:02
  3. Bootloader,MCSP and Serial communication
    By surfer0815 in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 3rd March 2006, 11:52
  4. Serial communication PIC to PIC help.
    By Rubicon in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 24th January 2005, 16:45
  5. Replies: 8
    Last Post: - 11th November 2004, 21:08

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