??? 01/28/05 11:28 Read: times |
#86001 - like this Responding to: ???'s previous message |
David Smith said:
;
*-ACC_bin ;Converts 2 digit BCD in ACC to bin in ACC ;does not detect hex (>99h) i/p; so 0A -> 0A, 10 -> 0A, 1A -> 14 ;uses r1 .ACC_bin: push B mov r1,a swap a anl a,#0fh ;msn mov B,#10 mul ab ab1: xch a,r1 ;lsn anl a,#0fh add a,r1 pop B abx: ret Do this with the [pre] and [/pre] tags (use standard HTML brakcketsm, not square ones) |
Topic | Author | Date |
Hex 2 Bin problem with program 8051 | 01/01/70 00:00 | |
you do it first | 01/01/70 00:00 | |
hex to bin | 01/01/70 00:00 | |
Re: hex to bin | 01/01/70 00:00 | |
Surely: BCD to bin (hex is bin?) | 01/01/70 00:00 | |
like this | 01/01/70 00:00 | |
brackets![]() | 01/01/70 00:00 | |
Posting | 01/01/70 00:00 | |
better code | 01/01/70 00:00 | |
if you can't explain | 01/01/70 00:00 |