cyberproxy Posted May 9, 2013 Posted May 9, 2013 I'm learning machine code. My questions are: 1) What is an accumulator? 2) What does the following statement mean, in simpler form? "The machine instruction to add 1 to the value in accumulator A is 01001100."
krash661 Posted May 9, 2013 Posted May 9, 2013 (edited) there's a lot to type, these links should help, i skimmed through them, everything you need is there, Machine code http://en.wikipedia.org/wiki/Machine_code Accumulator (computing) http://en.wikipedia.org/wiki/Accumulator_(computing) Edited May 9, 2013 by krash661
EdEarl Posted May 11, 2013 Posted May 11, 2013 (edited) A calculator shows its results in its accumulator, and its machine language is the buttons on the calculator. A calculator that can be programmed converts each key into a code that it stores in memory, for example the 1 key may be stored as an ASCII character 1, 2 as ASCII 2, + as an ASCII +, etc. (Refer to http://en.wikipedia.org/wiki/ASCII). In other words, each key press generates a number (e.g., ASCII) that is stored in memory to represent the key press. The numbers may or may not be ASCII, in general computers do no use ASCII, and their machine languages are much more complex than a calculator. Moreover, many machine languages are obtuse and difficult to learn. The ones for modern microprocessors are not only difficult to learn, they are nearly impossible to use to produce very efficient code. Languages such as C produce better code than almost any programmer, and they are much easier to use. Learning assembly language gives great insight into the inner workings of a computer, but I recommend you learn a simple one such as the 8080, Z80 or 6800. I learned on real machines about 25 years ago, so I have not use any of the emulators you can find when you google "Emulator 8080," "Emulator Z80," or "Emulator 6800." You may need to try a few to find one you like. Add 1 to the value in accumulator A is 01001100 means 01001100+1. You should be able to do the arithmetic. Good luck. Edited May 11, 2013 by EdEarl
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now