K22 Flexbus CSPMCR Registers

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

K22 Flexbus CSPMCR Registers

Jump to solution
709 Views
weblar
Contributor V

Hi,

I have the Flexbus of a K22 hooked up to an OLED display through FB_AD[7:0].

I'm not convinced that I've configured the Flexbus peripheral correctly as I'm seeing spurious pulses on the FB_AD[0] signal when looking at the bus on a logic analyser.

My code so far is...

// Configure the FlexBus chip select

FB->CS[0].CSAR = EBI_BASE_ADDRESS;                              // 0x60000000

// Set up the port size to 8bit

FB->CS[0].CSCR = FB_CSCR_PS(1) | FB_CSCR_AA_MASK | FB_CSCR_WS(1) | FB_CSCR_BLS_MASK;

// Set up the chip select mask register

FB->CS[0].CSMR = FB_CSMR_V_MASK;

Do I need to set FB_BE_7_0 = 1 and TSIZ[1:0] = 0b01 in the FB_CSPMCR register in order for correct 8-bit operation?

Thanks in advance,

Kev

Labels (1)
Tags (3)
0 Kudos
1 Solution
475 Views
weblar
Contributor V

Never mind, managed to fix the issue by setting the port size to 32bit but only using the lower 8 bits.

The display now works correctly with no extra tinkering.

View solution in original post

0 Kudos
1 Reply
476 Views
weblar
Contributor V

Never mind, managed to fix the issue by setting the port size to 32bit but only using the lower 8 bits.

The display now works correctly with no extra tinkering.

0 Kudos