Quantcast
Channel: Microcontrollers
Viewing all articles
Browse latest Browse all 216474

Forum Post: RE: Clock Multiplier for the MSP430 FRAM series

$
0
0

[quote user="dauletle"]

Are you saying that in my scenario, there is no need to use the DMA? I can tinker with the software so that there is a change on making the algorithms more efficient, but want to make sure that the peripheral clock cannot speed up any quicker than the 24 MHz.

[/quote]

SPI can be clocked (UCSSELx)  by ACLK / SMCLK, and for going over 24 MHz you must set ACLK / SMCLK over this value. But there is no need for this because in your case problem is code, not slow peripheral. You must design system on this way that it must be able to receive any time any numbers of bytes (highest priority) without possibility that receiving side can be interrupted with something else. This can be done with simple 256 bytes (RAM) circular RX buffer, that will be handled in ISR (case 2). Processing received data must work In background without interrupting RX side.

If you want to send for example 20 (fixed, known len in advance) bytes that are stored somewhere in memory over SPI, in this case DMA will be the best choice. But on RX side, when you don't know how many bytes will be received, and they must be stored in circular buffer or something like this, DMA will not improve anything over standard RX ISR.


Viewing all articles
Browse latest Browse all 216474

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>