#ifndef HARDWARE_MEMORY_MAP_H_
#define HARDWARE_MEMORY_MAP_H_

#include "8051.h"
#include "adc.h"
#include "cfg.h"
#include "cmp.h"
#include "dbg.h"
#include "gpio.h"
#include "int_ctrl.h"
#include "lssi.h"
#include "owi.h"
#include "prcmm.h"
#include "timer.h"
#include "wdt.h"

#define BA_RAM      0x0000
#define BA_CFG      0x0800
#define BA_ROM_DATA 0x1000
#define BA_DBG      0x2000
#define BA_PRCMM    0x2100
#define BA_INT_CTRL 0x2200
#define BA_WDT      0x2300
#define BA_GPIOA    0x2400
#define BA_GPIOB    0x2500
#define BA_GPIOC    0x2600
#define BA_CMP      0x2700
#define BA_ADC      0x2700
#define BA_LSSI0    0x2800
#define BA_LSSI1    0x2900
#define BA_OWI      0x2A00
#define BA_TIMER    0x2B00

#define RAM         ((volatile unsigned char __xdata*)BA_RAM)
#define CFG         ((CfgRegs __xdata*)BA_CFG)
#define ROM_DATA    ((volatile unsigned char __xdata*)BA_ROM_DATA)
#define DBG         ((DbgRegs __xdata*)BA_DBG)
#define PRCMM       ((PrcmmRegs __xdata*)BA_PRCMM)
#define INT_CTRL    ((IntCtrlRegs __xdata*)BA_INT_CTRL)
#define WDT         ((WdtRegs __xdata*)BA_WDT)
#define GPIOA       ((GpioRegs __xdata*)BA_GPIOA)
#define GPIOB       ((GpioRegs __xdata*)BA_GPIOB)
#define GPIOC       ((GpioRegs __xdata*)BA_GPIOC)
#define CMP         ((CmpRegs __xdata*)BA_CMP)
#define ADC         ((AdcRegs __xdata*)BA_ADC)
#define LSSI0       ((LssiRegs __xdata*)BA_LSSI0)
#define LSSI1       ((LssiRegs __xdata*)BA_LSSI1)
#define OWI         ((OwiRegs __xdata*)BA_OWI)
#define TIMER       ((TimerRegs __xdata*)BA_TIMER)

#endif /* HARDWARE_MEMORY_MAP_H_ */
