Please see the Getting Started Guide for " System_printf("This example requires external wires to be connected to the " * SysMin will only print to the console when you call flush or exit */ Halt the target to view any SysMin contents in ROV.\n") System_printf("Starting the SPI loop-back example\nSystem provider is set to" Task_construct(&task1Struct, (Task_FuncPtr)slaveTaskFxn, &taskParams, NULL) Task_construct(&task0Struct, (Task_FuncPtr)masterTaskFxn, &taskParams, NULL) * Construct master/slave Task threads */ System_printf("Unsuccessful master SPI transfer")
System_printf("Master: %s\n", masterRxBuffer) * Print contents of master receive buffer */ TransferOK = SPI_transfer(masterSpi, &masterTransaction) MasterTransaction.rxBuf = (Ptr)masterRxBuffer MasterTransaction.txBuf = (Ptr)masterTxBuffer * Initialize master SPI transaction structure */ * Initialize SPI handle as default master */ Void masterTaskFxn (UArg arg0, UArg arg1) * Master SPI sends a message to slave and also * task to ensure it is ready for a transaction. * This task runs at a lower priority after the slave System_printf("Unsuccessful slave SPI transfer") System_printf("Slave: %s\n", slaveRxBuffer) * Print contents of slave receive buffer */ TransferOK = SPI_transfer(slaveSpi, &slaveTransaction) SlaveTransaction.rxBuf = (Ptr)slaveRxBuffer SlaveTransaction.txBuf = (Ptr)slaveTxBuffer * Initialize slave SPI transaction structure */ System_abort("Error initializing SPI\n") SlaveSpi = SPI_open(Board_SPI1, &slaveSpiParams) * Initialize SPI handle with slave mode */ * message to master and also receives message from * This task runs on a higher priority, since slave Unsigned char slaveTxBuffer = "Hello, this is slave SPI1234" Unsigned char masterTxBuffer = "Hello, this is master SPI1234" if i add a "while loop", can it work continuously?Ĭhar task0Stack, task1Stack Q: Is there a simpler example you can recommend?
It works and i add my oscilloscope-screenshots | PD3->PQ0, PD2->PQ1, PD0->PQ2, PD1->PQ3 and the spiloopback works.ĪDS input frequency is 16MHz and output (DOUT) frequency is about 130kHz. I build like the jumper wire connections are needed for the external SPI loopback example. spiloopback.h is working on the EK-TM4C1294XL but I can not read any data from ADS127L01EVM. With these parts, I'm making ADC and I want to read with EK-TM4C1294XL (SPI) than I want to send It to the CAN line.
Upointer registration code code#
I'm using EK-TM4C1294XL via Code Composer Studio Version: 8.4 and spiloopback.