完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
电子发烧友论坛|
大家好,我对我的项目中的数据内存有一些问题。我做了一篇关于这个的文章(http://www. McCys.com /论坛/ M96803.ASPX),但是我正在创建另一篇文章,因为我现在从另一个角度看问题。基本上,我需要在FO中分配更多的数据内存。RM OFA 1K字符数组(虽然我相信确切的数字并不重要)。从DasBoADI可以看到我使用26K(49%)可用内存。在声明新数组之后,编译过程失败,链接错误:无法定位数据内存(在前一篇文章中的明确描述)。PosSeLeLY,大小为500,编译工作很好,但是程序得到了一个StAdStage异常(我仍然需要知道)。现在,在学习了数据表和家庭参考手册之后,我需要有人来确认我理解的是否正确:我有几个语言字符串AR。射线保存在PROG内存中的自动PSV管理(下面的例子)从家庭参考手册我的PIC应该有52K字节的RAM,其中上限32千字节[…]可以可选地映射到任何16K字程序空间页,这将是PSV页面机制(HTTP:/WW1.MICC)粗略地说,Adess空间是这样组织的:从0x00到0x0FFF,我保留了SFR空间(4K)——从0x0100到0x7FFF,它是可用的RAM(28 K)——从0x8000到0xFFFF,它是扩展内存,可选地DMA或PSV,我的问题主要是:如果我是HAVEPSV阵列是否意味着我只能使用第一个28字节的数据存储器?这就是为什么我不能分配更多内存的原因吗?如果是的话,有没有办法禁用PSV并使用整个52K?可能仍然在程序内存中保存我的语言字符串吗?长话短说,我可能现在意识到我的可用内存比我要少得多,我希望有人能确认它。
以上来自于百度翻译 以下为原文 Hello everyone, I'm having a few problems with the data memory in my project. I made a previous post about this (http://www.microchip.com/forums/m976803.aspx), but I'm creating another because I'm now seeing the problem from another perspective. Basically, I need to allocate more data memory, in the form of a 1K char array (though I believe the exact number is not important). From the dashboard I can see I used 26K (49%) of the available memory. After declaring the new array volatile unsigned char ReceivePacket_UART4aa[1000]; the compilation process fails with a linker error: could not allocate data memory (explicit description in the previous post). Possibly unrelelated, with a size of 500 the compilation works fine, but the program gets a StackAddress exception (wich I still have to figure out). Now, after studying the datasheet and family reference manual I need someone to confirm if what I understand is correct: I have several Language string arrays saved in the prog memory with automatic psv management (example below) __psv__ const LANGUAGE_STR_STATO_16 ITA_table_stato_16[NUMBER_STATO+1+1] __attribute__((space(psv))) = { ... }; from the family reference manual my PIC should have 52K bytes of RAM, of which The upper 32 Kbytes [...] can optionally be mapped into any16K word program space page and that would be the psv page mechanism (http://ww1.microchip.com/...iceDoc/70000613d.pdf). Roughly speaking, the addess space is organized like this: - from 0x0000 to 0x0FFF I have reserved SFR space (4K) - from 0x0100 to 0x7FFF it's usable RAM (28K) - from 0x8000 to 0xFFFF it's extended memory, optionally DMA or PSV dedicated My question basically is: if I have psv arrays does that mean I can only use the first 28 Kbytes of data memory? Can that be the reason why I can't allocate any more memory? And if so, is there a way to disable psv and use the whole 52K? Possibly while still saving my Language strings in program memory? Long story short, I might be realizing just now that my available memory is much less than I though, and I want someone to confirm it. |
|
相关推荐
1个回答
|
|
|
本在那里也被咬了,你可以使用SuxyEysEdSyxyByAyAtditTyx((节(EDS1)),空间(EDS))RAMFONT32(32×2×224);RAM阵列。对于ROM阵列,空间(PSV)应该类似地工作(我现在找不到一个例子……)
以上来自于百度翻译 以下为原文 Ben there and been bitten too You can use such __eds__ BYTE __attribute__((section("eds1"),space(eds))) ramFont32[32*2*224]; for RAM arrays. For ROM arrays, space (psv) should work similarly (I can't find an example right now...) |
|
|
|
|
只有小组成员才能发言,加入小组>>
MPLAB X IDE V6.25版本怎么对bootloader和应用程序进行烧录
475 浏览 0 评论
5795 浏览 9 评论
2334 浏览 8 评论
2224 浏览 10 评论
请问是否能把一个ADC值转换成两个字节用来设置PWM占空比?
3530 浏览 3 评论
1126浏览 1评论
有偿咨询,关于MPLAB X IPE烧录PIC32MX所遇到的问题
1098浏览 1评论
我是Microchip 的代理商,有PIC16F1829T-I/SS 技术问题可以咨询我,微信:A-chip-Ti
873浏览 1评论
MPLAB X IDE V6.25版本怎么对bootloader和应用程序进行烧录
475浏览 0评论
/9
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2025-12-3 11:08 , Processed in 1.486598 second(s), Total 75, Slave 58 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191

淘帖
1577