PBP 16F876A 2 Way Communication


Closed Thread
Results 1 to 14 of 14

Hybrid View

  1. #1
    dmugan's Avatar
    dmugan Guest


    Did you find this post helpful? Yes | No

    Default PBP 16F876A 2 way Communication

    Thanks Mat and Ioannis,

    The HSERIN command now reads:

    HSERIN [char var byte]

    I still get the same error

    ERROR Line 38: Expected '['.

    Anything else I should try? Thanks everyone.

  2. #2
    Join Date
    Oct 2003
    Location
    holland
    Posts
    251


    Did you find this post helpful? Yes | No

    Default

    There is al small misunderstanding.
    You should do this !
    DEFINE ADC_BITS 10
    DEFINE ADC_CLOCK 3
    DEFINE ADC_SAMPLEUS 10
    adcVar VAR WORD

    char VAR BYTE

    TRISA = %11111111
    ADCON1 = %10000010
    DEFINE HSER_RCSTA 90h
    DEFINE HSER_TXSTA 24h
    DEFINE HSER_BAUD 9600
    DEFINE HSER_CLOERR 1
    PAUSE 005

    main:
    If PIR1.5 = 1 THEN

    HSERIN [char] 'and than this

    HSEROUT [DEC adcvar, 10, 13]
    ENDIF
    ADCIN 0, adcVar
    PAUSE 50
    GOTO main

  3. #3
    dmugan's Avatar
    dmugan Guest


    Did you find this post helpful? Yes | No

    Default PBP 16876A 2 way Communication

    Mat,

    Thanks a million. The program now compiles ok, but it seems to hang during execution of the program. I have tried re-arranging the order of the instructions, but so far no luck. I will appreciate more suggestions

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


    Did you find this post helpful? Yes | No

    Default

    I'm going to tell you to READ THE PBP MANUAL now.
    Charles Linquist

  5. #5
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    a little typo error...
    Code:
    DEFINE HSER_CLOERR 1
    should be
    Code:
    DEFINE HSER_CLROERR 1
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  6. #6
    dmugan's Avatar
    dmugan Guest


    Did you find this post helpful? Yes | No

    Default PBP 16F876A 2 Way Communication

    Thanks to everyone, and a second time to Mister E for finding my typo. It now works like a charm! Have a great day!

Similar Threads

  1. 2 PIC, serial communication
    By lightgreen in forum Serial
    Replies: 6
    Last Post: - 21st November 2009, 15:20
  2. Help with 2 way communication
    By jessey in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 22nd April 2007, 09:11
  3. Microcontroller with 2 way paging application problem
    By oneohthree in forum mel PIC BASIC Pro
    Replies: 30
    Last Post: - 20th April 2007, 17:27
  4. PIC 2 PIC communication
    By Mario in forum Forum Requests
    Replies: 16
    Last Post: - 28th April 2006, 01:56
  5. hpwm more than 2 ch possible in pbp?????????
    By oscar in forum mel PIC BASIC Pro
    Replies: 20
    Last Post: - 10th March 2006, 07:28

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