Thread: Re: [Flashforth-devel] building FF5 for dsPIC33EP256GP502
Brought to you by:
oh2aun
From: Mikael N. <mik...@pp...> - 2014-07-10 19:49:40
|
<div style="font-size:10pt;"><p style="margin-top:0;margin-bottom:0;">I guess you need to check how the interrupts and the flash memory interface works on the 33e series.</p><p style="margin-top:0;margin-bottom:0;"> </p><p style="margin-top:0;margin-bottom:0;">I cannot remember how much ram FF can address. At least 32 kbyte.</p><p style="margin-top:0;margin-bottom:0;"> </p><p style="margin-top:0;margin-bottom:0;">Was it so that the e series has eeprom?</p><p style="margin-top:0;margin-bottom:0;">If so, it could be used for the dictionary pointers like on the 30f.</p><p style="margin-top:0;margin-bottom:0;"> </p><div><signature_tag><p style="margin-top:0;margin-bottom:0;">Sent from my LG Mobile</p></signature_tag></div><p id="last_enter" style="margin-top:0;margin-bottom:0;"> </p><p style="margin-top:0;margin-bottom:0;"> </p><p style="margin-top:0;margin-bottom:0;">------ Original message------</p> <p style="margin-top:0;margin-bottom:0;"><b>From: </b>Peter Jacobs<pe...@me...></p><p style="margin-top:0;margin-bottom:0;"><b>Date: </b>Thu, 10/07/2014 17:45</p><p style="margin-top:0;margin-bottom:0;"><b>To: </b>flashforth-devel;</p><p style="margin-top:0;margin-bottom:0;"><b>Subject:</b>[Flashforth-devel] building FF5 for dsPIC33EP256GP502</p><p style="margin-top:0;margin-bottom:0;"> </p><pre>Mike, I was attempting to build the 16-bit FF for a dsPIC33EP256GP502-I/SP because I was keen to have more SRAM than the dsPIC33FJ128GP802 offered. I think that I've got the correct header files included by adding an entry to ff30.inc but have just copied the p33f_config.inc as a starting point for a new p33e_config file. Presently I have the following errors from the assembler. make -f nbproject/Makefile-default.mk SUBPROJECTS= .build-conf make[1]: Entering directory `/home/peterj/pic_work/flash-forth/ff5p0-dsPIC33EP-july-2014/FF5-for_dsPIC33EP.X' make -f nbproject/Makefile-default.mk dist/default/production/FF5-for_dsPIC33EP.X.production.hex make[2]: Entering directory '/home/peterj/pic_work/flash-forth/ff5p0-dsPIC33EP-july-2014/FF5-for_dsPIC33EP.X' "/opt/microchip/xc16/v1.21/bin/xc16-gcc" ../src/ff-pic24-30-33.s -o build/default/production/_ext/1360937237/ff-pic24-30-33.o -c -mcpu=33EP256GP502 -omf=elf -I"../src" -Wa,-MD,"build/default/production/_ext/1360937237/ff-pic24-30-33.o.d",--defsym=__MPLAB_BUILD=1,-g,--no-relax .../src/ff-pic24-30-33.s: Assembler messages: .../src/ff-pic24-30-33.s:468: Error: Invalid operands specified ('btss INTCON2,#ALTIVT'). .../src/ff-pic24-30-33.s:468: Check operand #2. Operand must be between 0 and 15, inclusive. .../src/ff-pic24-30-33.s:1126: Error: Invalid operands specified ('bclr INTCON2,#ALTIVT'). .../src/ff-pic24-30-33.s:1126: Check operand #2. Operand must be between 0 and 15, inclusive. .../src/ff-pic24-30-33.s:1136: Error: Invalid operands specified ('bset INTCON2,#ALTIVT'). .../src/ff-pic24-30-33.s:1136: Check operand #2. Operand must be between 0 and 15, inclusive. make[2]: *** [build/default/production/_ext/1360937237/ff-pic24-30-33.o] Error 255 make[1]: *** [.build-conf] Error 2 make: *** [.build-impl] Error 2 nbproject/Makefile-default.mk:97: recipe for target 'build/default/production/_ext/1360937237/ff-pic24-30-33.o' failed make[2]: Leaving directory '/home/peterj/pic_work/flash-forth/ff5p0-dsPIC33EP-july-2014/FF5-for_dsPIC33EP.X' make[1]: Leaving directory `/home/peterj/pic_work/flash-forth/ff5p0-dsPIC33EP-july-2014/FF5-for_dsPIC33EP.X' BUILD FAILED (exit value 2, total time: 158ms) It seems that the interrupt vector tables are a bit different. Any suggestions? Also, this MCU has more static RAM than will fit within the first 32k address range. I guess that I need to set appropriate boundaries. Of course, these might also be just the start of many changes that might be needed. Could you hazard a guess as to how many? I will accept an answer of "too many", but I thought that I would just try my luck and see if it was easy to get FF running on this chip. Regards, Peter Jacobs ------------------------------------------------------------------------------ Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft _______________________________________________ Flashforth-devel mailing list Fla...@li... https://lists.sourceforge.net/lists/listinfo/flashforth-devel </pre></div> |
From: Mikael N. <mik...@pp...> - 2014-07-11 09:39:58
|
Peter, I shortly looked at the datasheet. The dsPIC33EP256GP502 does not have any alternate interrupt vector table. The change you have to do in FF is to revector the standard /_default_/ interrupts to the interrupt table in ram which is managed by FF, and there handle the interrupt vectoring. Another difference is that the flash erase block is 1024 instructions (3072 bytes). That should be reflected in the configuration file. Also the flash write codes may be different. I have not checked. The eeprom emulation code for storing the dictionary pointers and the turnkey may be affected. It is now written for a flash block erase size of 1536 bytes. Good luck ! BR Mike |
From: Peter J. <pe...@me...> - 2014-07-11 11:49:19
|
Mike, Thanks for looking. The flash write codes are different; I found a pair of tables in the migration guide. The gains that I thought I would be receiving with the larger SRAM may be lost because I think that not all of that memory can be addressed with a 16-bit address (may have to set RAM_SIZE to 28k rather than the physically implemented 32k). I expect that the buffers needed to deal with the larger erase blocks for the flash will be another loss (although I have not looked at how the flash self writing routines function). On the aspects of the processor speed, the longer instruction execution pipeline on this MCU seems to suffer bigger penalties for branching than the dsPIC33FJ. And without true EEPROM, it's looking not that much better a processor to spend much time on porting FF to it. Regards, Peter J. On 11/07/14 19:39, Mikael Nordman wrote: > Peter, > I shortly looked at the datasheet. > > The dsPIC33EP256GP502 does not have any alternate interrupt vector table. > > The change you have to do in FF is to revector the standard > /_default_/ interrupts to the interrupt table in ram which is managed > by FF, and there handle the interrupt vectoring. > > Another difference is that the flash erase block is 1024 instructions > (3072 bytes). That should be reflected in the configuration file. > Also the flash write codes may be different. I have not checked. > > The eeprom emulation code for storing the dictionary pointers and the > turnkey may be affected. It is now written for a flash block erase > size of 1536 bytes. > > Good luck ! > > BR Mike > |