完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
电子发烧友论坛
|
|
相关推荐
1 个讨论
|
|
|
你好,
这是受C55x c编译器只能寻址16bit地址(64K)的限制, 解决方法见下面的FAQ. In C55x, why does a long pointer fail when incremented over a 64k boundary? Problem: When a long pointer is incremented and crosses over a 64k boundary (ie, an address which is a multiple of 0x0001_0000) why isn't the upper 7 bits of the address modified? It appears the address just wraps around the same 64k block of memory. Solution: Even when the large memory, which supports 23-bit pointers, is used the compiler does not calculate the offset from the base address correctly when crossing a 64k page boundary. For example, if you have a pointer which starts at 0x2f000 and increment the pointer to pass address 0x2ffff, instead of becoming 0x30000 the address will wrap around and become 0x20000. The same is true for arrays, which should not span a 64k page boundary. A workaround is to manually check for a boundary change and keep track of what the next page should be. #pragma DATA_SECTION(gMp3, "ERAM") int gMp3[200000]; int *p; unsigned long int nextPage; unsigned long i; nextPage = (((unsigned long int)gMp3 & 0x7F0000) >> 16) + 1; for ( i = 0; i < 200000; i++)[ *p++ = 0x0000; /* IMPORTANT: need this to manage page boundries manually. */ if (((unsigned long int)p & 0xFFFF) == 0) [ p = (int *)(nextPage++ << 16); ] |
|
|
|
|
|
|
|
只有小组成员才能发言,加入小组>>
549 浏览 0 评论
1613 浏览 0 评论
2047 浏览 0 评论
为啥BQ7693003DBTR芯片在和BQ769X0盒子通讯时收不到信号?
1513 浏览 0 评论
DSP 28027F 开发板 XDS100v2调试探针诊断日志显示了 Error -150 (SC_ERR_FTDI_FAIL)如何解决
1337 浏览 0 评论
AT32F407在USART2 DMA发送数据时,接包接到了要发送的数据,程序还是处于等待传输完成的标识判断中,为什么?
1757浏览 29评论
2781浏览 23评论
请问下tpa3220实际测试引脚功能和官方资料不符,哪位大佬可以帮忙解答下
1724浏览 20评论
请教下关于TAS5825PEVM评估模块原理图中不太明白的地方,寻求答疑
1634浏览 14评论
两个TMP117传感器一个可以正常读取温度值,一个读取的值一直是0,为什么?
1645浏览 13评论
/9
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2025-12-2 10:15 , Processed in 1.396862 second(s), Total 69, Slave 52 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191

淘帖
5356