Confused by serin2 modes


Closed Thread
Results 1 to 2 of 2
  1. #1

    Default Confused by serin2 modes

    I have a 16F88 program which works well and uses Hserin and the following define and snipet of relevant code.

    Code:
    DEFINE HSER_BAUD 9600		'Set Baud rate to 9600bps
    DEFINE HSER_BITS 9		'Set to 9 bit mode
    DEFINE HSER_EVEN 1		'Set Even Parity
    DEFINE HSER_CLROERR 1 		'Clear overflow error automatically
    
    HSERIN [WAIT($87), STR BCMDATA\11]	'Wait for packet start $87 then Rxd 11 bytes into BCMDATA
    Now I want to transfer this program to a 12F683 chip so need to use Serin2, but although i can see what i believe the basic line should look like (below), the mode number is confusing. What mode or defines are equivalent to what I have with hserin above?

    The data is 8 bit with an even parity bit.

    Code:
    SERIN2 Bcm, ???, [WAIT($87), STR BCMDATA\11]

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


    Did you find this post helpful? Yes | No

    Default

    Code:
    DEFINE SER2_BITS 9
    SERIN22 PORTx.x, 8276, [wait($87), str bcmdata\11]
    Dave
    Always wear safety glasses while programming.

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