CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Search found 24 matches
CCS Forum Index
Author Message
  Topic: [PIC24HJ256GP210] IVT Spacing / Redirection
canadidan

Replies: 7
Views: 19695

PostForum: General CCS C Discussion   Posted: Wed Aug 14, 2019 2:57 pm   Subject: [PIC24HJ256GP210] IVT Spacing / Redirection
My ignorance will show here, but aren't fuses located outside of the "usable memory" range?

0x00000 - RESET (GOTO 0x26800)
0x00004 - IVT
0x00104 - AIVT
0x00400 - APP GOTO
0x00404 - AP ...
  Topic: [PIC24HJ256GP210] IVT Spacing / Redirection
canadidan

Replies: 7
Views: 19695

PostForum: General CCS C Discussion   Posted: Wed Aug 14, 2019 1:00 pm   Subject: [PIC24HJ256GP210] IVT Spacing / Redirection
Great example, thank you! Aside from the jump_to_isr() approach, the code I'm working with is similar, and uses ALTIVT for the bootloader and IVT for application.

However, I can clean up the organi ...
  Topic: [PIC24HJ256GP210] IVT Spacing / Redirection
canadidan

Replies: 7
Views: 19695

PostForum: General CCS C Discussion   Posted: Wed Aug 14, 2019 7:27 am   Subject: [PIC24HJ256GP210] IVT Spacing / Redirection
I think I found the answer! I have the whole byte address (hex file) and word address (flash memory) concepts clear in my head. What I didn't understand is why the PIC-C redirected IVT was different t ...
  Topic: [PIC24HJ256GP210] IVT Spacing / Redirection
canadidan

Replies: 7
Views: 19695

PostForum: General CCS C Discussion   Posted: Tue Aug 13, 2019 3:03 pm   Subject: [PIC24HJ256GP210] IVT Spacing / Redirection
Hello all, I'm hoping someone here can clarify this behaviour for me. It seems to be something compiler-specific that I can't find other reports of.

Note, this is inherited code, so when I call out ...
  Topic: [PIC24HJ256GP210] Increment operator issue with int32 array
canadidan

Replies: 3
Views: 10386

PostForum: General CCS C Discussion   Posted: Wed Jun 19, 2019 9:18 am   Subject: [PIC24HJ256GP210] Increment operator issue with int32 array
@dluu13 - great points. The +=1 notation more clearly shows intended behaviour, so I used that and it works correctly.

Count[ID] += 1; // This works

@Ttelmah - I had a feeling you would ...
  Topic: [PIC24HJ256GP210] Increment operator issue with int32 array
canadidan

Replies: 3
Views: 10386

PostForum: General CCS C Discussion   Posted: Wed Jun 19, 2019 7:11 am   Subject: [PIC24HJ256GP210] Increment operator issue with int32 array
Before I get started, this post is mostly to have a record on the internet for others with similar issues since I couldn't find anything else like it.

PIC-C Version 4.106 (very old)

Problem

I ...
  Topic: [PIC24HJ256GP210] Device ID becomes corrupted
canadidan

Replies: 43
Views: 65121

PostForum: General CCS C Discussion   Posted: Fri Mar 01, 2019 3:55 pm   Subject: [PIC24HJ256GP210] Device ID becomes corrupted
Great idea!

The initial setup is the same (no surprise):


// V4.106
//write_program_memory(_romw_curr_page, _romw_buffer, sizeof(_romw_buffer)); //write modified block
284 ...
  Topic: [PIC24HJ256GP210] Device ID becomes corrupted
canadidan

Replies: 43
Views: 65121

PostForum: General CCS C Discussion   Posted: Fri Mar 01, 2019 9:49 am   Subject: [PIC24HJ256GP210] Device ID becomes corrupted
I agree, and I wish we had transparency into that particular function.

My primary goal was to reduce instances of the Device ID becoming corrupt upon the very first upgrade. Of the 5 units tested w ...
  Topic: [PIC24HJ256GP210] Device ID becomes corrupted
canadidan

Replies: 43
Views: 65121

PostForum: General CCS C Discussion   Posted: Fri Mar 01, 2019 8:53 am   Subject: [PIC24HJ256GP210] Device ID becomes corrupted
Verdict

After a race to the death with two brand new ICs, my original hypothesis doesn't hold up:

Hypothesis: along with using rom_modify(), I need to port my code from V4.106 compiler to V5.044 ...
  Topic: [PIC24HJ256GP210] Device ID becomes corrupted
canadidan

Replies: 43
Views: 65121

PostForum: General CCS C Discussion   Posted: Thu Feb 28, 2019 7:29 am   Subject: [PIC24HJ256GP210] Device ID becomes corrupted
@Ttelmah - this is true, good point. However, wouldn't failure only occur in the blocks being erase/written? Even after 1000 cycles, the device ID block shouldn't become corrupted right?

Compiler V ...
  Topic: [PIC24HJ256GP210] Device ID becomes corrupted
canadidan

Replies: 43
Views: 65121

PostForum: General CCS C Discussion   Posted: Wed Feb 27, 2019 12:27 pm   Subject: [PIC24HJ256GP210] Device ID becomes corrupted
It's not quite resolved!

The firmware was originally programmed with V4.106.

I ported the BIOS to V5.044 fine, but the firmware had a bunch of bugs with the newer compiler.

The test last nigh ...
  Topic: [PIC24HJ256GP210] Device ID becomes corrupted
canadidan

Replies: 43
Views: 65121

PostForum: General CCS C Discussion   Posted: Wed Feb 27, 2019 8:49 am   Subject: [PIC24HJ256GP210] Device ID becomes corrupted
Good news - I think I solved it.

rom_write.c

I discovered the rom_write library in Compiler V5.044 - it wasn't in V4.106.

This library includes the rom_modify() function. This function handle ...
  Topic: [PIC24HJ256GP210] Device ID becomes corrupted
canadidan

Replies: 43
Views: 65121

PostForum: General CCS C Discussion   Posted: Mon Feb 25, 2019 3:34 pm   Subject: [PIC24HJ256GP210] Device ID becomes corrupted
Update

Erase loop does not seem to be the problem

* Commented out the erase loop: Corruption still occurs

* Page-aligned the erase: Corruption still occurs


void BIOS_Erase_CPU_Flash_FMWR ...
  Topic: [PIC24HJ256GP210] Device ID becomes corrupted
canadidan

Replies: 43
Views: 65121

PostForum: General CCS C Discussion   Posted: Fri Feb 22, 2019 8:15 am   Subject: [PIC24HJ256GP210] Device ID becomes corrupted
@dexta64 - actually I don't want it to touch the bootloader - this should be protected (recovery mode).

I'm still reworking this code - basically I want to buffer a whole page then write in one sho ...
  Topic: [PIC24HJ256GP210] Device ID becomes corrupted
canadidan

Replies: 43
Views: 65121

PostForum: General CCS C Discussion   Posted: Thu Feb 21, 2019 10:40 am   Subject: [PIC24HJ256GP210] Device ID becomes corrupted
Understood, both of you Smile I didn't write this code, just inherited it, and your help dissecting it is huge.

Data Length Packing

ROW = 192 bytes = 64 instructions
PAGE = 1536 bytes = 512 instru ...
 
Page 1 of 2 Goto page 1, 2  Next
All times are GMT - 6 Hours
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group