delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2008/03/11/12:31:48

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
X-Recipient: djgpp AT delorie DOT com
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=gamma;
h=domainkey-signature:received:received:message-id:date:from:sender:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth;
bh=K6PKrepQYdrxLbAeZ1s4G1ClvDEdxpCogEy+9+xUGvU=;
b=a3J96RKpZNZ0O9bO9N+hAac8QJiy+FGcXwmdV85l7tkxO2BkCRRPTjV/K2hngTpfKfqhVZ2FCgX5G/lN0vJ5mvBV5bhUZQL7676oFDxljJYsnGmwq/nxjWLVLI811tMbJpK/QS6Ts96Xrl6c6pV4hpbGPpOy3Q61qrwRWk6K4FY=
DomainKey-Signature: a=rsa-sha1; c=nofws;
d=gmail.com; s=gamma;
h=message-id:date:from:sender:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth;
b=DMbwLUxIfB1R/PMWkofUx/2bQ5I/ouiZNFYu2PEsr+Tdu1Y3eKyzOsoBo7c3g0Chxf2ogtqS52/FuYRKN3uadqbeOnRRStG0YYytTVUWR7UMNbIApMmSWg/KDlhViUg2uZ8PQ47BaubLJ0AD/p3eLEDmwEt42iML4FdTEFpR3vk=
Message-ID: <1a5a6bfe0803111031t39e14735v8637e7f048c6cd70@mail.gmail.com>
Date: Tue, 11 Mar 2008 13:31:23 -0400
From: "Daniel Verkamp" <daniel AT drv DOT nu>
Sender: daniel DOT verkamp AT gmail DOT com
To: djgpp AT delorie DOT com, kie AT gmx DOT de
Subject: Re: relocation truncated to fit: 16 against
In-Reply-To: <1ea8424e-da3e-4ecf-a0c6-4d836c62563e@d62g2000hsf.googlegroups.com>
MIME-Version: 1.0
References: <1ea8424e-da3e-4ecf-a0c6-4d836c62563e AT d62g2000hsf DOT googlegroups DOT com>
X-Google-Sender-Auth: 726ff7ed892e23a6
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Tue, Mar 11, 2008 at 1:11 PM, kie <kie AT gmx DOT de> wrote:
> Hi I'm triying to write my own Keyboard ISR, but I am having some
>  Trouble
>  with my ASM code to gat the scan_code from the PIC.

You should probably read up on GNU assembler first; Google should find
plenty of hits. Some good ones:
- http://www.delorie.com/djgpp/v2faq/faq17_1.html
- http://www.ibm.com/developerworks/library/l-ia.html

For example, 'movw $_raw_scan_code, %ax' is presumably meant to move
the value of ax into a 'raw_scan_code' variable, but remember that
AT&T syntax is generally 'source, destination', and the $ is not
needed here (you are getting the address of the variable there, then
trying to move it into a 16-bit register, which is the cause of the
error message), and you need to double the % signs when writing actual
register names in inline assembly, so it should presumably be more
like 'movw %%ax, _raw_scan_code'.  You could also use the input list
to avoid needing to mangle the name by hand.

-- Daniel Verkamp

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019