This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Memory mapping an LCD

Hi,

I'm trying to memory map an LCD module to the at91m42800A's external bus interface. I currently have the 8-bit device connected to the EBI on chip select 4. I also configured it's memory space (0x50000000-0x50FFFFFF) in startup.s.

However, every time I attempt a read/write to this device, the processor aborts. I realize this is a Linker problem, but I'm not sure how to configure it. I'm using the Keil toolset, btw.

Do I need to define a new memory CLASS, like XDATA? Any input on this subject would be much appreciated.

Cheers,

Tracy

Parents
  • Yeah,

    I figured it out finally. I was having problems trying to map the LCD to an absolute address. For example, when I attempted to read/write the LCD, the arm would throw a data abort.

    Fortunately, the CARM compiler implements an __at directive to specify where variables map to the memory space. I declared a variable

    volatile int lcd_reg __at 0x40000000;

    where 0x40000000 is the base address for the LCD memory space. This solved my problem.

Reply
  • Yeah,

    I figured it out finally. I was having problems trying to map the LCD to an absolute address. For example, when I attempted to read/write the LCD, the arm would throw a data abort.

    Fortunately, the CARM compiler implements an __at directive to specify where variables map to the memory space. I declared a variable

    volatile int lcd_reg __at 0x40000000;

    where 0x40000000 is the base address for the LCD memory space. This solved my problem.

Children