![]() |
Kinetis SDK v.1.2 Demo Applications User's Guide
Rev. 0
Freescale Semiconductor, Inc.
|
#include <stdio.h>
#include "board.h"
#include "fsl_flexio_spi_driver.h"
#include "fsl_clock_manager.h"
#include "fsl_debug_console.h"
#include "fsl_spi_slave_driver.h"
Macros | |
#define | COMM_SPI_SLAVE |
Functions | |
static uint32_t | spi_compare_sink_source (uint8_t *source, uint8_t *sink, uint16_t count) |
static void | flexio_spi_reset_buffer (uint8_t *txBuff, uint32_t count) |
static void | master_slave_transfer_int (void) |
static void | master_slave_transfer_dma (void) |
int | main (void) |
Function prototype for main function. More... | |
Variables | |
static uint32_t | s_flexioInstance |
flexio_spi_state_t | masterState |
static uint8_t | s_masterReadBuffer [20] |
static uint8_t | s_slaveReadBuffer [20] |
static uint8_t | s_masterWriteBuffer [20] |
static uint8_t | s_slaveWriteBuffer [20] |
#define COMM_SPI_SLAVE |
|
static |
int main | ( | void | ) |
Function prototype for main function.
Function prototype for main function.
This function used the input of user as trigger to start the measurement. When user press any key, the conversion will begin, then print converted value and current temperature of the chip.
Function prototype for main function.
Run a simple application which enables watchdog, then continuously refreshes the watchdog to prevent CPU reset Upon SW1 button push, the watchdog will expire after approximately 1 seconds and chip will reset.
Function prototype for main function.
This function uses terminal to enter DAC value and convert this value to DAC output.
Function prototype for main function.
This function use DMA peripheral to transfer two buffers
Function prototype for main function.
Thid function uses DSPI master to send an array to slave and receive the array back from slave, thencompare whether the two buffers are the same.
Function prototype for main function.
This function sends back received buffer from master through DSPI interface.
Function prototype for main function.
This function sends an array through DSPI loopback interface and compare it with received buffer whether they are the same.
Function prototype for main function.
This function use EDMA peripheral to transfer two buffers
Function prototype for main function.
This function use EWM as a watchdog for an external circuit. when the counter reaches high value, EWM enter interrupt.
Function prototype for main function.
This function uses SSD to demonstrate flash mode:
receiveBuff | Buffer used to hold received data |
Return code from each SSD function
Address of the target location
Return protection status
Number of longword or phrase to be verified
0=normal, 1=user, 2=factory - margin read for reading
|
static |
|
static |
|
static |
flexio_spi_state_t masterState |
|
static |
|
static |
|
static |
|
static |
|
static |