diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2009-06-02 13:41:38 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2009-06-02 13:41:38 +0000 |
commit | 2a7941ee58016ce7641ab8010aff5fe711e0bedc (patch) | |
tree | 4ac467770e31cbf9245936b998d47e0809bf28b7 /demos/ARM7-LPC214x-GCC/mmcsd.c | |
parent | 1aa2773ad03807e3d5c9822ea108bc2e280281db (diff) | |
download | ChibiOS-2a7941ee58016ce7641ab8010aff5fe711e0bedc.tar.gz ChibiOS-2a7941ee58016ce7641ab8010aff5fe711e0bedc.tar.bz2 ChibiOS-2a7941ee58016ce7641ab8010aff5fe711e0bedc.zip |
I/O port driver for LPC214x added.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@1016 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'demos/ARM7-LPC214x-GCC/mmcsd.c')
-rw-r--r-- | demos/ARM7-LPC214x-GCC/mmcsd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/demos/ARM7-LPC214x-GCC/mmcsd.c b/demos/ARM7-LPC214x-GCC/mmcsd.c index 292b450d5..bff2967d9 100644 --- a/demos/ARM7-LPC214x-GCC/mmcsd.c +++ b/demos/ARM7-LPC214x-GCC/mmcsd.c @@ -19,7 +19,7 @@ #include <ch.h>
-#include "lpc214x.h"
+#include "board.h"
#include "lpc214x_ssp.h"
#include "mmcsd.h"
@@ -42,7 +42,7 @@ void InitMMC(void) { void tmrfunc(void *par) {
if (cnt) {
- if (!(IO1PIN & (1 << 25))) {
+ if (!(chPortRead(IOPORT_B) & PB_CP1)) {
if (!--cnt)
chEvtBroadcastI(&MMCInsertEventSource);
}
@@ -50,7 +50,7 @@ void tmrfunc(void *par) { cnt = POLLING_INTERVAL;
}
else {
- if (IO1PIN & (1 << 25)) {
+ if (chPortRead(IOPORT_B) & PB_CP1) {
cnt = POLLING_INTERVAL;
chEvtBroadcastI(&MMCRemoveEventSource);
}
|