This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Can't write mibSPI registers

Other Parts Discussed in Thread: TMS570LS3137

Hi everyone,

I need some help. I'm trying to use SPI port as GIO, but I can't write in the registers

Environment:
Target: TMS570LS3137
IDE: IAR worckbench


#define STD_OFF    0
#define GPIO__OUTPUT    1
#define GPIO__MBSPI1_addr     ((gioPort_t *) 0xFFF7F418U)
#define GPIO__MBSPI3_addr     ((gioPort_t *) 0xFFF7F818U)
#define GPIO__MBSPI5_addr     ((gioPort_t *) 0xFFF7FC18U)


/* Set MBSPI5 CS[0] as output */
GPIO__MBSPI5_addr->DOUT |= (STD_OFF<< 0);
GPIO__MBSPI5_addr->DIR |= (GPIO__OUTPUT<< 0);


/* Set MBSPI1 SIMO[0] as output */
GPIO__MBSPI1_addr->DOUT |= (STD_OFF<< 10);
GPIO__MBSPI1_addr->DIR |= (GPIO__OUTPUT<< 10);


But DIR register has no change. Always has the value of Zero (GPIO__MBSPIx_addr->DIR = 0). And therefore I can't use as digital output

Is there some register than prevents writing?

Thanks