From a720f71ab84c363f04e04b058c82386f510153e5 Mon Sep 17 00:00:00 2001 From: patacongo Date: Sat, 1 Nov 2008 16:12:09 +0000 Subject: [PATCH] Added ST71x system timer logic git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@1115 42af7a65-404d-4744-a932-0658087f49c3 --- configs/olimex-strp711/ostest/defconfig | 2 +- configs/olimex-strp711/src/up_buttons.c | 6 +++--- configs/olimex-strp711/src/up_leds.c | 8 ++++---- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/configs/olimex-strp711/ostest/defconfig b/configs/olimex-strp711/ostest/defconfig index e310f54fe5..1ff1ad1c0c 100644 --- a/configs/olimex-strp711/ostest/defconfig +++ b/configs/olimex-strp711/ostest/defconfig @@ -108,7 +108,7 @@ CONFIG_STR71X_BSPI1=n CONFIG_STR71X_HDLC=n CONFIG_STR71X_XTI=n CONFIG_STR71X_GPIO0=y -CONFIG_STR71X_GPIO1=n +CONFIG_STR71X_GPIO1=y CONFIG_STR71X_GPIO2=n CONFIG_STR71X_ADC12=n CONFIG_STR71X_CKOUT=n diff --git a/configs/olimex-strp711/src/up_buttons.c b/configs/olimex-strp711/src/up_buttons.c index 2ee386daaa..108a5831cb 100644 --- a/configs/olimex-strp711/src/up_buttons.c +++ b/configs/olimex-strp711/src/up_buttons.c @@ -82,15 +82,15 @@ void up_buttoninit(void) /* Configure the GPIO pins as inputs */ reg16 = getreg16(STR71X_GPIO1_PC0); - reg16 |= STR71X_BOTHBUTTONS_GPIO1 + reg16 |= STR71X_BOTHBUTTONS_GPIO1; putreg16(reg16, STR71X_GPIO1_PC0); reg16 = getreg16(STR71X_GPIO1_PC1); - reg16 &= ~STR71X_BOTHBUTTONS_GPIO1 + reg16 &= ~STR71X_BOTHBUTTONS_GPIO1; putreg16(reg16, STR71X_GPIO1_PC1); reg16 = getreg16(STR71X_GPIO1_PC2); - reg16 &= ~STR71X_BOTHBUTTONS_GPIO1 + reg16 &= ~STR71X_BOTHBUTTONS_GPIO1; putreg16(reg16, STR71X_GPIO1_PC2); } diff --git a/configs/olimex-strp711/src/up_leds.c b/configs/olimex-strp711/src/up_leds.c index 873994c68c..a5719d5f99 100644 --- a/configs/olimex-strp711/src/up_leds.c +++ b/configs/olimex-strp711/src/up_leds.c @@ -106,21 +106,21 @@ void up_ledinit(void) /* Set normal function output */ reg16 = getreg16(STR71X_GPIO1_PC0); - reg16 |= STR71X_LEDGPIO1_BITS + reg16 |= STR71X_LEDGPIO1_BITS; putreg16(reg16, STR71X_GPIO1_PC0); reg16 = getreg16(STR71X_GPIO1_PC1); - reg16 &= ~STR71X_LEDGPIO1_BITS + reg16 &= ~STR71X_LEDGPIO1_BITS; putreg16(reg16, STR71X_GPIO1_PC1); reg16 = getreg16(STR71X_GPIO1_PC2); - reg16 |= STR71X_LEDGPIO1_BITS + reg16 |= STR71X_LEDGPIO1_BITS; putreg16(reg16, STR71X_GPIO1_PC2); /* Clear the LEDs (1 clears; 0 sets) */ reg16 = getreg16(STR71X_GPIO1_PD); - reg16 |= STR71X_LEDGPIO1_BITS + reg16 |= STR71X_LEDGPIO1_BITS; putreg16(reg16, STR71X_GPIO1_PD); }