S32 Configuration Tool SpiPhyUnit mapping to SpiExternal Device

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

S32 Configuration Tool SpiPhyUnit mapping to SpiExternal Device

Jump to solution
1,038 Views
matnerd
Contributor II

Hello NXP Community,

 

I have an LPSPI device driver I'm developing for an S32K344 with the MBDT toolbox 1.3.0.

I completed the design of a single LSPI channel with no issues.

However, when I attempt to instantiate a 2nd driver on a separate LSPI unit, I cannot get the Configuration Tool (1.6) to map to the proper SpiPhyUnit.

I assign a single SpiJob to a SpiSequence and SpiExternalDevice.

All Job's will run on whatever I define as SpiPhyUnit[0].

Looking over all of the generated source, I do not see how the device gets assigned to a SpiPhyUnit…

I have screenshots of my configuration below…

Any help is greatly appreciated!

Scott

0 Kudos
1 Solution
997 Views
Irina_Costachescu
NXP Employee
NXP Employee

Hi Scott,

The mapping between an SpiExternalDevice and an SpiPhyUnit is configured with the help of the SpiHwUnit setting, which can be found inside the SpiExternalDevice tab, as illustrated in the screenshot below:

Irina_Costachescu_0-1678379133865.png

As mentioned in the SpiHwUnit setting tooltip, you should choose the CSIB parameter, from the dropdown list, according to the order in which the LPSPI instances were configured inside the SpiPhyUnit tab.

Based on your attached screenshots, if you would like your SpiExternalDevice_0 to be associated to the LPSPI2 instance, you should select the SpiHwUnit as CSIB0, since LPSPI2 is configured as the first SpiPhyUnit.

From the attached LPSPI3.jpg, I see that SpiExternalDevice_1 has the SpiHwUnit set on CSIB0 as well. Under this configuration, it means that the SpiExternalDevice_1 is also associated to the LPSPI2 instance, and not to a different one. 

Hence, if you would like your SpiExternalDevice_1 to be associated to the LPSPI1 instance, you should select the SpiHwUnit as CSIB1, since LPSPI1 is configured as the second SpiPhyUnit.

Hope this helps,

Irina

 

View solution in original post

2 Replies
998 Views
Irina_Costachescu
NXP Employee
NXP Employee

Hi Scott,

The mapping between an SpiExternalDevice and an SpiPhyUnit is configured with the help of the SpiHwUnit setting, which can be found inside the SpiExternalDevice tab, as illustrated in the screenshot below:

Irina_Costachescu_0-1678379133865.png

As mentioned in the SpiHwUnit setting tooltip, you should choose the CSIB parameter, from the dropdown list, according to the order in which the LPSPI instances were configured inside the SpiPhyUnit tab.

Based on your attached screenshots, if you would like your SpiExternalDevice_0 to be associated to the LPSPI2 instance, you should select the SpiHwUnit as CSIB0, since LPSPI2 is configured as the first SpiPhyUnit.

From the attached LPSPI3.jpg, I see that SpiExternalDevice_1 has the SpiHwUnit set on CSIB0 as well. Under this configuration, it means that the SpiExternalDevice_1 is also associated to the LPSPI2 instance, and not to a different one. 

Hence, if you would like your SpiExternalDevice_1 to be associated to the LPSPI1 instance, you should select the SpiHwUnit as CSIB1, since LPSPI1 is configured as the second SpiPhyUnit.

Hope this helps,

Irina

 

990 Views
matnerd
Contributor II

Yeah - Thank You!

Operator - error, for some reason my brain was processing the CSIBx as a chip select channel...

This was driving me nuts - went so far as to run Beyond Compare on the folder structure while making slight changes to the config...

Blue Sky LpSpi!