#ifndef HARDWARE_MEMC_H_
#define HARDWARE_MEMC_H_

typedef struct
{
	volatile unsigned romKey;
	volatile unsigned romCtrl;
	volatile unsigned romClkDiv;
	volatile unsigned romSt;
	volatile unsigned extmemCtrl;
} MemcRegs;

#define MEMC_ROM_ST_RD_ERR      (1U << 3)
#define MEMC_ROM_ST_WR_ERR      (1U << 2)
#define MEMC_ROM_ST_ROM_BUSY    (1U << 1)
#define MEMC_ROM_ST_PGM         (1U << 0)

#define MEMC_EXTMEM_CTRL_T1_1   (1U << 2)
#define MEMC_EXTMEM_CTRL_T1_0   (0U << 2)
#define MEMC_EXTMEM_CTRL_T0_4   (3U << 0)
#define MEMC_EXTMEM_CTRL_T0_3   (2U << 0)
#define MEMC_EXTMEM_CTRL_T0_2   (1U << 0)
#define MEMC_EXTMEM_CTRL_T0_1   (0U << 0)

#endif /* HARDWARE_MEMC_H_ */
