View previous topic :: View next topic |
Author |
Message |
mrsmith Guest
|
write_program_memory compiles to... nothing? |
Posted: Thu Nov 02, 2006 5:08 pm |
|
|
While fighting to figure out while my write_program_memory wasn't working, I took a look at the listing, and low and behold, it doesn't appear to be compiling to anything! Check it out below...
Am I missing something obvious? This is a 18F4620 and 3.212 of the compiler.
Code: |
C328: MOVWF xDD
C32A: MOVLB 0
C32C: CALL B34A
....................
.................... write_program_memory(0x0200, data, 8);
....................
.................... packet[UDP_data+2] = 'A'; //change NRR to NRA!
C330: MOVLW 41
C332: MOVWF 49
.................... read_program_memory(memaddr, packet+47, 64);
C334: MOVFF 1CA,FF8
C338: MOVFF 1C9,FF7
C33C: MOVFF 1C8,FF6
C340: CLRF FEA
C342: MOVLW 4C |
|
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Thu Nov 02, 2006 5:22 pm |
|
|
Here are two possibilities:
1. Maybe they didn't add support for it until vs. 3.215. See the
version history below.
Quote: |
3.213 Updates for the newest chips
3.213 An internal error with some shift operations involving int32's is fixed
3.214 An underserved syntax error in #IF is fixed
3.214 A bug in set_tris_x() in PIC18 in fast_io mode is fixed
3.214 Some problem with the header files for new chips are fixed
3.214 A PIC18 optimization bug is fixed
3.215 A problem with %u during printf redirection is fixed
3.215 The SSP pins are corrected for non-standard chips
3.215 PCW now recognizes MPLAB 7.0
3.215 Flash programming algorithms updated for the newest chips, see readme.txt
3.215 New function WRITE_CONFIGURATION_MEMORY has been added
3.215 Some baud rate issues with parts that have a EUART are fixed
3.215 #USE I2C now allows the speed to be set in BPS using FAST=xxxxxxx
|
2. It's possible that support for writing to Flash memory is not
enabled in the Device data. I don't have PCWH, so I can't check
this for you. (I only have the command line compilers).
But if if you have PCWH, edit the 18F4620 data, and look for some
setting that allows writing to Flash memory. See if it's enabled.
http://www.ccsinfo.com/images/content/device_editor.gif |
|
|
mrsmith Guest
|
Weird |
Posted: Thu Nov 02, 2006 6:56 pm |
|
|
Kinda weird, since write_program_eeprom does seem to work fine... |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
|
mrsmith Guest
|
Ahh... |
Posted: Thu Nov 02, 2006 8:57 pm |
|
|
Thanks. I actually did a search before I posted, but I didn't see that thread. Just changed it to write_program_eeprom and everything is fine... |
|
|
|