flat assembler
Message board for the users of flat assembler.

Index > Main > Learning Assembly?

Author
Thread Post new topic Reply to topic
ryan_leaf



Joined: 30 Jun 2008
Posts: 2
Location: Massachusetts, United States
ryan_leaf 30 Jun 2008, 01:31
I am currently new to programing, while I have dabbled very little in other languages, I am a complete novice in programming. I discovered a good seeming book, called Art of Assembly, and started reading it online. However, then I looked on Amazon at the print-edition of the book, and many of the reviewers said it was too proprietary in it's teachings. It teaches a language called "High-Level Assembly" which is the brain-child of the author.

So, I am wondering what resource would teach most of what the Art of Assembly teaches, without teaching the proprietary language of High Level Assembly? I want to learn proper techniques; the correct programming knowledge to even to hardware level programming (i.e. embedded devices; programming EPROMS; hardware drivers (i.e. video card, sound card, NIC card); and I also want to learn enough about programming, that it will be a relatively simple transition to a higher level language such as C.

If it is necessary, I will clarify my postings.

Thank You,
Ryan Leaf

Art of Assembly: http://maven.smith.edu/~thiebaut/ArtOfAssembly/artofasm.html
Post 30 Jun 2008, 01:31
View user's profile Send private message Reply with quote
ManOfSteel



Joined: 02 Feb 2005
Posts: 1154
ManOfSteel 30 Jun 2008, 08:36
C and ASM are VERY different and you may never even need inline ASM in C (maybe only in low-level hardware programming) so why bother learning ASM in the first place if you already want to switch to C?

Anyway, the first things you should get are the Intel manuals and more precisely "Software Developer's Manual Volume 1: Basic Architecture", "Software Developer's Manual Volume 2A: Instruction Set Reference, A-M" and "Software Developer's Manual Volume 2B: Instruction Set Reference, N-Z". Keep those nearby.
http://developer.intel.com/products/processor/manuals/index.htm

Basic ASM:
http://drpaulcarter.com/pcasm/index.php
http://burks.bton.ac.uk/burks/language/asm/asmtut/asm1.htm

How to use FASM:
http://flatassembler.net/docs.php

And don't miss Iczelion's Win32ASM tutorials:
http://win32assembly.online.fr/tutorials.html
Post 30 Jun 2008, 08:36
View user's profile Send private message Reply with quote
ryan_leaf



Joined: 30 Jun 2008
Posts: 2
Location: Massachusetts, United States
ryan_leaf 30 Jun 2008, 12:55
Why would I want to learn ASM if I am already planning on going to C? Simple. I want to do Macintosh coding, therefore I cannot use Assembly. But, I also want to write drivers or program EPROMS using Windows or Linux, which I cannot do easily in C. Also, at some point I want to contribute to operating system developement, be it kernel-level or desktop-level; I need to have the skills and knowledge of Assembly to be effective.

I also cannnot code multi-core applications with any ease using C, due to the apparant lack of libraries for multi-core developement.

Would I pick up bad habits learning the author of the Art of Assembly's language (the one he uses in his book), and then later pick up regular x86 assembly language.
Post 30 Jun 2008, 12:55
View user's profile Send private message Reply with quote
bitRAKE



Joined: 21 Jul 2003
Posts: 4071
Location: vpcmpistri
bitRAKE 30 Jun 2008, 14:14
The initial reason Randy Hyde developed High Level Assembler (HLA) was to provide familiar syntax to high-level language programmers (C, C++) while introducing the concepts of x86. x86 has been around a long time and several syntax variations exist: Intel, AT&T, HLA, etc. Most assemblers use Intel syntax, but knowing x86 would make transferring to another syntax fairly easy.

Personally, I don't like HLA. Yet, in this instance it seems a proper fit.

_________________
¯\(°_o)/¯ “languages are not safe - uses can be” Bjarne Stroustrup
Post 30 Jun 2008, 14:14
View user's profile Send private message Visit poster's website Reply with quote
ManOfSteel



Joined: 02 Feb 2005
Posts: 1154
ManOfSteel 30 Jun 2008, 14:45
Quote:
I want to do Macintosh coding, therefore I cannot use Assembly.

Aren't x86 assemblers compatible with the new "Mac-Intel"? What about older 68K ASM (ex. EASy68K)?

Quote:
I also want to write drivers or program EPROMS using Windows or Linux, which I cannot do easily in C.

It can, and is most of the time done in C which uses ASM in/out instructions for its low-level I/O. Virtually every driver or other kernel-mode code on the market is written in C & co. In ASM, you'll have to modify all your OS-specific code (ex. Win32 API vs. int 0x80). This may not be easy to maintain, while you may port C code without much modification.

Quote:
Also, at some point I want to contribute to operating system developement, be it kernel-level or desktop-level; I need to have the skills and knowledge of Assembly to be effective.

Again, almost every "professional" OS out there is written in C with some parts written in HLL. Only a few hobby OS are written totally or in large part in ASM. The only places you'll need ASM in OSDEV is the bootloader (512 bytes) if you're not using someone else's and maybe the GDT or the IDT (?).

Quote:
Would I pick up bad habits learning the author of the Art of Assembly's language (the one he uses in his book), and then later pick up regular x86 assembly language.

All assemblers have different pseudo-instruction sets too. But with the links I provided above, you'll be able to read all Intel syntax ASM, learn Win32 programming and understand the way FASM works.
Post 30 Jun 2008, 14:45
View user's profile Send private message Reply with quote
avi



Joined: 24 Jun 2008
Posts: 23
Location: usa
avi 30 Jun 2008, 18:11
ryan_leaf wrote:

I want to learn proper techniques; the correct programming knowledge to even to hardware level programming
here is Jeff Duntemann's book(free download)you get what you pay for--
This one costs about 40 dollars and is not specific to UNIX (~~~==MacOS)
better choice: Unix based and free download
Barry Brey's book for low level hardware components, also about 40 dollars
only ten dollars, best book out there, but not UNIX basedMAC OS is a UNIX derivative
Blum's book, Linux, but costs 40 dollars, uses GAS, not very helpful in my opinionagain, GAS compatible (GNU AS) important for UNIX/C programming, but not for x86.---cpu in Mac OS.
I prefer FASM or NASM/YASM, rather than GAS. Since you have indicated naivete about programming, you have no need for HLA, which is designed to help those who are ALREADY experts in programming with C, but who know nothing about Assembly language programming. You are starting, correctly in my opinion, with Assembly language, not C, therefore, HLA is UNNECESSARY. Very smart. Excellent. Stick with it! You don't need HLA.
http://asm.sourceforge.net/resources.html
Smile

_________________
It is better to keep your mouth shut and appear stupid than to open it and remove all doubt.--Mark Twain
Post 30 Jun 2008, 18:11
View user's profile Send private message Reply with quote
Picnic



Joined: 05 May 2007
Posts: 1403
Location: Piraeus, Greece
Picnic 18 Dec 2008, 12:46
Plenty of resources links also here:
http://www.cheapersunglasses.com/asm.html

_________________
Hobby BASIC Interpreter
Post 18 Dec 2008, 12:46
View user's profile Send private message Visit poster's website Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20445
Location: In your JS exploiting you and your system
revolution 18 Dec 2008, 13:02
thimis wrote:
Plenty of resources links also here:
http://www.cheapersunglasses.com/asm.html
Yes, indeed, a nice looking page of links there.

But the domain name is kind of weird Confused I'm trying to imagine how sunglasses comes into the mix?
Post 18 Dec 2008, 13:02
View user's profile Send private message Visit poster's website Reply with quote
Mac2004



Joined: 15 Dec 2003
Posts: 314
Mac2004 18 Dec 2008, 17:12
@ryan_leaf: There's also a 'DOS version' available from the Art of assembly.
It doesn't handle HLA stuff at all and therefore it is a good assembly book.

regards,
Mac2004
Post 18 Dec 2008, 17:12
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.