From 627e6301e01c74834d62b6812cd06f7ec6cfd129 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Wed, 29 Oct 2014 12:31:55 -0600 Subject: [PATCH 1/4] EFM32 Gecko Starter Kit: Calibrate delay loops, update README --- configs/efm32-g8xx-stk/README.txt | 31 +++++++++++++++---- configs/efm32-g8xx-stk/nsh/defconfig | 2 +- .../olimex-efm32g880f128-stk/nsh/defconfig | 2 +- 3 files changed, 27 insertions(+), 8 deletions(-) diff --git a/configs/efm32-g8xx-stk/README.txt b/configs/efm32-g8xx-stk/README.txt index 0f6f3cab55..045861433a 100644 --- a/configs/efm32-g8xx-stk/README.txt +++ b/configs/efm32-g8xx-stk/README.txt @@ -29,13 +29,32 @@ STATUS ====== 2014-10-28. Testing is still in progress. At this point all basic boot - operations are successful: The LEDs work and the application tasks appear - to be successfully started. LED2 is on and LED0 is glowing (meaning that - interrupts are being processed). However, I get no output on PE0. Data - appears to be sent (at least by efm32_lowputc()). However, no signal - activity is present on PE0. + operations are successful: The LEDs work and the application tasks appear + to be successfully started. LED2 is on and LED0 is glowing (meaning that + interrupts are being processed). However, I get no output on PE0. Data + appears to be sent (at least by efm32_lowputc()). However, no signal + activity is present on PE0. - I am, of course, thinking that this is a pin configuration issue. + 2014-10-29: The NuttX is running on the EFM32 Gecko Starter Kit. There + are not many peripherals to test in that configuration, but the NuttShell + (NSH) is working over LEUART0 at 2400 baud (certainly that could go up + to 4800. The documentation says that 9600 is also possible on the + LEUART, but I am not sure how). + + I originally planned to use UART0 at 115200 baud, but I never could get + any output from the board. I reviewd my pin configuration and clocking + carefully and the USART seems to think it is working correctly. So I + am thinking that there is some board issue that prohibits that option + (probably because UART0 is used with the board controller???). Pins + are not available for other U[S]ARTs on the board. + + 2014-10-29: Calibrated the delays loops. + + 2014-10-29: The start-up time is long -- about a second. I have traced + this to the default delay in bringing up the LFCLK in efm32_clockconfig. + The default, reset setting of the LFXOTIMEOUT field of the CMU_CTRL + register is 3 which corresponds to a delay of 32768 cycles, or a full + second. I have not experimented to see if this delay can be reduced. LEDs ==== diff --git a/configs/efm32-g8xx-stk/nsh/defconfig b/configs/efm32-g8xx-stk/nsh/defconfig index a1433dc710..afcc123422 100644 --- a/configs/efm32-g8xx-stk/nsh/defconfig +++ b/configs/efm32-g8xx-stk/nsh/defconfig @@ -192,7 +192,7 @@ CONFIG_ARCH_HAVE_RAMVECTORS=y # # Board Settings # -CONFIG_BOARD_LOOPSPERMSEC=4531 +CONFIG_BOARD_LOOPSPERMSEC=2662 # CONFIG_ARCH_CALIBRATION is not set # diff --git a/configs/olimex-efm32g880f128-stk/nsh/defconfig b/configs/olimex-efm32g880f128-stk/nsh/defconfig index 065e7ffabc..b7a8dd3109 100644 --- a/configs/olimex-efm32g880f128-stk/nsh/defconfig +++ b/configs/olimex-efm32g880f128-stk/nsh/defconfig @@ -189,7 +189,7 @@ CONFIG_ARCH_HAVE_RAMVECTORS=y # # Board Settings # -CONFIG_BOARD_LOOPSPERMSEC=4531 +CONFIG_BOARD_LOOPSPERMSEC=2662 # CONFIG_ARCH_CALIBRATION is not set # From 8247bf3e1c446b463d728d0f7d26cf74d179051c Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Wed, 29 Oct 2014 17:29:21 -0600 Subject: [PATCH 2/4] SAM4E-EK: Fix an error in USART1 pin number --- configs/sam4e-ek/src/sam4e-ek.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configs/sam4e-ek/src/sam4e-ek.h b/configs/sam4e-ek/src/sam4e-ek.h index 25184e5892..ff642b9fc2 100644 --- a/configs/sam4e-ek/src/sam4e-ek.h +++ b/configs/sam4e-ek/src/sam4e-ek.h @@ -304,9 +304,9 @@ */ #define GPIO_RS232_ENABLE (GPIO_OUTPUT | GPIO_CFG_DEFAULT | \ - GPIO_OUTPUT_CLEAR | GPIO_PORT_PIOA | GPIO_PIN21) + GPIO_OUTPUT_CLEAR | GPIO_PORT_PIOA | GPIO_PIN23) #define GPIO_RS485_ENABLE (GPIO_OUTPUT | GPIO_CFG_DEFAULT | \ - GPIO_OUTPUT_SET | GPIO_PORT_PIOA | GPIO_PIN21) + GPIO_OUTPUT_SET | GPIO_PORT_PIOA | GPIO_PIN23) /* HSMCI SD Card Detect * From 6090a5a461798d12777351903b7218ebf67e9451 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Thu, 30 Oct 2014 06:56:30 -0600 Subject: [PATCH 3/4] Documentation Update --- configs/efm32-g8xx-stk/README.txt | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/configs/efm32-g8xx-stk/README.txt b/configs/efm32-g8xx-stk/README.txt index 045861433a..b9177207fb 100644 --- a/configs/efm32-g8xx-stk/README.txt +++ b/configs/efm32-g8xx-stk/README.txt @@ -28,12 +28,12 @@ CONTENTS STATUS ====== - 2014-10-28. Testing is still in progress. At this point all basic boot - operations are successful: The LEDs work and the application tasks appear - to be successfully started. LED2 is on and LED0 is glowing (meaning that - interrupts are being processed). However, I get no output on PE0. Data - appears to be sent (at least by efm32_lowputc()). However, no signal - activity is present on PE0. + 2014-10-28. At this point all basic boot operations are successful: The + LEDs work and the application tasks appear to be successfully started. + LED2 is on and LED0 is glowing (meaning that interrupts are being + processed). However, I get no output on PE0. Data appears to be sent + (at least by efm32_lowputc()). However, no signal activity is present + on PE0. 2014-10-29: The NuttX is running on the EFM32 Gecko Starter Kit. There are not many peripherals to test in that configuration, but the NuttShell From 138114dfd5acd50d5989b3b8376f0e7e2cca1830 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Thu, 30 Oct 2014 06:57:43 -0600 Subject: [PATCH 4/4] Remove some dangling whitespace --- configs/efm32-g8xx-stk/README.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configs/efm32-g8xx-stk/README.txt b/configs/efm32-g8xx-stk/README.txt index b9177207fb..ade1f7c6e9 100644 --- a/configs/efm32-g8xx-stk/README.txt +++ b/configs/efm32-g8xx-stk/README.txt @@ -29,7 +29,7 @@ STATUS ====== 2014-10-28. At this point all basic boot operations are successful: The - LEDs work and the application tasks appear to be successfully started. + LEDs work and the application tasks appear to be successfully started. LED2 is on and LED0 is glowing (meaning that interrupts are being processed). However, I get no output on PE0. Data appears to be sent (at least by efm32_lowputc()). However, no signal activity is present