Searching \ for '[PIC] PIC16F1827 EE declaration in code.' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: techref.massmind.org/techref/microchip/devices.htm?key=16F
Search entire site for: 'PIC16F1827 EE declaration in code.'.

Exact match. Not showing close matches.
PICList Thread
'[PIC] PIC16F1827 EE declaration in code.'
2011\09\28@161600 by Steve Smith

flavicon
face

This is a silly thing I have run out of ideas on....

Th define EE contents in code I have always used the following

org 0x2100                                ; address 0 of ee
dt        0f0h,0fh,b'01010101'        ; F0,0F,55... ect

For some reason on this chip when using abs code it fails with this error:-

Error - section '.org_3' can not fit the absolute section. Section '.org_3'
start=0x00002100, length=0x00000002


>From the help I know that the base address is right and it doesn't fail
until the dt is line is compiled. I have used the same code for years on
'877 ect and these don't fail.

Thanks

Steve

2011\09\28@165440 by Djula Djarmati

flavicon
On 28-Sep-11 22:12, Steve Smith wrote:
>
> This is a silly thing I have run out of ideas on....
>
> Th define EE contents in code I have always used the following
>
> org 0x2100                                ; address 0 of ee
> dt        0f0h,0fh,b'01010101'        ; F0,0F,55... ect
>
> For some reason on this chip when using abs code it fails with this error:-
>
> Error - section '.org_3' can not fit the absolute section. Section '.org_3'
> start=0x00002100, length=0x00000002


From MPASM Assembler Help:

EEPROM Start Address by Device
Most PIC1X MCUs: 0x2100
PIC18 MCUs:      0xF00000
PIC16F19XX MCUs: 0xF000

Try 0xf000.

Djula


>
>
>> From the help I know that the base address is right and it doesn't fail
> until the dt is line is compiled. I have used the same code for years on
> '877 ect and these don't fail.
>
> Thanks
>
> Steve

2011\09\28@170441 by Steve Smith

flavicon
face
Thanks

       org                0f000h
       dt                b'00001111'

Works... on a 16F18xx its not an F19xx so there is a little inconsistency
there...
This isn't what the help file on MPlab says...


Thanks
Steve

{Original Message removed}

2011\09\28@183636 by IVP

face picon face
> Try 0xf000

I don't know why (or maybe I do) more address information
isn't in the .INC file or the datasheet, specifically EEPROM,
when every last bit of everything else is mentioned

You can add your own definitions to 16F1627.INC, maybe
something like

EE_START   EQU   H'F000

2011\09\28@204706 by Djula Djarmati

flavicon
On 29-Sep-11 00:36, IVP wrote:
>> Try 0xf000
>
> I don't know why (or maybe I do) more address information
> isn't in the .INC file or the datasheet, specifically EEPROM,
> when every last bit of everything else is mentioned
>
> You can add your own definitions to 16F1627.INC, maybe
> something like
>
> EE_START   EQU   H'F000'

The address information is in the linker script file 16f1827_g.lkr:
CODEPAGE NAME=eedata START=0xF000 END=0xF0FF PROTECTED

Djul

2011\09\28@211751 by IVP

face picon face
> The address information is in the linker script file 16f1827_g.lkr:
> CODEPAGE NAME=eedata START=0xF000 END=0xF0FF
> PROTECTED

Quite true. I'd like it to be in more likely-to-be-read places too,
like the datasheet. Defining an address in the .inc file which can
be used with an .org is useful

Jo

2011\09\28@220305 by Bob Ammerman

flavicon
face
I'm pretty sure its really all the new PIC16F1xxx chips because they can have much more program memory than the PIC16Fxxx chips.

-- Bob Ammerman
RAm Systems

----- Original Message ----- From: "Steve Smith" <spam_OUTxygaxTakeThisOuTspamblueyonder.co.uk>
To: "'Microcontroller discussion list - Public.'" <.....piclistKILLspamspam@spam@mit.edu>
Sent: Wednesday, September 28, 2011 5:01 PM
Subject: RE: [PIC] PIC16F1827 EE declaration in code.


{Quote hidden}

> {Original Message removed}

2011\09\28@220539 by Bob Ammerman

flavicon
face
Olin would tell you to get away from absolute mode and use the linker. For most programs that makes good sense.

-- Bob Ammerman
RAm Systems

{Original Message removed}

2011\09\29@043821 by alan.b.pearce

face picon face
> Olin would tell you to get away from absolute mode and use the linker. For
> most programs that makes good sense.

That was my reaction too. Allocating space using linker names gets around a lot of this.


-- Scanned by iCritical.

More... (looser matching)
- Last day of these posts
- In 2011 , 2012 only
- Today
- New search...