When debugging programs that switch eight bits of a port for control purposes, it can be most useful to SERTXD the value to display on the console in binary form. This allows immediate identification of which lines are high or low.
For example;
sertxd ( "controls=", #bit7,#bit6,#bit5,#bit4, #bit3, #bit2, #bit1,#bit0, cr, lf )
My question is, is there a more elegant way of achieving this than the line I have just shown?
Also, is there any way of displaying higher variables, beyond b3, as binary strings without mapping them back to b0 and sertxd-ing the #bit values?
It would be super if one could "sertxd(%b5, cr, lf)" or some similar syntax... and have the binary string show on the console. Am I missing something?
For example;
sertxd ( "controls=", #bit7,#bit6,#bit5,#bit4, #bit3, #bit2, #bit1,#bit0, cr, lf )
My question is, is there a more elegant way of achieving this than the line I have just shown?
Also, is there any way of displaying higher variables, beyond b3, as binary strings without mapping them back to b0 and sertxd-ing the #bit values?
It would be super if one could "sertxd(%b5, cr, lf)" or some similar syntax... and have the binary string show on the console. Am I missing something?