Hello
Previously, I devellop project with codewarrior and KDS on K60/K70.
Today, I start a new project with K02 and then, Start with the new tools, Then MCUExpresso.
In it, I download the SDK for the K02, add some driver, middleware etc..
I configured my CPU, code "hello word" compile with some remark.
Many question:
1) The PRINTF("Hello word") is not recognized. Which component do I add to be taken?
2) I use the Spi, Then I Add the spi_adapter.
The DSPI_MasterInit is called from the generated file "Peripheral.c" => Ok
Now, I read the HAL dspi_adapter. If I want use it, there are a function HAL_SpiMasterInit which will call also DSPI_MasterInit… Then there is exemple code to use all the driver and HAL? with API detail, exemple code etc... I not find it!
3) The main function fall in infinite loop, then this is redundant with previous question, but I add timer / timer_manager. It seem with this I can configure and start some task. there is exemple? My need is to create some task, with different period and priority..
4) UART driver: how use the function LIN break detection? (may be response is in SDK documentation I asked in question 1?...)
Thank
已解决! 转到解答。
Hi,
Please check the following document and let me know if that is what you need.
https://community.nxp.com/docs/DOC-334074
Regards
Soledad
Hi,
Did you create a new project? or Did you import a project?
Please check the following document and let me know if this helps with your questions:
https://community.nxp.com/docs/DOC-334074
Regarding the SPI example code, after download the sdk for k02, you can find the DSPI examples at the following path:
\SDK_2.7.0_MK02FN128xxx10.zip\boards\frdmk22f\driver_examples
In addition, I am attaching the MCUXpresso SDK API Reference Manual_MK22
Please let me know if this helps,
have a nice day!
Regards
Soledad
Hello
I start new project from scratch
-Which module exactly must I add to have the "PrintF" function?
-For the UART module, I think the C code is designed to configure the BreakLin Dtetection, but the MCU expresso IDE do not allow to activate this option. I'm right?
Alos, If I understand, If I use the UART_Adpater, I mudt not configure into MCUExpresso peripheral the UART? (Because It will init by the UART_adapter) I'm Right?
Hi,
Please follow the below steps:
1. Click on New project
2. Select the MCU from installed SDK, click Next
3. In project, Options select UART and add the uart driver
4. Select Redirect SDK "PRINTF" to C library "printf", then click Finish
5. At this point, you should be able to use printf.
Please check the fsl_uart.h
You will find the structure with the settings for all of the UART interrupt configurations.
I hope this helps, have a nice day !
Regards
Soledad
Hello,
Thank for the information about the Printf. But now, when the project is already existing, how set this functionnality?
For the LinBreak, it is what I said. The Break Lin interrupt detection is on the c code, but on the MCUXpresso, it is not ?