[Icc-mot] upgrading

Edward Karpicz ekarpicz at freemail.lt
Wed Apr 9 23:28:33 PDT 2008


Wade A Smith wrote:
>>
>> STD should support up to 64k of paged memory:
>> http://www.imagecraft.com/pub/ICCV7_CPU12flyer.pdf
>>
>> BTW did you look at C64/C96/C128 chips? According to the docs these
>> should
>> have more than 48k of linear flash, though I didn't try these
>> myself.
>
> Time to test it out....
>
> 2 questions,
> 1) how do I specify that I want function main() to start at page 3C:8000?
> Most everything else can go ... wherever.


By default the same crt.s startup file is used for all configurations, paged 
and not paged. That's why crt.s always JSRs _main, and compiler always 
pushes main() into nonpaged memory. You lose some nonpaged memory, but you 
win the ease of use. You maay easily workaround main occuping nonpaged 
memory. Just rename your main() into main2() or something like that and call 
main2() from main().
I assume you checked Expanded memory Enable checkbox and Make Paged 
Functions Default? If for some reason you don't want Make Paged Default 
option, then you should use

  #pragma paged_function main2

to make main2 paged.

Do you really need sepcific paged function (main) sitting at absolute paged 
address (3c:8000)? This would be not easy and is definitely troublesome.



> 2) can I use C000-EFFF if F000-FFFF is used by the monitor and we don't
> wish to disturb that memory (because it loads the rest of flash for us)?

Of course you can use any part of any ppage as you wish. It's absolutely no 
problem having bootloader or monitor at f000-ffff and use for application 
c000-Efff or paged 3F:8000-3F:AFFF.
Defalut ICC derivative templates are set so if all nonpaged flash 4000-FFFF 
and alll paged flash was available. As soon as you enable paged memory, 
there's a page window hole so that nonpaged "text" area setting becomes 
0x4000.0x7FFF:0xC000.0xFFFF. If you want to lower upper bound, then you 
should use custom template and set program memory to 
0x4000.0x7FFF:0xC000.0xeFFF.
Paged memory setting. D64 template sets paged memory to 0xF0000.0xFFFFF. 
These figures are linear addresses. The least D64 PPAGE is 0x3C. Multiplying 
that by size of page window you get 0xF0000. 0x3F*0x4000 + 0x3FFF = 0xFFFFF. 
Now using pages 0x3E and 0x3F exclusively for nonpaged code, you can limit 
expanded memory setting to use only pages 3C and 3D: 0xF0000.0xF7FFF.


>
> We looked at the C chips, but they have NO EEPROM, which is an absolute
> must.  We even have a Delete4bytes+Program2bytes functions that write 1+
> bytes to EEPROM.
>

OK.

>
>> > We're having a meeting Friday to discuss getting one copy (of the
>> 4 we
>> > have) of the upgrade to try it out before we mess up what we have.
>>  The
>> > production guys are using two copies and they don't want to
>> disturb their
>> > procedures.
>>
>> Hm, interesting what production guys are doing with compiler and/or
>> IDE.
>> Terminal? Editor?
>
> Parmameters are set for each unit after calibration, so they go through
> their procedures for the IDE: modify the parameters; hit the compile
> button; SrecCvrt; and load it onto the chip.
> My current version (6 months newer than the production version) of the
> program uses EEPROM for the parameters.  The user interface is currently
> a serial terminal with no floating point to ASCII (toooo much space used
> up there), and now I'm working on a LCD menu/button interface.
> Eventually, production may^H^H^Hwill switch over to one of the user
> interfaces and the "compile-the-parameters-in" procedure will be changed,
> freeing up a copy of the compiler (when the EEs get over their fear of
> multi-file project software to start using the current version of the
> program instead of their tried-and-tested singular file original,
> in-house test version I gave them long ago).
>

I see it now, thanks.

Edward


>> > How much of a difference will we see in the upgrade?  What
>> differences
>> > will there be when we go to compile?
>> > I am assuming that we will want to have the interrupt handlers in
>> the
>> > 4000-7FFF range (page 3E) to keep the interrupts visible all the
>> time.
>> > Or is this a non-issue?
>>
>> Interrupt handlers should be in the 4000-7fff and c000-FEFF.
>> Non-issue since
>> these are automatically put there even if make paged functions
>> default
>> option is on.
>>
>> Edward
>
> Thand, Edward, for the info.
>
> _______________________________________________
> Icc-mot mailing list
> Icc-mot at imagecraft.com
> http://dragonsgate.net/mailman/listinfo/icc-mot
> 



More information about the Icc-mot mailing list