I want to write the code in machine code(binary)then convert it to gates, then to assembly.

How can I start?

To start, you need to find the op codes for the microprocessor instructions you intend to use. Typically these op codes will be given in hex. Then use Microsoft debug to enter the op codes. Debug comes with all versions of Windows, at least up through XP. If you don't have it, it can be downloaded from MSDN. As for going from machine code (hex/binary) to gates...hmm...not sure what you mean by convert to gates (Bill?). Anyway, the next step up from machine code IS assembly language; there is nothing inbetween. Debug can be used to assemble and disassemble code. To go from machine code (binary) to assembly neumonics, use Debug to disassemble the binary. I do not remember all the commands for Debug, but if you google it, I am sure they are out here on the Internet. At the risk of sounding flip, if you are not understanding things like hex to binary/binary to hex, op codes, and the other low-level terms used here, then you need to lay in some ground work first. There are many good books on doing assembly language programming, and typically these books will explain enough of the basics to get you up and running in just a chapter or two. I suggest Richard Detmer's book - Introduction to 80x86 Assembly Language and Computer Architecture. Check Amazon for good prices on used copies. Of course there are many, many free sources right here on the Internet; it's a good way to practice your googling skills.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.