News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

NASM uppercase conversion program issue

Started by silvercats, June 05, 2014, 07:39:22 PM

Previous topic - Next topic

Gunther

Hi silvercats,

it was a misunderstanding. I don't have the book by Jeff Duntemann. I have confused it with the book by James Leiterman. Apologies, but I was with my students on the road and therefore some days not at home. I therefore had no access to my big computer and only the laptop with me.

I've finished for you an example for assembling with NASM or YASM (version number is not critical). I've linked it wit gcc, because that saves a lot of trouble. It's inside the archive hello.zip, wich contains hello.tar.gz. The source is well commented and the program should run with any Linux distribution and under BSD.

By the way, I don't know if Duntemann's book is good, but for learning purposes is Dr. Carter's book an excellent choice. It's free, available in different translations via net, covers Windows and Linux and the examples are working well.

In the meantime, I'll take a look at your code and see what I can do for you.

Gunther
You have to know the facts before you can distort them.

silvercats

Quote from: habran on June 06, 2014, 02:29:07 PM
Quote'a’ 'z’ Let’s
:dazzled:
don't you find it strange in your code ::)

your compiler probably don't understand Martian language  :greensml: 

try NASA instead of NASM :bgrin:

A funny guy, aren't you?

The unreadable strange chars you see on the Source code that is posted here, are not REALLY on the original source file(.asm file) in the local computer. Don't know how it happened here. (but command line output's strange chars were  there, on the original Terminal.)


silvercats

Found the problem thanks to Gunter!  Thanks a lot for other people too.

Here is what happened. I use Geany for editing the source codes(a powerful tool for editing text and a lot more features and functions are there) . It has a button called "compile".  When i went to check the linker commands as Gunter wanted me to recheck them, i realized that i actually used the button on the Geany to compile the code. So no commands were used.  The program worked fine after using the proper stuff.  Thanks!!
.

silvercats

Thanks.  I will take a look at James Leiterman's book too

habran

hey silvercats :biggrin:
I CONFESS that I poses a certain amount of humor (and that is I suppose a crime these days)  but you have to confess that I was right:
you gave to NASM source that it can't read (garbage) and that's what I was trying to point out to
you ;)
Cod-Father

silvercats

Quote from: habran on June 08, 2014, 11:09:32 PM
hey silvercats :biggrin:
I CONFESS that I poses a certain amount of humor (and that is I suppose a crime these days)  but you have to confess that I was right:
you gave to NASM source that it can't read (garbage) and that's what I was trying to point out to
you ;)

did I tell you that you were funny? (hmm...is there a word called 'irony' in English).


1. It wasn't the NASM that I gave the source to exactly.
2.  If you read my post correctly, you would  read that there were no "garbage" in the actual source code for real.

We do appreciate real opinions and replies rather than wrong humor here.

Thank you

habran

Quotethis is the error I get when running the code (NASM is the assembler ). Thanks.

cat@cat-laptop:~/Desktop$ sudo ./uppercase2 >toUpper.txt <fromLow.txt
./uppercase2: 1: �f�f�f�tf�̀f��f=t?f��f�tfMg�: not found./uppercase2: 1:
arg�: not found
: not found2: 1:
Cod-Father

silvercats

Quote from: habran on June 09, 2014, 12:17:43 AM
Quotethis is the error I get when running the code (NASM is the assembler ). Thanks.

cat@cat-laptop:~/Desktop$ sudo ./uppercase2 >toUpper.txt <fromLow.txt
./uppercase2: 1: �f�f�f�tf�̀f��f=t?f��f�tfMg�: not found./uppercase2: 1:
arg�: not found
: not found2: 1:

the terminal output text yes....

Gunther

#23
Hi silvercats,

fine to hear that things work well. A few remarks:


  • I would use local labels with NASM. These are starting with a dot.
  • Give Dr. Paul Carter a try. The Leiterman book won't help you much.

And always remember: The funny guys are Windows coders. Do they really know what a terminal output is?  (With irony tags, in case anyone is in doubt. :lol: :lol: :lol:)

Gunther
You have to know the facts before you can distort them.

silvercats

Alright! Thanks for the help.It is really appreciated.......

Gunther

Quote from: silvercats on June 09, 2014, 11:10:34 PM
Alright! Thanks for the help.It is really appreciated.......

You're welcome.

Gunther
You have to know the facts before you can distort them.