Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

More PIC space

Status
Not open for further replies.
Nigel Goodwin said:
I suggest you go off and read about PIC's before making silly suggestions - for that matter, read the previous posts in this thread!.

Or somthing like that? Thats what one of the mentors kinda said that has been programming for 40 years and has programmed everything from autonomous cars to the patriot missle!
 
Krumlink said:
Thats what one of the mentors kinda said that has been programming for 40 years and has programmed everything from autonomous cars to the patriot missle!

But not pics.

Mike.
 
whatever. I will ask how to add external EEPROMS and tell you on tuesday.
 
Krumlink said:
whatever. I will ask how to add external EEPROMS and tell you on tuesday.

Don't forget to tell him it's for a Harvard architecture PIC, NOT for a mico-processor - if he made any such comment he obviously doesn't know the slightest thing about PIC's.
 
hey thanks guys, I'll tell you hyow this goes, this is going to be one of my first PIC projects, but before I get to the full fledge thing I'll just kinda work my way up. So by the looks of it the MCU has a ton of memory, so it should be fine. As soon as I'm done I'll post it later, right now I'm waiting for a programmer from the mail to get started with.
 
Guyfrom7up said:
hey thanks guys, I'll tell you hyow this goes, this is going to be one of my first PIC projects, but before I get to the full fledge thing I'll just kinda work my way up. So by the looks of it the MCU has a ton of memory, so it should be fine. As soon as I'm done I'll post it later, right now I'm waiting for a programmer from the mail to get started with.

You might consider looking at the EPE magazine website, they have done similar projects, and the code can be downloaded.
 
Something else to consider depending on your application would be to use an SD card as an external memory source with various code on it and use the 18F self programming facility to read the data off the card and program itself up with the code from the SD card. The downside is that you "only" have up to 100k rewrites on the program memory.

I'm working on something that uses this system for some multi personality modules. While I can fit all the code into a 18F4550 for one application, variances in the program design and output to a graphics LCD (with lots of bitmaps) mean that using external memory like this gives me the ability to switch between module personalities without having to constantly read from the SD card every time.

I.e. if the customer wants the module operating in a certain mode with a certain graphics display the bootloader reprograms the PIC with the appropriate software which then stays memory resident until they change their mind. If they change their mind more than 100,000 times then there could be a problem but this is highly unlikely to happen :D
 
Well reprogramming is not just a matter of endurance.
Reprogramming is slow and slightly error-prone process. What's more, errors can have unpredictable consequences. For example, if the device were to lose power in the seconds it takes to reprogram (esp if the user throught something was wrong because nothing was happening) then you have a device with a bootloader but broken code.

It would make a LOT more sense that, if you have all this constant data, to store that data on the SD card and use the rest of the space for one large program!

Some PICs are bigger than others, some dsPICs have 128K of program space!
 
I think we need to put this in to perspective! :D

An 18F PIC can have 64K of program memory - this is a HUGE amount - more than multi-million selling personal computers used to have, and the efficient PIC architecture probably makes better use of it as well. Plus the 64K in a Von Neuman machine includes both RAM and ROM, the 64K in a Harvard machine is entirely ROM.

It's really down to inefficient programming, rather like Windows programing - just wasting resources rather than using more efficient programming methods.
 
Oznog said:
Well reprogramming is not just a matter of endurance.
Reprogramming is slow and slightly error-prone process. ...

The best option is to use a PIC with enough memory to start with.

If one needs to reprogram on the fly the bootloader could be modified to validate the newly flashed program and reflash it needed. That does not make it any faster but it does keep the system from becoming corrupted.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top