summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-01-08 16:44:11 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-01-08 16:44:11 -0600
commit01a308f4d82c4220e2655ed9b389c3ce12e82523 (patch)
treec9e8ab2d551697eaed482f0f80373aee5b020fb4
parent2ff750fb0fafdfa1fa2ea674ef962f70e40e402b (diff)
downloadpx4-nuttx-01a308f4d82c4220e2655ed9b389c3ce12e82523.tar.gz
px4-nuttx-01a308f4d82c4220e2655ed9b389c3ce12e82523.tar.bz2
px4-nuttx-01a308f4d82c4220e2655ed9b389c3ce12e82523.zip
Fix STM32F103VE SPI3 definitions; Fix bug introduced in recent NX reorganization. From Steve Redler IV
-rw-r--r--nuttx/ChangeLog5
-rw-r--r--nuttx/arch/arm/include/stm32/chip.h2
-rw-r--r--nuttx/arch/arm/src/stm32/chip/stm32f103ze_pinmap.h5
-rw-r--r--nuttx/graphics/nxsu/Make.defs2
4 files changed, 12 insertions, 2 deletions
diff --git a/nuttx/ChangeLog b/nuttx/ChangeLog
index ef93b992c..5352a1857 100644
--- a/nuttx/ChangeLog
+++ b/nuttx/ChangeLog
@@ -6393,4 +6393,9 @@
* libc/stdio/lib_libfgets.c: Common implementation supports all
of the slightly different requirements of gets(), gets_s(), and
fgets() (2014-1-7).
+ * arch/arm/include/stm32/chip.h and chip/stm32f103ze_pinmap.h:
+ various fixes for STM32F103ZE SPI3. From Steve Redler IV
+ (2014-1-7).
+ * graphics/nxsu/Make.defs: Typo that crept into build in recent
+ NX reorganization. Found by Steve Redler IV (2014-1-7).
diff --git a/nuttx/arch/arm/include/stm32/chip.h b/nuttx/arch/arm/include/stm32/chip.h
index 12fb73f7c..183dfb0aa 100644
--- a/nuttx/arch/arm/include/stm32/chip.h
+++ b/nuttx/arch/arm/include/stm32/chip.h
@@ -683,7 +683,7 @@
# define STM32_NGTIM 4 /* 16-bit generall timers TIM2,3,4,5 with DMA */
# define STM32_NBTIM 0 /* No basic timers */
# define STM32_NDMA 2 /* DMA1-2 */
-# define STM32_NSPI 2 /* SPI1-2 */
+# define STM32_NSPI 3 /* SPI1-3 */
# define STM32_NI2S 0 /* No I2S (?) */
# define STM32_NUSART 3 /* USART1-3 */
# define STM32_NI2C 2 /* I2C1-2 */
diff --git a/nuttx/arch/arm/src/stm32/chip/stm32f103ze_pinmap.h b/nuttx/arch/arm/src/stm32/chip/stm32f103ze_pinmap.h
index 581b026a0..df1edbe75 100644
--- a/nuttx/arch/arm/src/stm32/chip/stm32f103ze_pinmap.h
+++ b/nuttx/arch/arm/src/stm32/chip/stm32f103ze_pinmap.h
@@ -325,6 +325,11 @@
# define GPIO_SPI1_MOSI (GPIO_ALT|GPIO_CNF_AFPP|GPIO_MODE_50MHz|GPIO_PORTA|GPIO_PIN7)
#endif
+# define GPIO_SPI2_NSS (GPIO_INPUT|GPIO_CNF_INFLOAT|GPIO_MODE_INPUT|GPIO_PORTB|GPIO_PIN12)
+# define GPIO_SPI2_SCK (GPIO_ALT|GPIO_CNF_AFPP|GPIO_MODE_50MHz|GPIO_PORTB|GPIO_PIN13)
+# define GPIO_SPI2_MISO (GPIO_INPUT|GPIO_CNF_INFLOAT|GPIO_MODE_INPUT|GPIO_PORTB|GPIO_PIN14)
+# define GPIO_SPI2_MOSI (GPIO_ALT|GPIO_CNF_AFPP|GPIO_MODE_50MHz|GPIO_PORTB|GPIO_PIN15)
+
#if defined(CONFIG_STM32_SPI3_REMAP)
# define GPIO_SPI3_NSS (GPIO_INPUT|GPIO_CNF_INFLOAT|GPIO_MODE_INPUT|GPIO_PORTA|GPIO_PIN4)
# define GPIO_SPI3_SCK (GPIO_ALT|GPIO_CNF_AFPP|GPIO_MODE_50MHz|GPIO_PORTC|GPIO_PIN10)
diff --git a/nuttx/graphics/nxsu/Make.defs b/nuttx/graphics/nxsu/Make.defs
index 93abe9d81..26e2f090c 100644
--- a/nuttx/graphics/nxsu/Make.defs
+++ b/nuttx/graphics/nxsu/Make.defs
@@ -40,5 +40,5 @@ NX_CSRCS += nx_filltrapezoid.c nx_getposition.c nx_getrectangle.c nx_kbdchin.c
NX_CSRCS += nx_kbdin.c nx_lower.c nx_mousein.c nx_move.c nx_open.c
NX_CSRCS += nx_openwindow.c nx_raise.c nx_redrawreq.c nx_releasebkgd.c
NX_CSRCS += nx_requestbkgd.c nx_setpixel.c nx_setsize.c nx_setbgcolor.c
-NX_CSRCS += nx_setposition.c nxsu_constructwindow.c nxsu_redrawreq.c
+NX_CSRCS += nx_setposition.c nx_constructwindow.c nxsu_redrawreq.c
NX_CSRCS += nxsu_reportposition.c