News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Updated MASM Reference and Programmer's Guide

Started by 00100b, December 21, 2004, 07:26:52 PM

Previous topic - Next topic

00100b

I've downloaded and have been reading the Microsoft Assember Programmer's Guide and Reference for version 6.1, but as many of you may know, it is kinda out-dated.

Is there an updated version somewhere that presents the information that they contained in a similar fashion and weeds out the 16-bit stuff (ie, Segments and Real-Mode).

For now, I am cross-referencing those documents with the MASM32 help files (and a few other documents) to try and determine which information is pertinent.  It's a slow-go, but I'm a somewhat patient martian.

Vortex

Hi Forby,

I am afraid MS didn't release any new version of the Assember Programmer's Guide and Reference.

00100b


John

Hi 4b,
A few months ago I was lucky enough to score a shrink copy of MASM 6.1 from eBay. I was suprised at how large and heavy the box turned out to be once it arrived, considering the entire install only took up ~8.5MB and there were only 5 floppys (floppies?). To my delight I found inside the box a copy of the manuals you speak of. They have been a great help to me to! Also inside the box was a book to teach you ASM using MASM 6.1 from the very beginning. It's called "Assembler Inside & Out" and was written by Harley Hahn published by Osborne or McGraw Hill. If you can find it I think you would agree that it is a very good resource. (It uses 16bit programming)

I'm not sure you should skip right to 32 bit ASM programming though. Especially considering you don't want to use all the prewritten things that come with a package such as MASM32. 16 bit programming is different, but you can pretty much ignore the discussions of segments (the biggest difference) in 16 bit real mode and still get an understanding of the Assembly language, memory, and the processor. 32 bit Windows programs require a large amount of boiler plate code and I think it would be better to learn the assembler for you than to learn Windows. Once you feel sufficently comfortable with 16 bit .com or .exe programs which have very little boiler plate code then you can make the leap to Windows and 32 bit flat model.

I'd also highly reccomend the book called "Code" by Charles Petzold. It will take you from the 1800's to pretty much modern day computers. It teaches you how to build a computer of your own, from relays to transistors, and design your own ASM instructions. It is very, very, good if you want to really go lower.

Good Luck,
John

00100b

Hi John,

Thanks for the info.  Since it's too late to tell Santa about the two books, a hunting I will go.

I can see your point concerning learning 16-bit assembler, and I did spend some time the other evening considering it.  My conclusion (and these may be conclusions made from ignorance) was that I couldn't see myself writing anything for a 16-bit, unprotected platforms at any time in the future.  Even the PLCs and SLCs that I deal with at work is using ladder-diagram programming, and using RSLogix of one flavor or another.  So for a historical/background-reference point of view, yes, I am at least reading those sections of documentation concerning the 16-bit assembler (M510 compatible).  Honestly though, it is more to try and differentiate between what is needed and/or is still applicable to 32-bit assembler.

Do you think that my conclusions are incorrect?  Should I focus more attention on 16-bit assembler, or can I still learn as much about the low-level concepts focusing on 32-bit assembler?

I'd appreciate any opinions on this.

Thanks

John

#5
You can learn every bit as much either way you go. What I'm trying to do is suggest it as another option to getting your feet wet with Assembly language, and asking you not to brush it off as useless too quickly.

I doubt very much that I will ever use the code I've written for 16 bit ASM (not 510 compatible either mind you!) in an actual 32bit program, but the learning that I did while writing it is indespensible. All the fluff is gone down there (in 16bit mode). I learned so much about the architecture of a computer and registers and was forced to place values on the stack for lack of any other place to stick them. Registers are twice the size in 32bit mode! In 16bit mode you need ml, the 16 bit linker, and their required files, that's it. There is almost no boiler plate code and it is very easy to get started once you get a good book or reference. Your debugger is even built into windows!

Anyhow, I really don't want to be a preacher (sp), and others here may completely disagree with me.

I found that the most difficult part of getting in to learning Assembly is precisely the part you are at right now. Figuring out where to start, what I need to start, and where to get material to learn from. What do I need, and what is a luxury? It's hard to know really unitl you already know. Kinda like bootstrapping, pull harder and you'll get off the ground eventually :p

00100b

As always, thanks for your honest input John.  I will spend some time looking at the 16-bit threads of the recently restored archive of this site and dig into this further.

Are there any issues with writing and running 16-bit code under either a Win2K or WinXP OS?

John

You are very welcome!

I can still run and assemble all my 16 bit code from a previous ASM class in college with no problem on both 2k and XP.

donkey

I think that the last version of the Programmers Guide that was released is 6.1 (of which I have an original set of manuals). It would be a good project for the MASM users to write an updated guide to using MASM as there are more and more new users and much of the info in the 6.1 guide is no longer pertinent. I think someone should start a MASM reference project that closely follows the originals aimed at developping a manual for beginners.
"Ahhh, what an awful dream. Ones and zeroes everywhere...[shudder] and I thought I saw a two." -- Bender
"It was just a dream, Bender. There's no such thing as two". -- Fry
-- Futurama

Donkey's Stable

John

donkey,
I think that is a great idea!

I'm still very much a newbie in all of this but I would definately be willing to help in any way I can if we could pull in a few people with a good knowledge of MASM.

MichaelW

I think it would be best to avoid following the originals too closely. From the MASM 6.0 Programmer's Guide:
QuoteThe Programmer's Guide is written for experienced programmers who know assembly language and are familiar with an assembler. The book does not teach the basics of assembly language; it does explain Microsoft-specific features. If you want to learn or review the basics of assembly language, refer to "Books for Further Reading" later in this introduction.
eschew obfuscation

MANT


deadh

Quote from: 00100b on December 21, 2004, 07:26:52 PM
I've downloaded and have been reading the Microsoft Assember Programmer's Guide and Reference for version 6.1, but as many of you may know, it is kinda out-dated.

Is there an updated version somewhere that presents the information that they contained in a similar fashion and weeds out the 16-bit stuff (ie, Segments and Real-Mode).

For now, I am cross-referencing those documents with the MASM32 help files (and a few other documents) to try and determine which information is pertinent.  It's a slow-go, but I'm a somewhat patient martian.


00100b...........


If you can get the MASM 6.x package, do it!  The Programmer's Guide is worth its weight in gold.  Forget about any 16 bit stuff you come across in there.  32 bit coding is easier--I've been doing the 16 bit trick since the early 80's and the 8 bit stuff since '75.  Once you open the Guide, you'll see what I mean.  I recently bought a second MASM package on eBay just for the manuals.  I actually use MASM version 6.15 for programming.  Everything else you'll need is available in the MASM32 (ver 8.2) package, and the various sites that support it.

-deadh

00100b

Thanks for the input deadh.

If I run across a copy of the MASM 6x package, then I will probably get it.