mikendee
- 17th February 2010, 08:45
Hi,
I have just stumbled onto a problem. If I declare the baud mode on SEROUT2 as a constant it compiles Okay but doesn't work.
eg:
BAUD CON 84
SEROUT2 PORTB.2, BAUD,["TEST",13]
But this does work
BAUD var Byte
BAUD = 84
SEROUT2 PORTB.2, BAUD,["TEST",13]
I have tried it with both 16F88 and 18F4550 pics and I have seen this method used in other posts such as http://www.picbasic.co.uk/forum/showthread.php?t=3789.
Is this usual or is it just me or my programmer or something.
Thanks for any ideas. Mike
I have just stumbled onto a problem. If I declare the baud mode on SEROUT2 as a constant it compiles Okay but doesn't work.
eg:
BAUD CON 84
SEROUT2 PORTB.2, BAUD,["TEST",13]
But this does work
BAUD var Byte
BAUD = 84
SEROUT2 PORTB.2, BAUD,["TEST",13]
I have tried it with both 16F88 and 18F4550 pics and I have seen this method used in other posts such as http://www.picbasic.co.uk/forum/showthread.php?t=3789.
Is this usual or is it just me or my programmer or something.
Thanks for any ideas. Mike