Quantcast
Channel: Processors forum - Recent Threads
Viewing all articles
Browse latest Browse all 17527

Connect EMIFA to DSP in DSP/ARM system

$
0
0

Dear All,

I have a problem with EMIFA on OMAPL137 EVM. The system is composed of Linux running on ARM and some codes running on DSP. I want to use EMIFA on DSP side. It seems that since ARM uses SD so the lower byte of the EMIFA is not usable on DSP side. Therefore, we use the higher byte of the EMIFA. Linux is loaded on ARM and then ARM loads a program on DSP. The program loaded on DSP wants to use the higher byte of EMIFA but it is not working. I use the following code to modify the PINMUXs: 

#define AEMIF_AWCCR *( unsigned int* )( 0x68000004 )
#define AEMIF_A1CR *( unsigned int* )( 0x68000010 )
#define AEMIF_A2CR *( unsigned int* )( 0x68000014 )
#define AEMIF_A3CR *( unsigned int* )( 0x68000018 )
#define AEMIF_A4CR *( unsigned int* )( 0x6800001C )
#define AEMIF_NANDFCR *( unsigned int* )( 0x68000060 )

void Setup_EMIFA( )
{
KICK0R = 0x83e70b13; // Kick0 register + data (unlock)
KICK1R = 0x95a4f1e0; // Kick1 register + data (unlock)
// Use extended wait cycles to keep CE low during NAND access
AEMIF_AWCCR = 0xff;

// Setup CS2 - 8-bit normal async
AEMIF_A1CR = 0x00300608;
AEMIF_NANDFCR &= ~1;

// Setup CS3 - 8-bit NAND
AEMIF_A2CR = 0x00300388;
AEMIF_NANDFCR &= ~2;

// Setup CS4 - 8-bit normal async
AEMIF_A3CR = 0x00a00504; // Setup=0, Strobe=A, Hold=0, TA=1, 8-bit
AEMIF_NANDFCR &= ~4;

// Setup CS5 - 8-bit normal async
AEMIF_A4CR = 0x00a00504; // Setup=0, Strobe=A, Hold=0, TA=1, 8-bit
AEMIF_NANDFCR &= ~8;

// Setup CS3 - 8-bit NAND
AEMIF_A2CR = 0x0031fff9;
AEMIF_NANDFCR &= ~2;

}


void Setup_EMIFA_PinMux()
{
KICK0R = 0x83e70b13; // Kick0 register + data (unlock)
KICK1R = 0x95a4f1e0; // Kick1 register + data (unlock)
//PINMUX13 &= 0x00FFFFFF;
//PINMUX13 |= 0x22000000;
PINMUX14 &= 0x00FFFFFF;
PINMUX14 |= 0x11000000;
PINMUX15 &= 0xF0000000;
PINMUX15 |= 0x01111111;
PINMUX16 &= 0x0000000F;
PINMUX16 |= 0x11111110;
PINMUX17 = 0x11111111;
PINMUX18 = 0x11111111;
PINMUX19 &= 0xFFFFFFF0;
PINMUX19 |= 0x00000001;
}

...

I use the following code to test EMIFA:

#define EMIFABaseAddress ( unsigned short* )(0x62000000)
volatile short *output = (short *)EMIFABaseAddress;

int main(){

Setup_EMIFA();
Setup_EMIFA_PinMux();
while (1==1)
output[255]=127;

}

What is the problem in your idea?

Thanks,

 


Viewing all articles
Browse latest Browse all 17527

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>