summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (from parent 1: af2c893)
raw | patch | inline | side by side (from parent 1: af2c893)
author | Frank Livingston <frank-livingston@ti.com> | |
Tue, 15 Nov 2016 22:56:48 +0000 (16:56 -0600) | ||
committer | Frank Livingston <frank-livingston@ti.com> | |
Tue, 15 Nov 2016 22:56:48 +0000 (16:56 -0600) |
pasdk/paf | patch | blob | history | |
pasdk/test_dsp/application/itopo/evmk2g/dcs7_params.c | patch | blob | history |
diff --git a/pasdk/paf b/pasdk/paf
index 5ed78e836c22eb6437d1f3c5da607f448ce1b2f1..28e3c506be967e25db31e1ba651c22a77ab848e1 160000 (submodule)
--- a/pasdk/paf
+++ b/pasdk/paf
-Subproject commit 5ed78e836c22eb6437d1f3c5da607f448ce1b2f1
+Subproject commit 28e3c506be967e25db31e1ba651c22a77ab848e1
diff --git a/pasdk/test_dsp/application/itopo/evmk2g/dcs7_params.c b/pasdk/test_dsp/application/itopo/evmk2g/dcs7_params.c
index a29bad0aa9051ee859818ba95aa8baaa7c102fa4..c1d6aa47e34a9421e2a1a1d826fd80706d4c3816 100644 (file)
-/*
-Copyright (c) 2016, Texas Instruments Incorporated - http://www.ti.com/
-All rights reserved.
-
-* Redistribution and use in source and binary forms, with or without
-* modification, are permitted provided that the following conditions
-* are met:
-*
-* Redistributions of source code must retain the above copyright
-* notice, this list of conditions and the following disclaimer.
-*
-* Redistributions in binary form must reproduce the above copyright
-* notice, this list of conditions and the following disclaimer in the
-* documentation and/or other materials provided with the
-* distribution.
+/******************************************************************************
+* Copyright (c) 2016, Texas Instruments Incorporated - http://www.ti.com
+* All rights reserved.
*
-* Neither the name of Texas Instruments Incorporated nor the names of
-* its contributors may be used to endorse or promote products derived
-* from this software without specific prior written permission.
+* Redistribution and use in source and binary forms, with or without
+* modification, are permitted provided that the following conditions are met:
+* * Redistributions of source code must retain the above copyright
+* notice, this list of conditions and the following disclaimer.
+* * Redistributions in binary form must reproduce the above copyright
+* notice, this list of conditions and the following disclaimer in the
+* documentation and/or other materials provided with the distribution.
+* * Neither the name of Texas Instruments Incorporated nor the
+* names of its contributors may be used to endorse or promote products
+* derived from this software without specific prior written permission.
*
-* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-*
-*/
+* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+* THE POSSIBILITY OF SUCH DAMAGE.
+*****************************************************************************/
//
//
void *buffer, size_t count);
#endif
+#ifdef SPICALLBACK
+extern void SPI_transferCallback(UART_Handle handle,
+ void *buffer, size_t count);
+#endif
+
+/* SPI parameters structure Slave mode*/
+SPI_Params spiParams =
+{
+#ifdef SPICALLBACK
+ SPI_MODE_CALLBACK, /* transferMode */
+#else
+ SPI_MODE_BLOCKING, /* transferMode */
+#endif
+ Semaphore_PendState_WAIT_FOREVER, /* transferTimeout */
+#ifdef SPICALLBACK
+ &SPI_transferCallback,
+#else
+ NULL, /* transferCallbackFxn */
+#endif
+ SPI_SLAVE, /* mode */
+ 1000000, /* bitRate */
+ 8, /* dataSize */
+ SPI_POL0_PHA0, /* frameFormat */
+ NULL /* custom */
+};
const DCS7_Params_Dev_Spi DCS7_PARAMS_DEV_SPI =
{
- sizeof(DCS7_Params_Dev_Spi)
+ sizeof(DCS7_Params_Dev_Spi),
+ NULL,
+ &spiParams,
+ {0, NULL, NULL, NULL}
};
const DCS7_Params_Dev_I2c DCS7_PARAMS_DEV_I2C =
{
sizeof(DCS7_Params_Dev_I2c),
+ NULL,
+ {I2C_MODE_BLOCKING, NULL, I2C_100kHz, NULL, I2C_SLAVE},
+ {NULL, 0, NULL, 0, 0, NULL, NULL},
+ 0x11
};
const DCS7_Params_Dev_Uart DCS7_PARAMS_DEV_UART =
{
sizeof(DCS7_Params_Dev_Uart),
- 0, // xrxSize
- 0, // xrxHwm
- 0, // xrxLwm
- 0, // xtxSize
0, // emask
NULL, // hUart
#ifdef UARTCALLBACK
#endif
0, // isEMDAConfigured
SRECORD_RES_MAX_S1_CNT * 72 /*ASCII_SRECORD_S1_MAX_SIZE*/, // scratchBufSize
- NULL // scratchBuf
+ NULL, // scratchBuf
+ {0}, // uartParams
+ 19200
};
const DCS7_Params_Dev DCS7_PARAMS_DEV =
sizeof(DCS7_Params),
/* DCS7 supports following values for device (dev):
DCS7_PARAMS_DEV_SPI0 - SPI0 device
- DCS7_PARAMS_DEV_SPI1 - SPI1 device
DCS7_PARAMS_DEV_I2C0 - I2C0 device
- DCS7_PARAMS_DEV_I2C1 - I2C1 device
DCS7_PARAMS_DEV_UART0 - UART0 device */
DCS7_PARAMS_DEV_UART0,
- /* DCS7 supports following values for (psfil):
- DCS7_PARAMS_PSFIL_ENA - enable processing zero fill
- DCS7_PARAMS_PSFIL_DIS - disable processing zero fill */
- DCS7_PARAMS_PSFIL_DIS,
- /* DCS7 supports following values for processing slc (pslc):
- DCS7_PARAMS_PSLC_DIS - disable processing slc
- DCS7_PARAMS_PSLC_ENA - enable processing slc */
- DCS7_PARAMS_PSLC_ENA,
/* DCS7 supports following values for error detection and report (edr):
DCS7_PARAMS_EDR_DIS - disable error detection and report
DCS7_PARAMS_EDR_ENA - enable error detection and report */
/* DCS7 device parameters */
(DCS7_Params_Dev*)&DCS7_PARAMS_DEV,
/* DCS7 log param */
- (Void*) &DCS7Trace,
+ (void*) &DCS7Trace,
};
void DCS7_errorInit()