TRIS_X assignment issue
Bean,
For the SX48/52
When I use a local byte to assign it to tris_x,
the compiler generates error "Byte parameter expected"
SUB mySub
· a var byte
· b var word
· tris_A = __param1 'ok
· a = tris_A 'ok
· tris_A = a 'generates error
ENDSUB
I don't see a reason why this should be. If necessary
a can be loaded into a __PARAMX first.
Another question regarding tris_x:
For the sx48/52, __TRIS EQU $FF is declared (also TRIS_X).
Where is this __TRIS used for?
regards peter
For the SX48/52
When I use a local byte to assign it to tris_x,
the compiler generates error "Byte parameter expected"
SUB mySub
· a var byte
· b var word
· tris_A = __param1 'ok
· a = tris_A 'ok
· tris_A = a 'generates error
ENDSUB
I don't see a reason why this should be. If necessary
a can be loaded into a __PARAMX first.
Another question regarding tris_x:
For the sx48/52, __TRIS EQU $FF is declared (also TRIS_X).
Where is this __TRIS used for?
regards peter
Comments
Yes, your right. I'll fix that right away.
Thanks again.
Bean.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Does that byte of memory hold "A", 65, $41 or %01000001 ?
Yes it does...
·
· Here is a new Beta for 2.00.30
· I think I fixed the problem. I also optimized the localbyte = register instructions (they no longer use __PARAM1).
Bean
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Does that byte of memory hold "A", 65, $41 or %01000001 ?
Yes it does...
Just what·is TRIS_X ($ff) used for?
Certainly not for just changing pin direction.
regards peter
Post Edited (Peter Verkaik) : 7/20/2009 10:06:29 PM GMT
Will this version 30 be posted in the sticky thread?
And what about TRIS_X for the SX48/52?
Is there any SX/B command that uses that location?
regards peter