I am writing to ask if anyone knows how to hand assemble a simple
68HC11 program? My problem is getting the op code. I am using the standard instruction set. I know that you have to count the number of CPU cycles for each instruction.
Does anybody know of a good tutorial on this?
Thanks, Mickey
Didn't find your answer? Ask the community — no account required.
L
Leon Heller
You need to know the number of bytes for each instruction, not the number of clock cycles, so that you can write down the address of each instruction. Why not use an assembler, it's much easier?
Leon
S
Spehro Pefhany
Read this:
formatting link
Best regards, Spehro Pefhany
"it's the network..." "The Journey is the reward"
speff@interlog.com Info for manufacturers: http://www.trexon.com
Embedded software/hardware/analog Info for designers: http://www.speff.com
P
Paul E. Bennett
I have always found the Leventhal books very good on such topics. However, if you already have the instruction set to hand (in the datasheets for the processor) you just need to take note of how many bytes each instruction occupies so that you can calculate the next instruction addresses. Be sure to count the negative direction properly too (when doing jumps back to the start of a loop).
********************************************************************
Paul E. Bennett ....................
Forth based HIDECS Consultancy .....
Mob: +44 (0)7811-639972
Tel: +44 (0)1235-811095
Going Forth Safely ....EBA. http://www.electric-boat-association.org.uk/********************************************************************
P
peter
Hi, try this for assembly and testing (free HC11 simulator):
formatting link
Regards Peter
Join the Discussion
Have something to add? Share your thoughts — no account required.
Didn't find your answer?
Ask the community — no account required
Report Content
You are reporting this content to the moderators. They will look at it
ASAP.