diff options
| author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2011-03-12 08:25:16 +0000 | 
|---|---|---|
| committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2011-03-12 08:25:16 +0000 | 
| commit | 3e8aa7cd6ab42de755f5e873d3775c3d7065a58f (patch) | |
| tree | 7bef5b6d625ad9d660a2bcbca7a1be3d7071c7ec /demos | |
| parent | f81c30406f47c57b8fcbec62ac66b66042eaa23f (diff) | |
| download | ChibiOS-3e8aa7cd6ab42de755f5e873d3775c3d7065a58f.tar.gz ChibiOS-3e8aa7cd6ab42de755f5e873d3775c3d7065a58f.tar.bz2 ChibiOS-3e8aa7cd6ab42de755f5e873d3775c3d7065a58f.zip | |
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2818 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'demos')
| -rw-r--r-- | demos/ARMCM3-STM32F103/readme.txt | 6 | ||||
| -rw-r--r-- | demos/ARMCM3-STM32F107-GCC/Makefile | 2 | ||||
| -rw-r--r-- | demos/ARMCM3-STM32F107-GCC/main.c | 13 | ||||
| -rw-r--r-- | demos/ARMCM3-STM32F107-GCC/mcuconf.h | 10 | ||||
| -rw-r--r-- | demos/ARMCM3-STM32F107-GCC/readme.txt | 9 | 
5 files changed, 21 insertions, 19 deletions
| diff --git a/demos/ARMCM3-STM32F103/readme.txt b/demos/ARMCM3-STM32F103/readme.txt index 5329bfb35..e14bc600f 100644 --- a/demos/ARMCM3-STM32F103/readme.txt +++ b/demos/ARMCM3-STM32F103/readme.txt @@ -10,12 +10,12 @@ The demo runs on an Olimex STM32-P103 board.  The demo flashes the board LED using a thread, by pressing the button located
  on the board the test procedure is activated with output on the serial port
 -COM2 (USART2).
 +SD2 (USART2).
  ** Build Procedure **
 -The demo has been tested by using the free Codesourcery GCC-based toolchain,
 -YAGARTO and an experimental WinARM build including GCC 4.3.0.
 +The demo has been tested by using the free Codesourcery GCC-based toolchain
 +and YAGARTO.
  Just modify the TRGT line in the makefile in order to use different GCC ports.
  ** Notes **
 diff --git a/demos/ARMCM3-STM32F107-GCC/Makefile b/demos/ARMCM3-STM32F107-GCC/Makefile index dc4ebeeeb..9a7631be9 100644 --- a/demos/ARMCM3-STM32F107-GCC/Makefile +++ b/demos/ARMCM3-STM32F107-GCC/Makefile @@ -57,7 +57,7 @@ LDSCRIPT= ch.ld  # Imported source files
  CHIBIOS = ../..
 -include $(CHIBIOS)/boards/ST_STM3210C_EVAL/board.mk
 +include $(CHIBIOS)/boards/OLIMEX_STM32_P107/board.mk
  include $(CHIBIOS)/os/hal/platforms/STM32/platform.mk
  include $(CHIBIOS)/os/hal/hal.mk
  include $(CHIBIOS)/os/ports/GCC/ARMCMx/STM32/port.mk
 diff --git a/demos/ARMCM3-STM32F107-GCC/main.c b/demos/ARMCM3-STM32F107-GCC/main.c index 73bc0b402..418966941 100644 --- a/demos/ARMCM3-STM32F107-GCC/main.c +++ b/demos/ARMCM3-STM32F107-GCC/main.c @@ -22,19 +22,18 @@  #include "test.h"
  /*
 - * Red LED blinker thread, times are in milliseconds.
 + * Green LED blinker thread, times are in milliseconds.
   */
  static WORKING_AREA(waThread1, 128);
  static msg_t Thread1(void *arg) {
    (void)arg;
    while (TRUE) {
 -    palClearPad(IOPORT4, 7);
 +    palClearPad(GPIOC, GPIOC_LED_STATUS1);
      chThdSleepMilliseconds(500);
 -    palSetPad(IOPORT4, 7);
 +    palSetPad(GPIOC, GPIOC_LED_STATUS1);
      chThdSleepMilliseconds(500);
    }
 -  return 0;
  }
  /*
 @@ -55,7 +54,7 @@ int main(void) {    /*
     * Activates the serial driver 2 using the driver default configuration.
     */
 -  sdStart(&SD2, NULL);
 +  sdStart(&SD3, NULL);
    /*
     * Creates the blinker thread.
 @@ -67,8 +66,8 @@ int main(void) {     * sleeping in a loop and check the button state.
     */
    while (TRUE) {
 -    if (palReadPad(IOPORT2, 9) == 0)
 -      TestThread(&SD2);
 +    if (palReadPad(GPIOC, GPIOC_SWITCH_TAMPER) == 0)
 +      TestThread(&SD3);
      chThdSleepMilliseconds(500);
    }
    return 0;
 diff --git a/demos/ARMCM3-STM32F107-GCC/mcuconf.h b/demos/ARMCM3-STM32F107-GCC/mcuconf.h index f3e7ad40b..3c741ceb8 100644 --- a/demos/ARMCM3-STM32F107-GCC/mcuconf.h +++ b/demos/ARMCM3-STM32F107-GCC/mcuconf.h @@ -94,8 +94,8 @@   * SERIAL driver system settings.
   */
  #define STM32_SERIAL_USE_USART1             FALSE
 -#define STM32_SERIAL_USE_USART2             TRUE
 -#define STM32_SERIAL_USE_USART3             FALSE
 +#define STM32_SERIAL_USE_USART2             FALSE
 +#define STM32_SERIAL_USE_USART3             TRUE
  #define STM32_SERIAL_USE_UART4              FALSE
  #define STM32_SERIAL_USE_UART5              FALSE
  #define STM32_SERIAL_USART1_PRIORITY        12
 @@ -107,9 +107,9 @@  /*
   * SPI driver system settings.
   */
 -#define STM32_SPI_USE_SPI1                  TRUE
 -#define STM32_SPI_USE_SPI2                  TRUE
 -#define STM32_SPI_USE_SPI3                  FALSE
 +#define STM32_SPI_USE_SPI1                  FALSE
 +#define STM32_SPI_USE_SPI2                  FALSE
 +#define STM32_SPI_USE_SPI3                  TRUE
  #define STM32_SPI_SPI1_DMA_PRIORITY         2
  #define STM32_SPI_SPI2_DMA_PRIORITY         2
  #define STM32_SPI_SPI3_DMA_PRIORITY         2
 diff --git a/demos/ARMCM3-STM32F107-GCC/readme.txt b/demos/ARMCM3-STM32F107-GCC/readme.txt index 959a23363..f535df8b4 100644 --- a/demos/ARMCM3-STM32F107-GCC/readme.txt +++ b/demos/ARMCM3-STM32F107-GCC/readme.txt @@ -4,15 +4,18 @@  ** TARGET **
 -The demo runs on an ST STM3210C-EVAL board.
 +The demo runs on an Olimex STM32-P107 board.
  ** The Demo **
 +The demo flashes the board LED using a thread, by pressing the button located
 +on the board the test procedure is activated with output on the serial port
 +SD3 (USART3).
  ** Build Procedure **
 -The demo has been tested by using the free Codesourcery GCC-based toolchain,
 -YAGARTO and an experimental WinARM build including GCC 4.3.0.
 +The demo has been tested by using the free Codesourcery GCC-based toolchain
 +and YAGARTO.
  Just modify the TRGT line in the makefile in order to use different GCC ports.
  ** Notes **
 | 
