Hello,
I'm just beginning to work with KL25Z and the beginning is quite difficult. I work with Kinetis DesignStudio.
My program has to received order via serial connection, but also makes different things. On my arduino UNO32, I had just to test a flag to know that a byte is ready to be read, or better an interrupt, but with the KL25Z, I don't knnow how to do that. My first idea was to use the Serial_LDD component, but there is no event for 'byte ready to be read'. Have you a simple solution?
Thanks
Michel
You can use the OnBlockReceived() event for this. But I recommend that you probably better use the AsynchroSerial component which is easier to use, and has as well an OnRxChar() event you could use.
If you are not sure how to use the events and methods: there is help available, see Getting Help on Processor Expert Components | MCU on Eclipse
I hope this helps,
Erich
Michel
The Serial_LDD component probably has a callback - it may be dummy and need to be filled out.
For the KL25 and KDS you can however get an optimised solution at this link: http://www.utasker.com/kinetis/FRDM-KL25Z.html
Your task will be scheduled on any UART reception and it allows you to use interrupt or DMA modes.
The UART interface is documented at http://www.utasker.com/docs/uTasker/uTaskerUART.PDF. The complete operation (including interrupts and DMA) can be simulated in the uTasker KL25 simulator in approx. real-time so you can monitor the peripheral operation and develop and test the software with a UART peer without needing any hardware.
Using the same interface (as UART) you can also communication over USB-CDC or operate in USB-CDC to UART bridge mode.
Regards
Mark