[<<] [<] Page 1 of 1 [>] [>>] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Address of Configuration Word
From: Greg Reynolds ####@####.#### Date: 9 Aug 2004 22:23:20 +0100 Message-Id: <4117DC3D.5090309@bham.ac.uk> Hi, I'm writing a programmer for my hardware. I assemble the attached code with just "gpasm". When it writes the hex file, the address for the config word is written as "0x400E", not "0x2007" as I would expect. Is there something I'm doing wrong? Or is this what would be expected. gpasm-0.12.3.beta / Slackware 10 / Intel SMP. Thanks, Greg. ------------------------------------------------------------------- #include "p16f877a.inc" ;; PIC 16F877A, crystal oscillator, code-protect, no wdt __CONFIG (_WDT_OFF & _XT_OSC & _CP_OFF) LIST P=PIC16F877A #define BANK0 bcf STATUS, RP0 #define BANK1 bsf STATUS, RP0 org 0x00 start BANK1 clrf TRISB BANK0 movlw 0xF0 movwf PORTB finish: goto finish end | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: Address of Configuration Word
From: "acemailone" ####@####.#### Date: 9 Aug 2004 23:46:44 +0100 Message-Id: <000c01c47e62$e0901410$6502a8c0@P4SDX> 0x400E is OK. Hex file has byte addresses. In the PIC spec 0x2007 is the word address. Adrian ----- Original Message ----- From: "Greg Reynolds" ####@####.#### To: ####@####.#### Sent: Monday, August 09, 2004 4:19 PM Subject: Address of Configuration Word > Hi, > > I'm writing a programmer for my hardware. > > I assemble the attached code with just "gpasm". > > When it writes the hex file, the address for the config word is written > as "0x400E", not "0x2007" as I would expect. > > Is there something I'm doing wrong? Or is this what would be expected. > > gpasm-0.12.3.beta / Slackware 10 / Intel SMP. > > Thanks, > > Greg. > > ------------------------------------------------------------------- > #include "p16f877a.inc" > > ;; PIC 16F877A, crystal oscillator, code-protect, no wdt > __CONFIG (_WDT_OFF & _XT_OSC & _CP_OFF) > > LIST P=PIC16F877A > > #define BANK0 bcf STATUS, RP0 > #define BANK1 bsf STATUS, RP0 > > org 0x00 > start BANK1 > clrf TRISB > BANK0 > movlw 0xF0 > movwf PORTB > finish: goto finish > > end > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: ####@####.#### > For additional commands, e-mail: ####@####.#### > > | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
[<<] [<] Page 1 of 1 [>] [>>] |