aboutsummaryrefslogtreecommitdiffstats
path: root/testhal/SPC563Mxx/SPI
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2013-03-27 13:40:49 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2013-03-27 13:40:49 +0000
commit0a69d7dd419e1d0925c02a7b621e72e44d8c25bb (patch)
tree8b70dfe8c2061186f1511f9a940f9260a18e0b2f /testhal/SPC563Mxx/SPI
parent72fee26a32402aea500c0a925021694f0bb18776 (diff)
downloadChibiOS-0a69d7dd419e1d0925c02a7b621e72e44d8c25bb.tar.gz
ChibiOS-0a69d7dd419e1d0925c02a7b621e72e44d8c25bb.tar.bz2
ChibiOS-0a69d7dd419e1d0925c02a7b621e72e44d8c25bb.zip
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@5508 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'testhal/SPC563Mxx/SPI')
-rw-r--r--testhal/SPC563Mxx/SPI/Makefile2
-rw-r--r--testhal/SPC563Mxx/SPI/main.c4
2 files changed, 5 insertions, 1 deletions
diff --git a/testhal/SPC563Mxx/SPI/Makefile b/testhal/SPC563Mxx/SPI/Makefile
index 2cef7b38c..c52b0f44a 100644
--- a/testhal/SPC563Mxx/SPI/Makefile
+++ b/testhal/SPC563Mxx/SPI/Makefile
@@ -5,7 +5,7 @@
# Compiler options here.
ifeq ($(USE_OPT),)
- USE_OPT = -O2 -ggdb -fomit-frame-pointer -falign-functions=16
+ USE_OPT = -O0 -ggdb -fomit-frame-pointer -falign-functions=16
endif
# C specific options here (added to USE_OPT).
diff --git a/testhal/SPC563Mxx/SPI/main.c b/testhal/SPC563Mxx/SPI/main.c
index 9ddb9761a..23ccd435a 100644
--- a/testhal/SPC563Mxx/SPI/main.c
+++ b/testhal/SPC563Mxx/SPI/main.c
@@ -119,6 +119,10 @@ int main(void) {
for (i = 0; i < sizeof(txbuf); i++)
txbuf[i] = (uint8_t)i;
+ spiStart(&SPID2, &hs_spicfg); /* Setup transfer parameters. */
+ spiExchange(&SPID2, 512,
+ txbuf, rxbuf); /* Atomic transfer operations. */
+
/*
* Starting the transmitter and receiver threads.
*/