Practice
Short, checked exercises. You write 8085 assembly in the full simulator, press Check, and get told exactly which case failed and why, then step through that case in the debugger.
- beginner 2 steps
Add Two 8-bit Numbers
Read two bytes from memory, add them, and store the result. The smallest complete program that touches memory, registers and flags.
#arithmetic#memory#flags - beginner 2 steps
Subtract Two 8-bit Numbers
Subtract one byte from another, learn why the carry flag doubles as a borrow, and meet the other way of reaching memory.
#arithmetic#memory#flags - beginner 2 steps
Swap Two Bytes in Memory
Exchange the contents of two memory locations, and discover why you always need a third place to put something down.
#memory#pointers#registers - intermediate Plus 2 steps
Sum an Array of Bytes
Walk a block of memory with a counter and accumulate a total. This is the loop every array algorithm is built from.
#arrays#loops#counters#flags - intermediate Plus 2 steps
Copy a Block of Memory
Move N bytes from one place to another with two pointers, then find out why the same loop destroys the data when the two blocks overlap.
#memory#pointers#loops#arrays - intermediate Plus 3 steps
Largest Number in an Array
Compare bytes without destroying them, and carry a running best through a loop. The pattern behind searching, sorting and every minimum or maximum.
#arrays#loops#comparison#flags - intermediate Plus 2 steps
Count the 1 Bits in a Byte
Rotate a byte through the carry flag one bit at a time and tally the ones. The first program that looks inside a byte instead of at it.
#bits#rotate#loops#flags - intermediate Plus 2 steps
Add Two 16-bit Numbers
Add numbers that do not fit in a register, first a byte at a time with the carry chain, then in one instruction with a register pair.
#arithmetic#16-bit#register-pairs#flags - intermediate Plus 3 steps
Multiply Two 8-bit Numbers
The 8085 has no multiply instruction, so build one out of a counted loop, then widen it to a 16-bit product with a register pair.
#arithmetic#loops#16-bit#counters - intermediate Plus 4 steps
Sort an Array in Ascending Order
Bubble sort, built one pass at a time. A loop inside a loop, a swap inside a comparison, and the first program with real structure.
#arrays#sorting#loops#comparison