Searching \ for ' [PIC] Hi-Tech C, 16F877 and EEPROM data' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/microchip/memory.htm?key=data
Search entire site for: 'Hi-Tech C, 16F877 and EEPROM data'.

No exact or substring matches. trying for part
PICList Thread
'[PICLIST] [PIC] Hi-Tech C, 16F877 and EEPROM data'
2000\11\13@152707 by Wynn Rostek

flavicon
face
I've been trying to mix some C code and some assembly language data.
The C code is a complete program that is working, the data is some configuration
information that varies with each customer. I'm using the Hi-Tech C compiler
with MPLAB 5.11.02. The processsor is the 16F877. The configuration data
is supposed to go in the 256 bytes of EEPROM.

I added the configuration file, cfg.as,  to the project and configured it as an assembly language file. When I build the project, I see the the line indicating
that it is processing the assembly language file, but nothing happens.

Compiling CFG.AS
Command line: "C:\HT-PIC\BIN\ASPIC.EXE -16F877 -C C:\PRS151\PIC\PRS2\CFG.AS"

Now when I type this line from a DOS window, the Hi-Tech assembler runs and generates
as cross-reference file and an object file. These files are not generated when you do a build project.

OK, now for the real kicker. Even if I leave the manually generated Cfg.obj in the project
directory when I do a make project, MPLAB says:

MPLAB is unable to find output file "CFG.OBJ"

Am I out of luck using the Hi-Tech C compiler with the 16F877 and putting configuration
data in the EEPROM? Or have I missed some critical installation step somewhere?

TIA

Wynn Rostek

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
"[PIC]:","[SX]:","[AVR]:"

2000\11\13@160317 by Clyde Stubbs

flavicon
face
On Mon, Nov 13, 2000 at 03:17:26PM -0500, Wynn Rostek wrote:
> I've been trying to mix some C code and some assembly language data.

Check that in Install Language Tool you have all three things
(compiler, assembler, linker) pointing to PICC.EXE.


--
Clyde Stubbs                     |            HI-TECH Software
Email: spam_OUTclydeTakeThisOuTspamhtsoft.com          |          Phone            Fax
WWW:   http://www.htsoft.com/    | USA: (408) 490 2885  (408) 490 2885
PGP:   finger .....clydeKILLspamspam@spam@htsoft.com   | AUS: +61 7 3355 8333 +61 7 3355 8334
---------------------------------------------------------------------------
HI-TECH C: compiling the real world.

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
"[PIC]:","[SX]:","[AVR]:" =uP ONLY! "[EE]:","[OT]:" =Other "[BUY]:","[AD]:" =Ads




2000\11\14@031208 by Michael Rigby-Jones

flavicon
face
I have been working on a project where we do exactly this, apart from our
config data is held in a .c file and the actual org statement and db
statements are between #asm and #endasm directives.  This works fine, the
only thing I couldn't get working was using dw to allocate a 16 bit word.

Regards

Mike

> {Original Message removed}

2000\11\14@091553 by Wynn Rostek

flavicon
face
Mike,

I had the assembler pointed to aspic. Once I fixed that, stuff seemed to
work except that only every other byte ended up in EEPROM.
Since the configuration data was being generated by a Visual C++ program it
took about 60 seconds to put in a bandaid to pad the file with
extra bytes so that all of the config bytes got saved to EEPROM, but it
bothers to have stuff like that in the code.  I also noticed that the data
that was in the file using DW, only the high order byte was stored in
EEPROM. was this the problem you ran into?

Wynn Rostek

{Original Message removed}

2000\11\14@092932 by Michael Rigby-Jones

flavicon
face
> ----- Original Message -----
> From: Michael Rigby-Jones <mrjonesspamKILLspamNORTELNETWORKS.COM>
> To: <.....PICLISTKILLspamspam.....MITVMA.MIT.EDU>
> Sent: Tuesday, November 14, 2000 3:04 AM
> Subject: Re: [PIC] Hi-Tech C, 16F877 and EEPROM data
>
>
> > I have been working on a project where we do exactly this, apart from
> our
> > config data is held in a .c file and the actual org statement and db
> > statements are between #asm and #endasm directives.  This works fine,
> the
> > only thing I couldn't get working was using dw to allocate a 16 bit
> word.
> >
> > Regards
> >
> > Mike
>
       {Original Message removed}

2000\11\15@212609 by Clyde Stubbs

flavicon
face
> Yes, that was exactly the problem.  I store a lot of calibration figures in
> eeprom, and most of them are 16 bit integers.  The DW was an obvious choice,

Not when you only have a 14 bit word to store it into!

> HiTech list, only my posts don't seem to get through any more.

Hmmm, you posted a message on 6th November ok.

Cheers, Clyde

--
Clyde Stubbs                     |            HI-TECH Software
Email: EraseMEclydespam_OUTspamTakeThisOuThtsoft.com          |          Phone            Fax
WWW:   http://www.htsoft.com/    | USA: (408) 490 2885  (408) 490 2885
PGP:   finger clydespamspam_OUThtsoft.com   | AUS: +61 7 3355 8333 +61 7 3355 8334
---------------------------------------------------------------------------
HI-TECH C: compiling the real world.

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.


2000\11\16@031305 by Michael Rigby-Jones

flavicon
face
> -----Original Message-----
> From: Clyde Stubbs [SMTP:@spam@clydeKILLspamspamHTSOFT.COM]
> Sent: Thursday, November 16, 2000 2:26 AM
> To:   KILLspamPICLISTKILLspamspamMITVMA.MIT.EDU
> Subject:      Re: [PIC] Hi-Tech C, 16F877 and EEPROM data
>
> > Yes, that was exactly the problem.  I store a lot of calibration figures
> in
> > eeprom, and most of them are 16 bit integers.  The DW was an obvious
> choice,
>
> Not when you only have a 14 bit word to store it into!
>
Ahh...I assumed (arrghh!!) that the dw would just use two adjacent
locations.  Obviously I'm as wrong as a very incorrect thing.  Is there any
other way to achieve this apart from splitting the integer up into two
bytes?

> > HiTech list, only my posts don't seem to get through any more.
>
> Hmmm, you posted a message on 6th November ok.
>
> Cheers, Clyde
>
I recently tried posting a message regarding an issue with the delay macro
in the samples directory (actually...possibly a pre-processor issue) but I
didn't receive my posting back as I usually do.

Mike

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email RemoveMElistservTakeThisOuTspammitvma.mit.edu with SET PICList DIGEST in the body


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