Dev_Inf.h 896 B

1234567891011121314151617181920212223242526272829
  1. #define MCU_FLASH 1
  2. #define NAND_FLASH 2
  3. #define NOR_FLASH 3
  4. #define SRAM 4
  5. #define PSRAM 5
  6. #define PC_CARD 6
  7. #define SPI_FLASH 7
  8. #define I2C_FLASH 8
  9. #define SDRAM 9
  10. #define I2C_EEPROM 10
  11. #define SECTOR_NUM 10 // Max Number of Sector types
  12. struct DeviceSectors
  13. {
  14. unsigned long SectorNum; // Number of Sectors
  15. unsigned long SectorSize; // Sector Size in Bytes
  16. };
  17. struct StorageInfo
  18. {
  19. char DeviceName[100]; // Device Name and Description
  20. unsigned short DeviceType; // Device Type: ONCHIP, EXT8BIT, EXT16BIT, ...
  21. unsigned long DeviceStartAddress; // Default Device Start Address
  22. unsigned long DeviceSize; // Total Size of Device
  23. unsigned long PageSize; // Programming Page Size
  24. unsigned char EraseValue; // Content of Erased Memory
  25. struct DeviceSectors sectors[SECTOR_NUM];
  26. };