Truncated match.
PICList
Thread
'CCS C Compiler's ENABLE option'
1999\12\20@040730
by
Ali GOKSU
Hi All,
Please be informed that CCS C Compilers #use rs232 statement does not
correctly handle 'enable' option for rs485 transmission.
I used the following use directive.
#use rs232(baud=9600, xmit=PIN_C6, rcv=PIN_C7, parity=N, bits=8,
enable=PIN_C4, brgh1ok)
With this directive, when I use a stement like 'printf(string)' , PIN_C4 is
supposed to be HIGH during transmission, but it does not.
to cope with this, I used the following code fragment:
#use rs232(baud=9600, xmit=PIN_C6, rcv=PIN_C7, parity=N, bits=8, brgh1ok)
...
...
output_high(PIN_C4); // enable RS485 driver.
printf(string);
output_low(PIN_C4); // disable RS485 driver.
Regards, Ali GOKSU
Software Engineer
1999\12\20@140832
by
Bert Koerts
At 03:55 20-12-99 EST, you wrote:
>Hi All,
>
>Please be informed that CCS C Compilers #use rs232 statement does not
>correctly handle 'enable' option for rs485 transmission.
>
You have to set this pin as an output using something like #use
fixed_io(c_outputs=PIN_C1, PIN_C2, PIN_C5, PIN_C6). (see page 26 of your
reference manual - nov 1998)
What device / pins and compiler version do you use? The enable pin works
fine on 16C74A / 16C73A with pin_C5.
friendly regards,
Bert
More... (looser matching)
- Last day of these posts
- In 1999
, 2000 only
- Today
- New search...