您尚未登录。

楼主 #1 2018-04-25 13:55:11

BugActiveDaughter
会员
注册时间: 2017-10-17
已发帖子: 118
积分: 117.5

stm32f429的nand hal 驱动有bug

HAL_NAND_Write_Page函数要多加一句   *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = 0x00U; ,如下
/* Send read page command sequence */
    *(__IO uint8_t *)((uint32_t)(deviceaddress | CMD_AREA)) = NAND_CMD_AREA_A;
   
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = 0x00U;
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = 0x00U; //add
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = ADDR_1ST_CYCLE(addressoffset);
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = ADDR_2ND_CYCLE(addressoffset);
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = ADDR_3RD_CYCLE(addressoffset);

HAL_NAND_Read_Page要改三个地方 ,下边有add就是增加语句

    /* Send read page command sequence */
    *(__IO uint8_t *)((uint32_t)(deviceaddress | CMD_AREA)) = NAND_CMD_AREA_A;
   
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = 0x00U;
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = 0x00U; // 1  add
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = ADDR_1ST_CYCLE(addressoffset);
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = ADDR_2ND_CYCLE(addressoffset);
    *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = ADDR_3RD_CYCLE(addressoffset);
 
    /* for 512 and 1 GB devices, 4th cycle is required */
    if(hnand->Info.BlockNbr >= 1024U)
    {
     *(__IO uint8_t *)((uint32_t)(deviceaddress | ADDR_AREA)) = ADDR_4TH_CYCLE(addressoffset);
    }
 
    *(__IO uint8_t *)((uint32_t)(deviceaddress | CMD_AREA))  = NAND_CMD_AREA_TRUE1;

    for(i = 0; i < 10; i++);//2  add
    if(NAND_WaitRB(1))return HAL_BUSY;    //3//add

离线

#2 2018-04-25 13:56:17

daydayup
会员
注册时间: 2017-10-09
已发帖子: 343
积分: 343

Re: stm32f429的nand hal 驱动有bug

谢谢分享!

离线

#3 2018-04-25 13:57:11

qianhao
会员
注册时间: 2017-12-14
已发帖子: 138
积分: 122

Re: stm32f429的nand hal 驱动有bug

学到了 活到老学到老

离线

楼主 #4 2018-04-25 13:58:18

BugActiveDaughter
会员
注册时间: 2017-10-17
已发帖子: 118
积分: 117.5

Re: stm32f429的nand hal 驱动有bug

1.6版本的hal库

离线

楼主 #5 2018-04-27 11:02:09

BugActiveDaughter
会员
注册时间: 2017-10-17
已发帖子: 118
积分: 117.5

Re: stm32f429的nand hal 驱动有bug

升级到最新的就不会有bug,兼容性就比较好

离线

#6 2018-04-27 11:15:57

晕哥
管理员
注册时间: 2017-09-06
已发帖子: 9,348
积分: 9202

Re: stm32f429的nand hal 驱动有bug

BugActiveDaughter 说:

升级到最新的就不会有bug,兼容性就比较好

最新是哪个版本?





离线

#7 2018-06-19 18:37:38

19697805
会员
注册时间: 2018-06-19
已发帖子: 77
积分: 72

Re: stm32f429的nand hal 驱动有bug

谢谢分享!  活到老学到老

离线

#8 2019-03-09 18:21:13

tink
会员
注册时间: 2019-03-09
已发帖子: 32
积分: 32

Re: stm32f429的nand hal 驱动有bug

谢谢分享!

离线

页脚

工信部备案:粤ICP备20025096号 Powered by FluxBB

感谢为中文互联网持续输出优质内容的各位老铁们。 QQ: 516333132, 微信(wechat): whycan_cn (哇酷网/挖坑网/填坑网) service@whycan.cn