You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
84 lines
2.8 KiB
84 lines
2.8 KiB
/* ===========================================================================
|
|
* COPYRIGHT (C) 2016-2023 ConvenientPower Semiconductor. ALL RIGHTS RESERVED.
|
|
*
|
|
* Filename: cmd.h
|
|
* Author : Wenge.Duan <Wenge.Duan@convenientpower.com>
|
|
* Date : 05/18/2023
|
|
* Description:
|
|
*
|
|
* ===========================================================================
|
|
*/
|
|
|
|
#pragma once
|
|
#ifndef __CMD__
|
|
#define __CMD__
|
|
|
|
#define _CMD 0x200009F0
|
|
#define _FLAG 0x200009F4
|
|
|
|
#define _BUFFER0 0x20000880 // program buffer0
|
|
#define _BUFFER1 0x200008C0 // program buffer1
|
|
#define _BUFFER2 0x20000860 // code len
|
|
#define _BUFFER3 0x20000870 // crc
|
|
|
|
|
|
|
|
#define ADDR_CMD (uint16_t *) _CMD
|
|
#define ADDR_FLAG (uint16_t *) _FLAG
|
|
|
|
#define ADDR_BUFFER0 (uint32_t *) _BUFFER0
|
|
#define ADDR_BUFFER1 (uint32_t *) _BUFFER1
|
|
#define ADDR_BUFFER2 (uint32_t *) _BUFFER2
|
|
#define ADDR_BUFFER3 (uint32_t *) _BUFFER3
|
|
|
|
|
|
#define CHIP_ERASE 0x5000
|
|
#define PAGE_ERASE 0x5100
|
|
#define SECTOR_ERASE 0x5200
|
|
|
|
#define PGM_CKBD 0x1000
|
|
#define PGM_CKBDB 0x1100
|
|
#define PGM_FF 0x1200
|
|
#define PGM_BUFFER0 0x2000
|
|
#define PGM_BUFFER1 0x2100
|
|
#define PGM_TRIM 0x3000
|
|
#define PGM_CAL 0x3100
|
|
|
|
#define CP_READ_FF 0x4000
|
|
#define CP_READ_CKBD 0x4100
|
|
#define CP_READ_CKBDB 0x4200
|
|
//#define CP_INITIAL_MARGIN_READ_CKBD 0x4300
|
|
//#define CP_PGM_MARGIN_READ_CKBD 0x4400
|
|
#define CP_READ_00 0x4300
|
|
//#define CP_READ_00_VDDH 0x4600
|
|
//#define CP_PGM_MARGIN_READ_00 0x4700
|
|
//#define CP_INITIAL_MARGIN_READ_MAIN_FF 0x4800
|
|
//#define CP_READ_FF 0x4900
|
|
//#define CP_READ_CODE 0x4a00
|
|
//#define CP_INITIAL_MARGIN_READ_CODE 0x4b00
|
|
//#define CP_PGM_MARGIN_READ_CODE 0x4c00
|
|
//#define ICC_READ 0x5000
|
|
//#define FT_READ_FF_VDDL 0x6000
|
|
//#define FT_READ_FF_VDDH 0x6100
|
|
//#define FT_READ_CODE_VDDL 0x6200
|
|
//#define FT_READ_CODE_VDDH 0x6300
|
|
//#define FT_INITIAL_MARGIN_READ_CODE 0x6400
|
|
//#define FT_PGM_MARGIN_READ_CODE 0x6500
|
|
|
|
|
|
#define CALC_CRC_APP 0x7000
|
|
#define CALC_CRC_TEST 0x7100
|
|
#define CALC_CRC_ROM 0x7200
|
|
|
|
|
|
|
|
#define RUNNING 0x1000
|
|
#define PASS 0x2000
|
|
#define FAIL 0x3000
|
|
#define ILLEGAL 0x4000
|
|
#define IDLE 0x5000
|
|
|
|
// pipeline buffer and handshake
|
|
#define SECTOR_LENGTH 64
|
|
|
|
#endif
|
|
|