arjun.a
rename files
6c7b14a
Ticket Name: [TDA4M] Questions about PSDK SPI Test on TDA4M EVM Board
Query Text:
Other Parts Discussed in Thread: TDA2 Dear Ti members, I would like to test the SPI communication between the MCU and Main domain using PSDK 0.9 SW on the TDA4M EVM board. I have some questions about this as below. 1. According to the mcusw release document, SPI communication test between MCU and Main domain A72 is completed through MCUSS Demo App based on RTOS. Is the psdk 0.9 version of the SPI communication test complete? Error occurs due to header file when building ipc_spi_slave code of MCUSS Demo App. The problem is caused by an invalid header file which is not for TDA4M. ( in ipc_spi_slave_app.c ) Build error reason ==> #include <ti/csl/soc/am65xx/src/cslr_soc.h> Modify ==> #include <ti/csl/soc/j721e/src/cslr_soc.h> As there is no code of am65xx, it is impossible to check the comparison, so I request reconfirmation upon completion of SPI communication test. 2. According to the mcusw release document, SPI communication test between MCU and Main domain A72 is completed through MCUSS Demo App based on RTOS. However, in PSDK 0.9, we know that the Main domain A72 is only Linux supported. I tried to modify the makefile for ipc_spi_slave_app to test on MCU2_0 or MCU2_1, but it does not build due to linker script( *.lds ) problem. Later I checked in the 0.9 release document that McSPI only supports MPU1_0 and MCU1_0. In version 0.9, is ipc_spi_slave_app test completely impossible on MCU2 and MCU3 in the main domain? Is it possible in version 1.0 3. I downloaded the kernel code from PSDK 0.9 Linux version and confirmed that the SPI Slave Driver code ( spi_omap2_mcspi.c ) exists. 1) I need to add and to modify code to use this driver ( the driver is not included now ), so I will be working on it. Can you give me a guide on how to modify and build for using this driver? ( I have no experience with Yocto base. ) 2) There are two SPI test examples in the "tools/spi" path. Are there any additional examples? And is it possible to slave test with SPIdev_test.c file? ( I will test by connecting MCU as Master and Main domain as slave. ) Please let me know your opinion. Thank you.
Responses:
Hi Junny, Regarding your 1st question, please find my reply below. Please comment the include file portion #include <ti/csl/soc/j721e/src/cslr_soc.h> as it is a bug and will be fixed in next release. After commenting, build should go fine. Regarding your 2nd question, please find my reply below. I agree with your point, right now ipc_spi_slave_app is tested on A72 only. In the next release ipc_spi_slave_app will be ported to MCU2 or MCU3 core. For 3rd question, I will forward this query to Linux expert.
As of now, the SPI is not supported in the kernel. You need to describe the SPI device in device tree and enable the driver config for the this to work. Note that this has not been tried so far on Linux Nikhil D
Dear Nikhil D Thank you for your answer. If so, will the next version of Linux(version 1.0) be released with the spi code fully included? Please let me know. Thank you. Best Regards.
Dear Sunil Thank you for your answer. If possible, can I get the code for MCU2 or MCU3 before the next release? ( If there aren't many points to fix against 0.9 ) Please let me know. Thanks and Regards.
Hi Junny, As this is a new requirement, need to get approval from the management and then needs to be implemented. I will inform you earliest after implementation or when it can be provided. Regards, Sunil Kumar M S
HI Junny, Can we close this thread? Regards, Sunil Kumar M S
Dear Sunil, I have not received an answer of additional linux question yet. After receiving the answer, I will close this thread if there are no further questions. Thanks and Regards, Junny.
Dear Sunil, I have not received an answer of my additional linux question yet. After receiving the answer, I will close this thread if there are no further questions. Thanks and Regards, Junny.
HI junny, What is the additional question you are referring to? Regards, NIkhil D
Dear NIkhil D, As asked in my reply, will the next release version of Linux(version 1.0) be released with the spi code fully included? Additionally, Are you currently working on device tree and congifuration of SPI on Linux? If possible, can you share me device tree and configuration working guide for now? Please let me know your answer. Thanks & Regards, Junny.
Hi Junny, As this SPI is not a standard SPI bus connected to a SPI device, it is rather difficult to verify the Linux driver standlaone. As mentioned, this will be new requirement that needs to be approved and implemented. Unfortunately, I do not have any code / DT changes to share with you. Regards, Nikhil D
Dear Nikhil D, "As this SPI is not a standard SPI bus connected to a SPI device" ==> What does this mean? Is the SPI IP included in TDA4 completely different from the SPI IP included in the TDA2 family or other chips? Comparing the TRM documents seems to use the same SPI IP, isn't it? Please let me know. Thanks and Regards, Junny
Hi Junny, The IP is same, but there is no realy SPI device connected to it, that's why I said it is hard to test in standalone Linux environment, You cannot write a SPI slave driver, because there is none. Nikhil D
Dear Nikhil D, 1. According to the TRM document, MCU_SPI2 and Main_SPI4 are connected internally without pinout. So, I do not understand your comment that there is no realy SPI device connected to it. 2. Currently I have downloaded the 0.9 version of Linux code. 3. I checked the 0.9 Linux code, it seems that the SPI slave driver is included. However, as you said, it requires additional work except SPI driver (DTS, Config ... etc). 4. So, after completing the additional work, I'll try to test by setting MCU_SPI2 as Master (Running RTOS) and Main_SPI4 as Slave (Running Linux). If I do additional work on Linux, such as DTS, Config, etc. I think SPI communication test is possible. Is it wrong? Am I misunderstanding? Please let me know your opinion. Thanks and Regards, Junny
Hi Junny, Yes your understanding is correct and the approach is correct. You just need to program the SPI device in slave mode. There are no pinmux to be set. You can try this out yourself. Regards, NIkhil D
Dear NIkhil D, Thanks for your answer. I will try and If I have further questions, I will contact E2E again. And I will resolve this thread. Best Regards, Junny.