完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
大家好,
我需要擦除和写的SA0扇区在M95F77 8L,但我不能写的数据到那个,可以有任何人帮助我在此。 下面我提到我的示例代码擦除和写入数据。(同样的代码工作以及SA3部门) 注: 启用SSEN位。 SWR00= 0x0F; 扇区擦除: { γ-WaITynop-(); γ-WaITynop-(); FSRYWRE=1; γ-WaITynop-(); γ-WaITynop-(); Sure0} =双闪光灯; αi(); *((uint8_t *)((sectorstartaddress &;0xf000)| 0x0aaa))= 0xaa; *((uint8_t *)((sectorstartaddress &;0xf000)| 0x0554))= 0x55; *((uint8_t *)((sectorstartaddress &;0xf000)| 0x0aaa))= 0x80; *((uint8_t *)((sectorstartaddress &;0xf000)| 0x0aaa))= 0xaa; *((uint8_t *)((sectorstartaddress &;0xf000)| 0x0554))= 0x55; *((uTn8*t*)扇区起始地址)=0x30; γ-WaITynop-(); γ-WaITynop-(); αi(); } 部门写作: { αi(); FSRYWRE=1; γ-WaITynop-(); γ-WaITynop-(); Sure0} =双闪光灯; *((Unt8*T*)(地址和0xF000)0x0AAA)=0xAA; *((Unt8*T*)(地址和0xF000)0x055 4)=0x55; *((Unt8*T*)(地址和0xF000)0x0AAA)=0xA0; *((uTn8*t*)(地址))=u8DATA; γ-WaITynop-(); γ-WaITynop-(); 而(!)FSRY-RDY; αi(); } 谢谢 阿尼尔-库马尔-维米拉 以上来自于百度翻译 以下为原文 Hello All, I need to Erase and Write the SA0 Sector in MB95F778L, but i am not able write the data into that,can any one help me on this please. below i mentioned my example code for erasing and writing the data.(This same code is working well for SA3 sector) Note:: SSEN bit is enabled. SWRE0 = 0x0F; For Sector erasing:: { __wait_nop(); __wait_nop(); FSR_WRE = 1; __wait_nop(); __wait_nop(); SWRE0 |= DUALFLASH_APPL_WEN_MASK; __DI(); *((uint8_t*)((SectorStartAddress & 0xF000) | 0x0AAA)) = 0xAA; *((uint8_t*)((SectorStartAddress & 0xF000) | 0x0554)) = 0x55; *((uint8_t*)((SectorStartAddress & 0xF000) | 0x0AAA)) = 0x80; *((uint8_t*)((SectorStartAddress & 0xF000) | 0x0AAA)) = 0xAA; *((uint8_t*)((SectorStartAddress & 0xF000) | 0x0554)) = 0x55; *((uint8_t*)SectorStartAddress) = 0x30; __wait_nop(); __wait_nop(); __EI(); } For Sector Writting: { __DI(); FSR_WRE = 1; __wait_nop(); __wait_nop(); SWRE0 |= DUALFLASH_APPL_WEN_MASK; *((uint8_t*)((Address & 0xF000) | 0x0AAA)) = 0xAA; *((uint8_t*)((Address & 0xF000) | 0x0554)) = 0x55; *((uint8_t*)((Address & 0xF000) | 0x0AAA)) = 0xA0; *((uint8_t*)(Address)) = u8Data; __wait_nop(); __wait_nop(); while (!FSR_RDY); __EI(); } Thanks Anil Kumar VEMULA |
|
相关推荐
1个回答
|
|
你好,
当您试图更新SA0位置时,哪个引导程序执行擦除/写入命令,在SA1还是SA2? 我希望在SA1的引导加载程序发出擦除/写入命令来更新SA3和SA0。 M957070的双操作快闪存储器由两个银行组成,不能在同一时间在同一银行中被擦除/编程和读取(指令提取)。 SA0和SA1位于同一银行,SA2和SA3位于另一银行。 因此,SA1上的引导加载程序可以擦除/写入SA3,但不能执行SA0。 SA2上的引导加载程序可以擦除/写入SA0,但不能执行SA3。 请尝试在SA2上从Bootloader删除/写入SA0。 以上来自于百度翻译 以下为原文 Hello, When you tried to update the SA0 location, which bootloader executed the erase/write commands, at SA1 or SA2? I expect that the bootloader at SA1 issued the erase/write commands to update SA3 and SA0. The dual operation flash memory of MB95770 consists of two banks and cannot be erased/programmed and read (instruction-fetched) at the same time in bank on the same side. SA0 and SA1 are located in the same bank, while SA2 and SA3 are located in another bank. So, the bootloader at SA1 can erase/write the SA3, but cannot do the SA0. The bootloader at SA2 can erase/write the SA0, but cannot do the SA3. Please try erase/write the SA0 from the bootloader at SA2. |
|
|
|
只有小组成员才能发言,加入小组>>
756个成员聚集在这个小组
加入小组2129 浏览 1 评论
1871 浏览 1 评论
3687 浏览 1 评论
请问可以直接使用来自FX2LP固件的端点向主机FIFO写入数据吗?
1806 浏览 6 评论
1552 浏览 1 评论
CY8C4025LQI在程序中调用函数,通过示波器观察SCL引脚波形,无法将pin0.4(SCL)下拉是什么原因导致?
622浏览 2评论
CYUSB3065焊接到USB3.0 TYPE-B口的焊接触点就无法使用是什么原因导致的?
460浏览 2评论
CX3连接Camera修改分辨率之后,播放器无法播出camera的画面怎么解决?
455浏览 2评论
410浏览 2评论
使用stm32+cyw43438 wifi驱动whd,WHD驱动固件加载失败的原因?
1099浏览 2评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2025-1-24 02:25 , Processed in 0.862616 second(s), Total 77, Slave 61 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号