Internal memory LPC1768

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Internal memory LPC1768

966 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by kevin on Wed May 29 07:57:23 MST 2013
The LPC1768 has internal memory to record data?

The LPC1768 has the possibility during the execution of the program I put a value in the variable and when reset the program the variable remain  with this value?
0 Kudos
Reply
4 Replies

804 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by kevin on Wed May 29 12:41:34 MST 2013
someone has some example code of how to make a variable does not lose its value even when you turn off the circuit?
0 Kudos
Reply

804 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by R2D2 on Wed May 29 08:43:33 MST 2013

Quote: Rob65
... the last one is a bit more tricky; you will need to bypass the generated linked scripts from the LPCXpresso tools and check the Gnu documentation to understand how linker files work and dive a bit in the startup code.



:confused:

Not if you use an actual LPCXpresso version.
0 Kudos
Reply

804 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Rob65 on Wed May 29 08:33:03 MST 2013
Yes - in different ways.

There are some scratchpad registers in the RTC, these even allow you to keep some data valid while the power is removed (you do need a backup battery).

You can also write some data into the flash memory, this is then always available after a power on or a reset.

You can change the memory regions and the startup code to have some part of the RAM not being cleared when the startup code runs - in that case global variables in this region will keep the value that is in memory.
Note that this also means that on an initial startup you must make sure there are sensible values in here.

The first two solutions are described in the LPC17xx user manual, the last one is a bit more tricky; you will need to bypass the generated linked scripts from the LPCXpresso tools and check the Gnu documentation to understand how linker files work and dive a bit in the startup code.

Rob
0 Kudos
Reply

804 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by R2D2 on Wed May 29 08:24:10 MST 2013

Quote: kevin
The LPC1768 has the possibility during the execution of the program I put a value in the variable and when reset the program the variable remain  with this value?



See: http://knowledgebase.nxp.com/showthread.php?t=4166
0 Kudos
Reply