LPSPI Baud Rate Change

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

LPSPI Baud Rate Change

2,252件の閲覧回数
jeffthompson
Contributor V

I initially configure my SPI device at at a baud rate of 10 MHz. Following that, it's able to run at 30 MHz, so I get a copy of masterConfig by calling LPSPI_MasterGetDefaultConfig, change the baudRate member of the copy to 30000000, and then call LPSPI_MasterInit, passing it the LPSPI peripheral's base address, the modified copy of masterConfig, and the LPSPI clock frequency. I got the base address and clock frequency from peripherals.h, and they match the settings I chose using MCUXpresso ConfigTools Peripherals tools. However, the baud rate does not change. What else do I need to do?

ラベル(1)
0 件の賞賛
返信
2 返答(返信)

2,152件の閲覧回数
nxf45548
NXP Employee
NXP Employee

Can you please provide us the part number of the product that you are using? 

0 件の賞賛
返信

2,152件の閲覧回数
jeffthompson
Contributor V

MIMXRT1062DVL6A

Found the problem. Before calling LPSPI_MasterInit, I had to call LPSPI_Enable( base, false ) to disable the peripheral first. The MasterInit call enables it automatically.

0 件の賞賛
返信