Documentation: migrate STM32F4

This commit is contained in:
raiden00pl
2023-08-23 10:22:31 +02:00
committed by Alan Carvalho de Assis
parent 0953d0cbb5
commit 00db279c00
34 changed files with 7626 additions and 8496 deletions
@@ -1,5 +1,6 @@
README
======
=======
Axoloti
=======
This README discusses issues unique to NuttX configurations for the
Axoloti open source synthesizer board featuring the STM32F427IGH6
@@ -0,0 +1,372 @@
==============
mikroe-stm32f4
==============
This README discusses issues unique to NuttX configurations for the
MikroElektronika Mikromedia for STM32F4 development board. This is
another board support by NuttX that uses the same STM32F407VGT6 MCU
as does the STM32F4-Discovery board. This board, however, has very
different on-board peripherals than does the STM32F4-Discovery:
- TFT display with touch panel,
- VS1053 stereo audio codec with headphone jack,
- SD card slot,
- Serial FLASH memory,
- USB OTG FS with micro-AB connector, and
- Battery connect and batter charger circuit.
See the http://www.mikroe.com/mikromedia/stm32-m4/ for more information
about this board.
LEDs
====
The Mikroe-STM32F4 board has no user accessible LEDs onboard, only a power
and "charging" LED. All visual user output must be performed through the TFT
display.
External LEDs could be added via the expansion headers on the side of the
board, but as this would be a custom configuration, LEDs are not supported
in this port.
PWM
===
The Mikroe-STM32F4 has no real on-board PWM devices, but it does have PWM
pins routed to the expansion I/O headers on the side of the board.
UARTs
=====
The Mikroe-STM32F4 board has no onboard RS-232 line driver, however the
expansion I/O header provides access to USART2 on pins PD5/PD6. The port
includes support for USART2 configured as /dev/ttyS0.
USART2
------
========== =====
UART/USART PINS
========== =====
RX PD6
TX PD5
========== =====
Default USART/UART Configuration
--------------------------------
USART2 is enabled in all configurations (see \*/defconfig). RX and TX are
configured on pins PD6 and PD5, respectively (see include/board.h).
Timer Inputs/Outputs
====================
::
TIM1
CH1 PA8, PE9
CH2 PA9[1], PE11
CH3 PA10[1], PE13
CH4 PA11[1], PE14
TIM2
CH1 PA0[1], PA15, PA5[1]
CH2 PA1, PB3[1]
CH3 PA2, PB10[1]
CH4 PA3, PB11
TIM3
CH1 PA6[1], PB4, PC6
CH2 PA7[1], PB5, PC7[1]
CH3 PB0, PC8
CH4 PB1, PC9
TIM4
CH1 PB6[1], PD12[1]
CH2 PB7, PD13[1]
CH3 PB8, PD14[1]
CH4 PB9[1], PD15[1]
TIM5
CH1 PA0[1], PH10[2]
CH2 PA1, PH11[2]
CH3 PA2, PH12[2]
CH4 PA3, PI0
TIM8
CH1 PC6, PI5
CH2 PC7[1], PI6
CH3 PC8, PI7
CH4 PC9, PI2
TIM9
CH1 PA2, PE5
CH2 PA3, PE6
TIM10
CH1 PB8, PF6
TIM11
CH1 PB9[1], PF7
TIM12
CH1 PH6[2], PB14
CH2 PC15, PH9[2]
TIM13
CH1 PA6[1], PF8
TIM14
CH1 PA7[1], PF9
[1] Indicates pins that have other on-board functions and should be used only
with care (See table 5 in the Mikroe-STM32F4 User Guide). The rest are
free I/O pins.
[2] Port H pins are not supported by the MCU
MIO283QT-2/MIO283QT-9A
======================
The original Mikroe-SMT32F4 board as an on-board MIO283QT-2 TFT LCD that can
be configured and used. This is a 320x240 resolution display with color
capability to 262K colors, though the mio283qt-2 driver in NuttX only
supports 16-bit color depth, or 65K colors. Changes to both the
mio283qt-2 driver and the driver interface layer would need to be made
to support 24 BPP mode.
UPDATE: New boards now support a MIO283QT-9A TFT LCD that is not compatible
with the MIO283QT-2. It uses a different LCD controller. The default in
all of these configurations is the MIO283QT-2. But MIO283QT-9A is also
supported and you can switch from the MIO283QT-2 to the MIO283QT-9A by simply
modifying the NuttX configuration
Configurations
==============
Each Mikroe-STM32F4 configuration is maintained in a sub-directory and
can be selected as follow::
tools/configure.sh mikroe-stm32f4:<subdir>
If this is a Windows native build, then configure.bat should be used
instead of configure.sh::
configure.bat Mikroe-STM32F4\<subdir>
Where <subdir> is one of the following:
fulldemo
--------
This is an example that includes an NSH shell over USB that also
enables all features of the Mikroe-STM32F4 board including the LCD,
on-board 1M Flash with SMART filesystem, Aux RS-232 serial port on the
expansion header, etc. A couple of the NX graphics commands are made
available via the NSH prompt for performing LCD demonstrations, and the
nximage example is used as a splash-screen at startup.
kostest
-------
NOTE: This configuration compiles, but has not been fully tested
on the hardware yet.
This configuration directory, performs a simple OS test using
apps/examples/ostest with NuttX build as a kernel-mode monolithic
module and the user applications are built separately. Is
is recommended to use a special make command; not just 'make' but
make with the following two arguments::
make pass1 pass2
In the normal case (just 'make'), make will attempt to build both user-
and kernel-mode blobs more or less interleaved. This actual works!
However, for me it is very confusing so I prefer the above make command:
Make the user-space binaries first (pass1), then make the kernel-space
binaries (pass2)
NOTES:
1. This configuration uses the mconf-based configuration tool. To
change this configuration using that tool, you should:
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
see additional README.txt files in the NuttX tools repository.
b. Execute 'make menuconfig' in nuttx/ in order to start the
reconfiguration process.
2. This is the default platform/toolchain in the configuration::
CONFIG_HOST_WINDOWS=y : Windows
CONFIG_WINDOWS_CYGWIN=y : Cygwin environment on Windows
CONFIG_ARM_TOOLCHAIN_GNU_EABI=y : GNU EABI toolchain for Windows
This is easily changed by modifying the configuration.
3. At the end of the build, there will be several files in the top-level
NuttX build directory::
PASS1:
nuttx_user.elf - The pass1 user-space ELF file
nuttx_user.hex - The pass1 Intel HEX format file (selected in defconfig)
User.map - Symbols in the user-space ELF file
PASS2:
nuttx - The pass2 kernel-space ELF file
nuttx.hex - The pass2 Intel HEX file (selected in defconfig)
System.map - Symbols in the kernel-space ELF file
4. Combining .hex files. If you plan to use the STM32 ST-Link Utility to
load the .hex files into FLASH, then you need to combine the two hex
files into a single .hex file. Here is how you can do that.
a. The 'tail' of the nuttx.hex file should look something like this
(with my comments added)::
$ tail nuttx.hex
# 00, data records
...
:10 9DC0 00 01000000000800006400020100001F0004
:10 9DD0 00 3B005A0078009700B500D400F300110151
:08 9DE0 00 30014E016D0100008D
# 05, Start Linear Address Record
:04 0000 05 0800 0419 D2
# 01, End Of File record
:00 0000 01 FF
Use an editor such as vi to remove the 05 and 01 records.
b. The 'head' of the nuttx_user.hex file should look something like
this (again with my comments added)::
$ head nuttx_user.hex
# 04, Extended Linear Address Record
:02 0000 04 0801 F1
# 00, data records
:10 8000 00 BD89 01084C800108C8110208D01102087E
:10 8010 00 0010 00201C1000201C1000203C16002026
:10 8020 00 4D80 01085D80010869800108ED83010829
...
Nothing needs to be done here. The nuttx_user.hex file should
be fine.
c. Combine the edited nuttx.hex and un-edited nuttx_user.hex
file to produce a single combined hex file::
$ cat nuttx.hex nuttx_user.hex >combined.hex
Then use the combined.hex file with the STM32 ST-Link tool. If
you do this a lot, you will probably want to invest a little time
to develop a tool to automate these steps.
nsh
---
This is an NSH example that uses USART2 as the console. Note that
the Mikroe-STM32F4 board doesn't actually have onboard line drivers
or a connector for USART2, but it does route the USART2 signals to
the expansion header. To use this demo, you would need to connect
an external 3.3V RS-232 line driver to the USART's I/O lines on the
expansion header.
NOTE: This demo doesn't quite work yet. I can get output to the
USART, but so far, I have not gotten nsh to actually come up.
nx
--
An example using the NuttX graphics system (NX). This example
focuses on general window controls, movement, mouse and keyboard
input.::
CONFIG_LCD_LANDSCAPE=y : 320x240 landscape orientation
CONFIG_LCD_MIO283QT2=y : MIO283QT-2 is the default
You can the newer MIO283QT-9A by enabling it in the configuration.::
CONFIG_LCD_MIO283QT2=n : Disable the MIO283QT-2
CONFIG_LCD_MIO283QT9A=y : Enable the MIO283QT-9A
nxlines
-------
An example using the NuttX graphics system (NX). This example focuses on
placing lines on the background in various orientations using the
on-board TFT LCD.::
CONFIG_LCD_LANDSCAPE=y : 320x240 landscape orientation
CONFIG_LCD_MIO283QT2=y : MIO283QT-2 is the default
You can the newer MIO283QT-9A by enabling it in the configuration.::
CONFIG_LCD_MIO283QT2=n : Disable the MIO283QT-2
CONFIG_LCD_MIO283QT9A=y : Enable the MIO283QT-9A
nxtext
------
Another example using the NuttX graphics system (NX). This
example focuses on placing text on the background while pop-up
windows occur. Text should continue to update normally with
or without the popup windows present.
usbnsh
-------
This is another NSH example. If differs from other 'nsh' configurations
in that this configurations uses a USB serial device for console I/O.
Such a configuration is useful on the stm32f4discovery which has no
builtin RS-232 drivers.
NOTES:
1. This configuration uses the mconf-based configuration tool. To
change this configuration using that tool, you should:
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
see additional README.txt files in the NuttX tools repository.
b. Execute 'make menuconfig' in nuttx/ in order to start the
reconfiguration process.
2. By default, this configuration uses the ARM EABI toolchain
for Windows and builds under Cygwin (or probably MSYS). That
can easily be reconfigured, of course.::
CONFIG_HOST_WINDOWS=y : Builds under Windows
CONFIG_WINDOWS_CYGWIN=y : Using Cygwin
CONFIG_ARM_TOOLCHAIN_GNU_EABI=y : GNU EABI toolchain for Windows
3. This configuration does have UART2 output enabled and set up as
the system logging device::
CONFIG_SYSLOG_CHAR=y : Use a character device for system logging
CONFIG_SYSLOG_DEVPATH="/dev/ttyS0" : UART2 will be /dev/ttyS0
However, there is nothing to generate SYSLOG output in the default
configuration so nothing should appear on UART2 unless you enable
some debug output or enable the USB monitor.
4. Enabling USB monitor SYSLOG output. If tracing is enabled, the USB
device will save encoded trace output in in-memory buffer; if the
USB monitor is enabled, that trace buffer will be periodically
emptied and dumped to the system logging device (UART2 in this
configuration)::
CONFIG_USBDEV_TRACE=y : Enable USB trace feature
CONFIG_USBDEV_TRACE_NRECORDS=128 : Buffer 128 records in memory
CONFIG_NSH_USBDEV_TRACE=n : No builtin tracing from NSH
CONFIG_NSH_ARCHINIT=y : Automatically start the USB monitor
CONFIG_USBMONITOR=y : Enable the USB monitor daemon
CONFIG_USBMONITOR_STACKSIZE=2048 : USB monitor daemon stack size
CONFIG_USBMONITOR_PRIORITY=50 : USB monitor daemon priority
CONFIG_USBMONITOR_INTERVAL=2 : Dump trace data every 2 seconds
CONFIG_USBMONITOR_TRACEINIT=y : Enable TRACE output
CONFIG_USBMONITOR_TRACECLASS=y
CONFIG_USBMONITOR_TRACETRANSFERS=y
CONFIG_USBMONITOR_TRACECONTROLLER=y
CONFIG_USBMONITOR_TRACEINTERRUPTS=y
5. By default, this project assumes that you are *NOT* using the DFU bootloader.
Using the Prolifics PL2303 Emulation
------------------------------------
You could also use the non-standard PL2303 serial device instead of
the standard CDC/ACM serial device by changing::
CONFIG_CDCACM=y : Disable the CDC/ACM serial device class
CONFIG_CDCACM_CONSOLE=y : The CDC/ACM serial device is NOT the console
CONFIG_PL2303=y : The Prolifics PL2303 emulation is enabled
CONFIG_PL2303_CONSOLE=y : The PL2303 serial device is the console
@@ -0,0 +1,394 @@
================
ST Nucleo F401RE
================
This page discusses issues unique to NuttX configurations for the ST
NucleoF401RE and NucleoF411RE boards from ST Micro. See
http://www.st.com/web/catalog/mmc/FM141/SC1169/SS1577/LN1810/PF258797
http://www.st.com/web/catalog/mmc/FM141/SC1169/SS1577/LN1877/PF260049
These two boards are very similar, both supporting STM32 "Dynamic Efficiency
Line" parts but differing in the specific STM32 chip mounted on board. The
chips themselves are also very similar with the STM32F411RE having some
additional capability:
NucleoF401RE:
- Microprocessor: 32-bit ARM Cortex M4 at 84MHz STM32F104RE
- Memory: 512 KB Flash and 96 KB SRAM
- ADC: 1×12-bit, 2.4 MSPS A/D converter: up to 10 channels
- DMA: 16-stream DMA controllers with FIFOs and burst support
- Timers: Up to 11 timers: up to six 16-bit, two 32-bit timers, two
watchdog timers, and a SysTick timer
- GPIO: Up to 81 I/O ports with interrupt capability
- I2C: Up to 3 × I2C interfaces
- USARTs: Up to 3 USARTs
- SPIs: Up to 4 SPIs (2 I2S)
- SDIO interface
- USB: USB 2.0 full-speed device/host/OTG controller with on-chip PHY
- CRC calculation unit
- RTC
The NucleoF411RE also has additional DMA and SPI peripheral capabilities.
Board features, however, are identical:
- Peripherals: 1 led, 1 push button
- Debug: Serial wire debug and JTAG interfaces
- Expansion I/F Ardino and Morpho Headers
Uses a STM32F103 to provide a ST-Link for programming, debug similar to the
OpenOcd FTDI function - USB to JTAG front-end.
See http://mbed.org/platforms/ST-Nucleo-F401RE and
http://developer.mbed.org/platforms/ST-Nucleo-F411RE for more
information about these boards.
mbed
====
The Nucleo-F401RE includes boot loader from mbed:
https://mbed.org/platforms/ST-Nucleo-F401RE/
https://mbed.org/handbook/Homepage
Using the mbed loader:
1. Connect the Nucleo-F4x1RE to the host PC using the USB connector.
2. A new file system will appear called NUCLEO; open it with Windows
Explorer (assuming that you are using Windows).
3. Drag and drop nuttx.bin into the MBED window. This will load the
nuttx.bin binary into the Nucleo-F4x1RE. The NUCLEO window will
close then re-open and the Nucleo-F4x1RE will be running the new code.
Hardware
========
GPIO
----
::
SERIAL_TX=PA_2 USER_BUTTON=PC_13
SERIAL_RX=PA_3 LED1 =PA_5
A0=PA_0 USART2RX D0=PA_3 D8 =PA_9
A1=PA_1 USART2TX D1=PA_2 D9 =PC_7
A2=PA_4 D2=PA_10 WIFI_CS=D10=PB_6 SPI_CS
A3=PB_0 WIFI_INT=D3=PB_3 D11=PA_7 SPI_MOSI
A4=PC_1 SDCS=D4=PB_5 D12=PA_6 SPI_MISO
A5=PC_0 WIFI_EN=D5=PB_4 LED1=D13=PA_5 SPI_SCK
LED2=D6=PB_10 I2C1_SDA=D14=PB_9 Probe
D7=PA_8 I2C1_SCL=D15=PB_8 Probe
From: https://mbed.org/platforms/ST-Nucleo-F401RE/
Buttons
-------
B1 USER: the user button is connected to the I/O PC13 (pin 2) of the STM32
microcontroller.
LEDs
----
The Nucleo F401RE and Nucleo F411RE provide a single user LED, LD2. LD2
is the green LED connected to Arduino signal D13 corresponding to MCU I/O
PA5 (pin 21) or PB13 (pin 34) depending on the STM32target.
- When the I/O is HIGH value, the LED is on.
- When the I/O is LOW, the LED is off.
These LEDs are not used by the board port unless CONFIG_ARCH_LEDS is
defined. In that case, the usage by the board port is defined in
include/board.h and src/sam_leds.c. The LEDs are used to encode OS-related
events as follows when the red LED (PE24) is available:
=================== ======================= ===========
SYMBOL Meaning LD2
=================== ======================= ===========
LED_STARTED NuttX has been started OFF
LED_HEAPALLOCATE Heap has been allocated OFF
LED_IRQSENABLED Interrupts enabled OFF
LED_STACKCREATED Idle stack created ON
LED_INIRQ In an interrupt No change
LED_SIGNAL In a signal handler No change
LED_ASSERTION An assertion failed No change
LED_PANIC The system has crashed Blinking
LED_IDLE MCU is is sleep mode Not used
=================== ======================= ===========
Thus if LD2, NuttX has successfully booted and is, apparently, running
normally. If LD2 is flashing at approximately 2Hz, then a fatal error
has been detected and the system has halted.
Serial Consoles
===============
USART1
------
Pins and Connectors::
RXD: PA11 CN10 pin 14
PB7 CN7 pin 21
TXD: PA10 CN9 pin 3, CN10 pin 33
PB6 CN5 pin 3, CN10 pin 17
NOTE: You may need to edit the include/board.h to select different USART1
pin selections.
TTL to RS-232 converter connection::
Nucleo CN10 STM32F4x1RE
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
To configure USART1 as the console::
CONFIG_STM32_USART1=y
CONFIG_USART1_SERIALDRIVER=y
CONFIG_USART1_SERIAL_CONSOLE=y
CONFIG_USART1_RXBUFSIZE=256
CONFIG_USART1_TXBUFSIZE=256
CONFIG_USART1_BAUD=115200
CONFIG_USART1_BITS=8
CONFIG_USART1_PARITY=0
CONFIG_USART1_2STOP=0
USART2
------
Pins and Connectors::
RXD: PA3 CN9 pin 1 (See SB13, 14, 62, 63). CN10 pin 37
PD6
TXD: PA2 CN9 pin 2(See SB13, 14, 62, 63). CN10 pin 35
PD5
UART2 is the default in all of these configurations.
TTL to RS-232 converter connection::
Nucleo CN9 STM32F4x1RE
----------- ------------
Pin 1 PA3 USART2_RX *Warning you make need to reverse RX/TX on
Pin 2 PA2 USART2_TX some RS-232 converters
Solder Bridges. This configuration requires:
- SB62 and SB63 Closed: PA2 and PA3 on STM32 MCU are connected to D1 and D0
(pin 7 and pin 8) on Arduino connector CN9 and ST Morpho connector CN10
as USART signals. Thus SB13 and SB14 should be OFF.
- SB13 and SB14 Open: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
disconnected to PA3 and PA2 on STM32 MCU.
To configure USART2 as the console::
CONFIG_STM32_USART2=y
CONFIG_USART2_SERIALDRIVER=y
CONFIG_USART2_SERIAL_CONSOLE=y
CONFIG_USART2_RXBUFSIZE=256
CONFIG_USART2_TXBUFSIZE=256
CONFIG_USART2_BAUD=115200
CONFIG_USART2_BITS=8
CONFIG_USART2_PARITY=0
CONFIG_USART2_2STOP=0
USART6
------
Pins and Connectors::
RXD: PC7 CN5 pin2, CN10 pin 19
PA12 CN10, pin 12
TXD: PC6 CN10, pin 4
PA11 CN10, pin 14
To configure USART6 as the console::
CONFIG_STM32_USART6=y
CONFIG_USART6_SERIALDRIVER=y
CONFIG_USART6_SERIAL_CONSOLE=y
CONFIG_USART6_RXBUFSIZE=256
CONFIG_USART6_TXBUFSIZE=256
CONFIG_USART6_BAUD=115200
CONFIG_USART6_BITS=8
CONFIG_USART6_PARITY=0
CONFIG_USART6_2STOP=0
Virtual COM Port
----------------
Yet another option is to use UART2 and the USB virtual COM port. This
option may be more convenient for long term development, but is painful
to use during board bring-up.
Solder Bridges. This configuration requires:
- SB62 and SB63 Open: PA2 and PA3 on STM32 MCU are disconnected to D1
and D0 (pin 7 and pin 8) on Arduino connector CN9 and ST Morpho
connector CN10.
- SB13 and SB14 Closed: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
connected to PA3 and PA2 on STM32 MCU to have USART communication
between them. Thus SB61, SB62 and SB63 should be OFF.
Configuring USART2 is the same as given above.
Question: What BAUD should be configure to interface with the Virtual
COM port? 115200 8N1?
Default
-------
As shipped, SB62 and SB63 are open and SB13 and SB14 closed, so the
virtual COM port is enabled.
Shields
=======
RS-232 from Cutedigi.com
------------------------
Supports a single RS-232 connected via::
Nucleo CN9 STM32F4x1RE Cutedigi
----------- ------------ --------
Pin 1 PA3 USART2_RX RXD
Pin 2 PA2 USART2_TX TXD
Support for this shield is enabled by selecting USART2 and configuring
SB13, 14, 62, and 63 as described above under "Serial Consoles"
Itead Joystick Shield
---------------------
See http://imall.iteadstudio.com/im120417014.html for more information
about this joystick.
Itead Joystick Connection::
--------- ----------------- ---------------------------------
ARDUINO ITEAD NUCLEO-F4x1
PIN NAME SIGNAL SIGNAL
--------- ----------------- ---------------------------------
D3 Button E Output PB3
D4 Button D Output PB5
D5 Button C Output PB4
D6 Button B Output PB10
D7 Button A Output PA8
D8 Button F Output PA9
D9 Button G Output PC7
A0 Joystick Y Output PA0 ADC1_0
A1 Joystick X Output PA1 ADC1_1
--------- ----------------- ---------------------------------
All buttons are pulled on the shield. A sensed low value indicates
when the button is pressed.
NOTE: Button F cannot be used with the default USART1 configuration
because PA9 is configured for USART1_RX by default. Use select
different USART1 pins in the board.h file or select a different
USART or select CONFIG_NUCLEO_F401RE_AJOY_MINBUTTONS which will
eliminate all but buttons A, B, and C.
Itead Joystick Signal interpretation::
--------- ----------------------- ---------------------------
BUTTON TYPE NUTTX ALIAS
--------- ----------------------- ---------------------------
Button A Large button A JUMP/BUTTON 3
Button B Large button B FIRE/BUTTON 2
Button C Joystick select button SELECT/BUTTON 1
Button D Tiny Button D BUTTON 6
Button E Tiny Button E BUTTON 7
Button F Large Button F BUTTON 4
Button G Large Button G BUTTON 5
--------- ----------------------- ---------------------------
Itead Joystick configuration settings::
System Type -> STM32 Peripheral Support
CONFIG_STM32_ADC1=y : Enable ADC1 driver support
Drivers
CONFIG_ANALOG=y : Should be automatically selected
CONFIG_ADC=y : Should be automatically selected
CONFIG_INPUT=y : Select input device support
CONFIG_INPUT_AJOYSTICK=y : Select analog joystick support
There is nothing in the configuration that currently uses the joystick.
For testing, you can add the following configuration options to enable the
analog joystick example at apps/examples/ajoystick::
CONFIG_NSH_ARCHINIT=y
CONFIG_EXAMPLES_AJOYSTICK=y
CONFIG_EXAMPLES_AJOYSTICK_DEVNAME="/dev/ajoy0"
STATUS:
2014-12-04:
- Without ADC DMA support, it is not possible to sample both X and Y
with a single ADC. Right now, only one axis is being converted.
- There is conflicts with some of the Arduino data pins and the
default USART1 configuration. I am currently running with USART1
but with CONFIG_NUCLEO_F401RE_AJOY_MINBUTTONS to eliminate the
conflict.
- Current showstopper: I appear to be getting infinite interrupts as
soon as joystick button interrupts are enabled.
Configurations
==============
f401-nsh:
---------
Configures the NuttShell (nsh) located at apps/examples/nsh for the
Nucleo-F401RE board. The Configuration enables the serial interfaces
on UART2. Support for builtin applications is enabled, but in the base
configuration no builtin applications are selected (see NOTES below).
NOTES:
1. This configuration uses the mconf-based configuration tool. To
change this configuration using that tool, you should:
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
see additional README.txt files in the NuttX tools repository.
b. Execute 'make menuconfig' in nuttx/ in order to start the
reconfiguration process.
2. By default, this configuration uses the ARM EABI toolchain
for Linux. That can easily be reconfigured, of course.:
CONFIG_HOST_LINUX=y : Builds under Linux
CONFIG_ARM_TOOLCHAIN_GNU_EABI=y : GNU EABI toolchain for Linux
3. Although the default console is USART2 (which would correspond to
the Virtual COM port) I have done all testing with the console
device configured for USART1 (see instruction above under "Serial
Consoles). I have been using a TTL-to-RS-232 converter connected
as shown below::
Nucleo CN10 STM32F4x1RE
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
f411-nsh
--------
This configuration is the same as the f401-nsh configuration, except
that it is configured to support the Nucleo-F411RE.
@@ -0,0 +1,223 @@
================
ST Nucleo F410RB
================
This page discusses issues unique to NuttX configurations for the ST
Nucleo F410RB board from ST Micro. See
http://www.st.com/en/evaluation-tools/nucleo-f410rb.html
NucleoF410RB:
- Microprocessor: 32-bit ARM Cortex M4 at 100MHz STM32F410RB
- Memory: 128 KB Flash and 32 KB SRAM
- ADC: 1x12-bit, 2.4 MSPS A/D converter: up to 16 channels
- DAC: 1x12-bit, 2.4 MSPS A/D converter: up to 1 channels
- DMA: 16-stream DMA controllers with FIFOs and burst support
- Timers: Up to 11 timers: up to 5 16-bit, 1 32-bit timers, two
watchdog timers, and a SysTick timer
- GPIO: Up to 81 I/O ports with interrupt capability
- I2C: Up to 3 I2C interfaces
- USARTs: Up to 3 USARTs
- SPIs: Up to 4 SPIs (2 I2S)
- CRC calculation unit
- RTC
- Peripherals: 1 led, 1 push button
- Debug: Serial wire debug and JTAG interfaces
- Expansion I/F Ardino and Morpho Headers
Uses a STM32F103 to provide a ST-Link for programming, debug similar to the
OpenOcd FTDI function - USB to JTAG front-end.
See https://os.mbed.com/platforms/ST-Nucleo-F410RB for more
information about this board.
Hardware
========
Buttons
-------
B1 USER: the user button is connected to the I/O PC13 (pin 2) of the STM32
microcontroller.
LEDs
----
The Nucleo F410RB provide a single user LED, LD2. LD2
is the green LED connected to Arduino signal D13 corresponding to MCU I/O
PA5 (pin 21) or PB13 (pin 34) depending on the STM32target.
- When the I/O is HIGH value, the LED is on.
- When the I/O is LOW, the LED is off.
These LEDs are not used by the board port unless CONFIG_ARCH_LEDS is
defined. In that case, the usage by the board port is defined in
include/board.h and src/sam_leds.c. The LEDs are used to encode OS-related
events as follows when the red LED (PE24) is available::
SYMBOL Meaning LD2
------------------- ----------------------- -----------
LED_STARTED NuttX has been started OFF
LED_HEAPALLOCATE Heap has been allocated OFF
LED_IRQSENABLED Interrupts enabled OFF
LED_STACKCREATED Idle stack created ON
LED_INIRQ In an interrupt No change
LED_SIGNAL In a signal handler No change
LED_ASSERTION An assertion failed No change
LED_PANIC The system has crashed Blinking
LED_IDLE MCU is is sleep mode Not used
Thus if LD2, NuttX has successfully booted and is, apparently, running
normally. If LD2 is flashing at approximately 2Hz, then a fatal error
has been detected and the system has halted.
Serial Consoles
===============
USART1
------
Pins and Connectors::
RXD: PA11 CN10 pin 14
PB7 CN7 pin 21
TXD: PA10 CN9 pin 3, CN10 pin 33
PB6 CN5 pin 3, CN10 pin 17
NOTE: You may need to edit the include/board.h to select different USART1
pin selections.
TTL to RS-232 converter connection::
Nucleo CN10 STM32F410RB
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
To configure USART1 as the console::
CONFIG_STM32_USART1=y
CONFIG_USART1_SERIALDRIVER=y
CONFIG_USART1_SERIAL_CONSOLE=y
CONFIG_USART1_RXBUFSIZE=256
CONFIG_USART1_TXBUFSIZE=256
CONFIG_USART1_BAUD=115200
CONFIG_USART1_BITS=8
CONFIG_USART1_PARITY=0
CONFIG_USART1_2STOP=0
USART2
------
Pins and Connectors::
RXD: PA3 CN9 pin 1 (See SB13, 14, 62, 63). CN10 pin 37
PD6
TXD: PA2 CN9 pin 2(See SB13, 14, 62, 63). CN10 pin 35
PD5
UART2 is the default in all of these configurations.
TTL to RS-232 converter connection::
Nucleo CN9 STM32F410RB
----------- ------------
Pin 1 PA3 USART2_RX *Warning you make need to reverse RX/TX on
Pin 2 PA2 USART2_TX some RS-232 converters
Solder Bridges. This configuration requires:
- SB62 and SB63 Closed: PA2 and PA3 on STM32 MCU are connected to D1 and D0
(pin 7 and pin 8) on Arduino connector CN9 and ST Morpho connector CN10
as USART signals. Thus SB13 and SB14 should be OFF.
- SB13 and SB14 Open: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
disconnected to PA3 and PA2 on STM32 MCU.
To configure USART2 as the console::
CONFIG_STM32_USART2=y
CONFIG_USART2_SERIALDRIVER=y
CONFIG_USART2_SERIAL_CONSOLE=y
CONFIG_USART2_RXBUFSIZE=256
CONFIG_USART2_TXBUFSIZE=256
CONFIG_USART2_BAUD=115200
CONFIG_USART2_BITS=8
CONFIG_USART2_PARITY=0
CONFIG_USART2_2STOP=0
USART6
------
Pins and Connectors::
RXD: PC7 CN5 pin2, CN10 pin 19
PA12 CN10, pin 12
TXD: PC6 CN10, pin 4
PA11 CN10, pin 14
To configure USART6 as the console::
CONFIG_STM32_USART6=y
CONFIG_USART6_SERIALDRIVER=y
CONFIG_USART6_SERIAL_CONSOLE=y
CONFIG_USART6_RXBUFSIZE=256
CONFIG_USART6_TXBUFSIZE=256
CONFIG_USART6_BAUD=115200
CONFIG_USART6_BITS=8
CONFIG_USART6_PARITY=0
CONFIG_USART6_2STOP=0
Virtual COM Port
----------------
Yet another option is to use UART2 and the USB virtual COM port. This
option may be more convenient for long term development, but is painful
to use during board bring-up.
Solder Bridges. This configuration requires:
- SB62 and SB63 Open: PA2 and PA3 on STM32 MCU are disconnected to D1
and D0 (pin 7 and pin 8) on Arduino connector CN9 and ST Morpho
connector CN10.
- SB13 and SB14 Closed: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
connected to PA3 and PA2 on STM32 MCU to have USART communication
between them. Thus SB61, SB62 and SB63 should be OFF.
Configuring USART2 is the same as given above.
Question: What BAUD should be configure to interface with the Virtual
COM port? 115200 8N1?
Default
-------
As shipped, SB62 and SB63 are open and SB13 and SB14 closed, so the
virtual COM port is enabled.
Configurations
==============
nsh
---
Configures the NuttShell (nsh) located at apps/examples/nsh for the
Nucleo-F410RB board. The Configuration enables the serial interfaces
on UART2. Support for builtin applications is enabled, but in the base
configuration no builtin applications are selected (see NOTES below).
NOTES:
1. This configuration uses the mconf-based configuration tool. To
change this configuration using that tool, you should:
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
see additional README.txt files in the NuttX tools repository.
b. Execute 'make menuconfig' in nuttx/ in order to start the
reconfiguration process.
@@ -0,0 +1,394 @@
================
ST Nucleo F401RE
================
This README discusses issues unique to NuttX configurations for the ST
NucleoF401RE and NucleoF411RE boards from ST Micro. See
http://www.st.com/web/catalog/mmc/FM141/SC1169/SS1577/LN1810/PF258797
http://www.st.com/web/catalog/mmc/FM141/SC1169/SS1577/LN1877/PF260049
These two boards are very similar, both supporting STM32 "Dynamic Efficiency
Line" parts but differing in the specific STM32 chip mounted on board. The
chips themselves are also very similar with the STM32F411RE having some
additional capability:
NucleoF411RE:
- Microprocessor: 32-bit ARM Cortex M4 at 100MHz STM32F411RE
- Memory: 512 KB Flash and 128 KB SRAM
- ADC: 1×12-bit, 2.4 MSPS A/D converter: up to 10 channels
- DMA: 16-stream DMA controllers with FIFOs and burst support
- Timers: Up to 11 timers: up to six 16-bit, two 32-bit timers, two
watchdog timers, and a SysTick timer
- GPIO: Up to 81 I/O ports with interrupt capability
- I2C: Up to 3 × I2C interfaces
- USARTs: Up to 3 USARTs
- SPIs: Up to 4 SPIs (2 I2S)
- SDIO interface
- USB: USB 2.0 full-speed device/host/OTG controller with on-chip PHY
- CRC calculation unit
- RTC
The NucleoF411RE also has additional DMA and SPI peripheral capabilities.
Board features, however, are identical:
- Peripherals: 1 led, 1 push button
- Debug: Serial wire debug and JTAG interfaces
- Expansion I/F Ardino and Morpho Headers
Uses a STM32F103 to provide a ST-Link for programming, debug similar to the
OpenOcd FTDI function - USB to JTAG front-end.
See http://mbed.org/platforms/ST-Nucleo-F401RE and
http://developer.mbed.org/platforms/ST-Nucleo-F411RE for more
information about these boards.
mbed
====
The Nucleo-F411RE includes boot loader from mbed:
https://mbed.org/platforms/ST-Nucleo-F401RE/
https://mbed.org/handbook/Homepage
Using the mbed loader:
1. Connect the Nucleo-F4x1RE to the host PC using the USB connector.
2. A new file system will appear called NUCLEO; open it with Windows
Explorer (assuming that you are using Windows).
3. Drag and drop nuttx.bin into the MBED window. This will load the
nuttx.bin binary into the Nucleo-F4x1RE. The NUCLEO window will
close then re-open and the Nucleo-F4x1RE will be running the new code.
Hardware
========
GPIO
----
::
SERIAL_TX=PA_2 USER_BUTTON=PC_13
SERIAL_RX=PA_3 LED1 =PA_5
A0=PA_0 USART2RX D0=PA_3 D8 =PA_9
A1=PA_1 USART2TX D1=PA_2 D9 =PC_7
A2=PA_4 D2=PA_10 WIFI_CS=D10=PB_6 SPI_CS
A3=PB_0 WIFI_INT=D3=PB_3 D11=PA_7 SPI_MOSI
A4=PC_1 SDCS=D4=PB_5 D12=PA_6 SPI_MISO
A5=PC_0 WIFI_EN=D5=PB_4 LED1=D13=PA_5 SPI_SCK
LED2=D6=PB_10 I2C1_SDA=D14=PB_9 Probe
D7=PA_8 I2C1_SCL=D15=PB_8 Probe
From: https://mbed.org/platforms/ST-Nucleo-F401RE/
Buttons
-------
B1 USER: the user button is connected to the I/O PC13 (pin 2) of the STM32
microcontroller.
LEDs
----
The Nucleo F401RE and Nucleo F411RE provide a single user LED, LD2. LD2
is the green LED connected to Arduino signal D13 corresponding to MCU I/O
PA5 (pin 21) or PB13 (pin 34) depending on the STM32target.
- When the I/O is HIGH value, the LED is on.
- When the I/O is LOW, the LED is off.
These LEDs are not used by the board port unless CONFIG_ARCH_LEDS is
defined. In that case, the usage by the board port is defined in
include/board.h and src/sam_leds.c. The LEDs are used to encode OS-related
events as follows when the red LED (PE24) is available:
=================== ======================= ===========
SYMBOL Meaning LD2
=================== ======================= ===========
LED_STARTED NuttX has been started OFF
LED_HEAPALLOCATE Heap has been allocated OFF
LED_IRQSENABLED Interrupts enabled OFF
LED_STACKCREATED Idle stack created ON
LED_INIRQ In an interrupt No change
LED_SIGNAL In a signal handler No change
LED_ASSERTION An assertion failed No change
LED_PANIC The system has crashed Blinking
LED_IDLE MCU is is sleep mode Not used
=================== ======================= ===========
Thus if LD2, NuttX has successfully booted and is, apparently, running
normally. If LD2 is flashing at approximately 2Hz, then a fatal error
has been detected and the system has halted.
Serial Consoles
===============
USART1
------
Pins and Connectors::
RXD: PA11 CN10 pin 14
PB7 CN7 pin 21
TXD: PA10 CN9 pin 3, CN10 pin 33
PB6 CN5 pin 3, CN10 pin 17
NOTE: You may need to edit the include/board.h to select different USART1
pin selections.
TTL to RS-232 converter connection::
Nucleo CN10 STM32F4x1RE
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
To configure USART1 as the console::
CONFIG_STM32_USART1=y
CONFIG_USART1_SERIALDRIVER=y
CONFIG_USART1_SERIAL_CONSOLE=y
CONFIG_USART1_RXBUFSIZE=256
CONFIG_USART1_TXBUFSIZE=256
CONFIG_USART1_BAUD=115200
CONFIG_USART1_BITS=8
CONFIG_USART1_PARITY=0
CONFIG_USART1_2STOP=0
USART2
------
Pins and Connectors::
RXD: PA3 CN9 pin 1 (See SB13, 14, 62, 63). CN10 pin 37
PD6
TXD: PA2 CN9 pin 2(See SB13, 14, 62, 63). CN10 pin 35
PD5
UART2 is the default in all of these configurations.
TTL to RS-232 converter connection::
Nucleo CN9 STM32F4x1RE
----------- ------------
Pin 1 PA3 USART2_RX *Warning you make need to reverse RX/TX on
Pin 2 PA2 USART2_TX some RS-232 converters
Solder Bridges. This configuration requires:
- SB62 and SB63 Closed: PA2 and PA3 on STM32 MCU are connected to D1 and D0
(pin 7 and pin 8) on Arduino connector CN9 and ST Morpho connector CN10
as USART signals. Thus SB13 and SB14 should be OFF.
- SB13 and SB14 Open: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
disconnected to PA3 and PA2 on STM32 MCU.
To configure USART2 as the console::
CONFIG_STM32_USART2=y
CONFIG_USART2_SERIALDRIVER=y
CONFIG_USART2_SERIAL_CONSOLE=y
CONFIG_USART2_RXBUFSIZE=256
CONFIG_USART2_TXBUFSIZE=256
CONFIG_USART2_BAUD=115200
CONFIG_USART2_BITS=8
CONFIG_USART2_PARITY=0
CONFIG_USART2_2STOP=0
USART6
------
Pins and Connectors::
RXD: PC7 CN5 pin2, CN10 pin 19
PA12 CN10, pin 12
TXD: PC6 CN10, pin 4
PA11 CN10, pin 14
To configure USART6 as the console::
CONFIG_STM32_USART6=y
CONFIG_USART6_SERIALDRIVER=y
CONFIG_USART6_SERIAL_CONSOLE=y
CONFIG_USART6_RXBUFSIZE=256
CONFIG_USART6_TXBUFSIZE=256
CONFIG_USART6_BAUD=115200
CONFIG_USART6_BITS=8
CONFIG_USART6_PARITY=0
CONFIG_USART6_2STOP=0
Virtual COM Port
----------------
Yet another option is to use UART2 and the USB virtual COM port. This
option may be more convenient for long term development, but is painful
to use during board bring-up.
Solder Bridges. This configuration requires:
- SB62 and SB63 Open: PA2 and PA3 on STM32 MCU are disconnected to D1
and D0 (pin 7 and pin 8) on Arduino connector CN9 and ST Morpho
connector CN10.
- SB13 and SB14 Closed: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
connected to PA3 and PA2 on STM32 MCU to have USART communication
between them. Thus SB61, SB62 and SB63 should be OFF.
Configuring USART2 is the same as given above.
Question: What BAUD should be configure to interface with the Virtual
COM port? 115200 8N1?
Default
-------
As shipped, SB62 and SB63 are open and SB13 and SB14 closed, so the
virtual COM port is enabled.
Shields
=======
RS-232 from Cutedigi.com
------------------------
Supports a single RS-232 connected via::
Nucleo CN9 STM32F4x1RE Cutedigi
----------- ------------ --------
Pin 1 PA3 USART2_RX RXD
Pin 2 PA2 USART2_TX TXD
Support for this shield is enabled by selecting USART2 and configuring
SB13, 14, 62, and 63 as described above under "Serial Consoles"
Itead Joystick Shield
---------------------
See http://imall.iteadstudio.com/im120417014.html for more information
about this joystick.
Itead Joystick Connection::
--------- ----------------- ---------------------------------
ARDUINO ITEAD NUCLEO-F4x1
PIN NAME SIGNAL SIGNAL
--------- ----------------- ---------------------------------
D3 Button E Output PB3
D4 Button D Output PB5
D5 Button C Output PB4
D6 Button B Output PB10
D7 Button A Output PA8
D8 Button F Output PA9
D9 Button G Output PC7
A0 Joystick Y Output PA0 ADC1_0
A1 Joystick X Output PA1 ADC1_1
--------- ----------------- ---------------------------------
All buttons are pulled on the shield. A sensed low value indicates
when the button is pressed.
NOTE: Button F cannot be used with the default USART1 configuration
because PA9 is configured for USART1_RX by default. Use select
different USART1 pins in the board.h file or select a different
USART or select CONFIG_NUCLEO_F401RE_AJOY_MINBUTTONS which will
eliminate all but buttons A, B, and C.
Itead Joystick Signal interpretation::
--------- ----------------------- ---------------------------
BUTTON TYPE NUTTX ALIAS
--------- ----------------------- ---------------------------
Button A Large button A JUMP/BUTTON 3
Button B Large button B FIRE/BUTTON 2
Button C Joystick select button SELECT/BUTTON 1
Button D Tiny Button D BUTTON 6
Button E Tiny Button E BUTTON 7
Button F Large Button F BUTTON 4
Button G Large Button G BUTTON 5
--------- ----------------------- ---------------------------
Itead Joystick configuration settings::
System Type -> STM32 Peripheral Support
CONFIG_STM32_ADC1=y : Enable ADC1 driver support
Drivers
CONFIG_ANALOG=y : Should be automatically selected
CONFIG_ADC=y : Should be automatically selected
CONFIG_INPUT=y : Select input device support
CONFIG_INPUT_AJOYSTICK=y : Select analog joystick support
There is nothing in the configuration that currently uses the joystick.
For testing, you can add the following configuration options to enable the
analog joystick example at apps/examples/ajoystick::
CONFIG_NSH_ARCHINIT=y
CONFIG_EXAMPLES_AJOYSTICK=y
CONFIG_EXAMPLES_AJOYSTICK_DEVNAME="/dev/ajoy0"
STATUS:
2014-12-04:
- Without ADC DMA support, it is not possible to sample both X and Y
with a single ADC. Right now, only one axis is being converted.
- There is conflicts with some of the Arduino data pins and the
default USART1 configuration. I am currently running with USART1
but with CONFIG_NUCLEO_F401RE_AJOY_MINBUTTONS to eliminate the
conflict.
- Current showstopper: I appear to be getting infinite interrupts as
soon as joystick button interrupts are enabled.
Configurations
==============
f401-nsh:
---------
Configures the NuttShell (nsh) located at apps/examples/nsh for the
Nucleo-F401RE board. The Configuration enables the serial interfaces
on UART2. Support for builtin applications is enabled, but in the base
configuration no builtin applications are selected (see NOTES below).
NOTES:
1. This configuration uses the mconf-based configuration tool. To
change this configuration using that tool, you should:
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
see additional README.txt files in the NuttX tools repository.
b. Execute 'make menuconfig' in nuttx/ in order to start the
reconfiguration process.
2. By default, this configuration uses the ARM EABI toolchain
for Linux. That can easily be reconfigured, of course.:
CONFIG_HOST_LINUX=y : Builds under Linux
CONFIG_ARM_TOOLCHAIN_GNU_EABI=y : GNU EABI toolchain for Linux
3. Although the default console is USART2 (which would correspond to
the Virtual COM port) I have done all testing with the console
device configured for USART1 (see instruction above under "Serial
Consoles). I have been using a TTL-to-RS-232 converter connected
as shown below::
Nucleo CN10 STM32F4x1RE
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
f411-nsh
--------
This configuration is the same as the f401-nsh configuration, except
that it is configured to support the Nucleo-F411RE.
@@ -0,0 +1,222 @@
================
ST Nucleo F410RB
================
This page discusses issues unique to NuttX configurations for the ST
Nucleo F410RB board from ST Micro. See
http://www.st.com/en/evaluation-tools/nucleo-f412zg.html
NucleoF412ZG:
- Microprocessor: 32-bit ARM Cortex M4 at 100MHz STM32F412ZG
- Memory: 1 MB Flash and 256 KB SRAM
- ADC: 1x12-bit, 2.4 MSPS A/D converter: up to 16 channels
- DMA: 2x8-stream DMA controllers with FIFOs and burst support
- Timers: Up to 17 timers: up to 12 16-bit, 2 32-bit timers, two
watchdog timers, and a SysTick timer
- GPIO: Up to 114 I/O ports with interrupt capability
- I2C: Up to 4 I2C interfaces
- USARTs: Up to 4 USARTs
- SPIs: Up to 5 SPIs (5 I2S)
- SDIO interface (SD/MMC/eMMC)
- Advanced connectivity: USB 2.0 full-speed device/host/OTG controller with PHY
- 2x CAN (2.0B Active)
- True random number generator
- CRC calculation unit
- 96-bit unique ID
- RTC
See:
https://www.st.com/content/ccc/resource/technical/document/user_manual/group0/26/49/90/2e/33/0d/4a/da/DM00244518/files/DM00244518.pdf/jcr:content/translations/en.DM00244518.pdf
- Peripherals: 3 led, 2 push button
- Debug: Serial wire debug and JTAG interfaces
- Expansion I/F Ardino and Morpho Headers
Hardware
========
Buttons
-------
B1 USER: the user button is connected to the I/O PC13 (pin 2) of the STM32
microcontroller.
LEDs
----
The Nucleo F410RB provide a single user LED, LD2. LD2
is the green LED connected to Arduino signal D13 corresponding to MCU I/O
PA5 (pin 21) or PB13 (pin 34) depending on the STM32target.
- When the I/O is HIGH value, the LED is on.
- When the I/O is LOW, the LED is off.
These LEDs are not used by the board port unless CONFIG_ARCH_LEDS is
defined. In that case, the usage by the board port is defined in
include/board.h and src/sam_leds.c. The LEDs are used to encode OS-related
events as follows when the red LED (PE24) is available::
SYMBOL Meaning LD2
------------------- ----------------------- -----------
LED_STARTED NuttX has been started OFF
LED_HEAPALLOCATE Heap has been allocated OFF
LED_IRQSENABLED Interrupts enabled OFF
LED_STACKCREATED Idle stack created ON
LED_INIRQ In an interrupt No change
LED_SIGNAL In a signal handler No change
LED_ASSERTION An assertion failed No change
LED_PANIC The system has crashed Blinking
LED_IDLE MCU is is sleep mode Not used
Thus if LD2, NuttX has successfully booted and is, apparently, running
normally. If LD2 is flashing at approximately 2Hz, then a fatal error
has been detected and the system has halted.
Serial Consoles
===============
USART1
------
Pins and Connectors::
RXD: PA11 CN10 pin 14
PB7 CN7 pin 21
TXD: PA10 CN9 pin 3, CN10 pin 33
PB6 CN5 pin 3, CN10 pin 17
NOTE: You may need to edit the include/board.h to select different USART1
pin selections.
TTL to RS-232 converter connection::
Nucleo CN10 STM32F410RB
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
To configure USART1 as the console::
CONFIG_STM32_USART1=y
CONFIG_USART1_SERIALDRIVER=y
CONFIG_USART1_SERIAL_CONSOLE=y
CONFIG_USART1_RXBUFSIZE=256
CONFIG_USART1_TXBUFSIZE=256
CONFIG_USART1_BAUD=115200
CONFIG_USART1_BITS=8
CONFIG_USART1_PARITY=0
CONFIG_USART1_2STOP=0
USART2
------
Pins and Connectors::
RXD: PA3 CN9 pin 1 (See SB13, 14, 62, 63). CN10 pin 37
PD6
TXD: PA2 CN9 pin 2(See SB13, 14, 62, 63). CN10 pin 35
PD5
UART2 is the default in all of these configurations.
TTL to RS-232 converter connection::
Nucleo CN9 STM32F410RB
----------- ------------
Pin 1 PA3 USART2_RX *Warning you make need to reverse RX/TX on
Pin 2 PA2 USART2_TX some RS-232 converters
Solder Bridges. This configuration requires:
- SB62 and SB63 Closed: PA2 and PA3 on STM32 MCU are connected to D1 and D0
(pin 7 and pin 8) on Arduino connector CN9 and ST Morpho connector CN10
as USART signals. Thus SB13 and SB14 should be OFF.
- SB13 and SB14 Open: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
disconnected to PA3 and PA2 on STM32 MCU.
To configure USART2 as the console::
CONFIG_STM32_USART2=y
CONFIG_USART2_SERIALDRIVER=y
CONFIG_USART2_SERIAL_CONSOLE=y
CONFIG_USART2_RXBUFSIZE=256
CONFIG_USART2_TXBUFSIZE=256
CONFIG_USART2_BAUD=115200
CONFIG_USART2_BITS=8
CONFIG_USART2_PARITY=0
CONFIG_USART2_2STOP=0
USART6
------
Pins and Connectors::
RXD: PC7 CN5 pin2, CN10 pin 19
PA12 CN10, pin 12
TXD: PC6 CN10, pin 4
PA11 CN10, pin 14
To configure USART6 as the console::
CONFIG_STM32_USART6=y
CONFIG_USART6_SERIALDRIVER=y
CONFIG_USART6_SERIAL_CONSOLE=y
CONFIG_USART6_RXBUFSIZE=256
CONFIG_USART6_TXBUFSIZE=256
CONFIG_USART6_BAUD=115200
CONFIG_USART6_BITS=8
CONFIG_USART6_PARITY=0
CONFIG_USART6_2STOP=0
Virtual COM Port
----------------
Yet another option is to use UART2 and the USB virtual COM port. This
option may be more convenient for long term development, but is painful
to use during board bring-up.
Solder Bridges. This configuration requires:
- SB62 and SB63 Open: PA2 and PA3 on STM32 MCU are disconnected to D1
and D0 (pin 7 and pin 8) on Arduino connector CN9 and ST Morpho
connector CN10.
- SB13 and SB14 Closed: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
connected to PA3 and PA2 on STM32 MCU to have USART communication
between them. Thus SB61, SB62 and SB63 should be OFF.
Configuring USART2 is the same as given above.
Question: What BAUD should be configure to interface with the Virtual
COM port? 115200 8N1?
Default:
As shipped, SB62 and SB63 are open and SB13 and SB14 closed, so the
virtual COM port is enabled.
Configurations
==============
nsh
---
Configures the NuttShell (nsh) located at apps/examples/nsh for the
Nucleo-F410RB board. The Configuration enables the serial interfaces
on UART2. Support for builtin applications is enabled, but in the base
configuration no builtin applications are selected (see NOTES below).
NOTES:
1. This configuration uses the mconf-based configuration tool. To
change this configuration using that tool, you should:
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
see additional README.txt files in the NuttX tools repository.
b. Execute 'make menuconfig' in nuttx/ in order to start the
reconfiguration process.
@@ -0,0 +1,3 @@
================
ST Nucleo F429ZI
================
@@ -0,0 +1,494 @@
================
ST Nucleo F446RE
================
This page discusses issues unique to NuttX configurations for the ST
NucleoF446RE boards from ST Micro. See
https://www.st.com/en/evaluation-tools/nucleo-f446re.html
NucleoF446RE:
- Microprocessor: 32-bit ARM Cortex M4 at 180MHz STM32F446RE
- Memory: 512 KB Flash and 128 KB SRAM
- ADC: 1×12-bit, 2.4 MSPS A/D converter: up to 10 channels
- DMA: 16-stream DMA controllers with FIFOs and burst support
- Timers: Up to 11 timers: up to six 16-bit, two 32-bit timers, two
watchdog timers, and a SysTick timer
- GPIO: Up to 81 I/O ports with interrupt capability
- I2C: Up to 3 × I2C interfaces
- USARTs: Up to 3 USARTs
- USARTs: Up to 3 USARTs
- SPIs: Up to 4 SPIs (2 I2S)
- SDIO interface
- USB: USB 2.0 full-speed device/host/OTG controller with on-chip PHY
- CRC calculation unit
- RTC
The NucleoF446RE also has additional DMA and SPI peripheral capabilities.
Board features, however, are identical:
- Peripherals: 1 led, 1 push button
- Debug: Serial wire debug and JTAG interfaces
- Expansion I/F Ardino and Morpho Headers
Uses a STM32F103 to provide a ST-Link for programming, debug similar to the
OpenOcd FTDI function - USB to JTAG front-end.
See https://os.mbed.com/platforms/ST-Nucleo-F446RE/ for more
information about this board.
mbed
====
The Nucleo-F401RE includes boot loader from mbed:
https://mbed.org/platforms/ST-Nucleo-F401RE/
https://mbed.org/handbook/Homepage
Using the mbed loader:
1. Connect the Nucleo-F4x1RE to the host PC using the USB connector.
2. A new file system will appear called NUCLEO; open it with Windows
Explorer (assuming that you are using Windows).
3. Drag and drop nuttx.bin into the MBED window. This will load the
nuttx.bin binary into the Nucleo-F4x1RE. The NUCLEO window will
close then re-open and the Nucleo-F4x1RE will be running the new code.
Hardware
========
..
GPIO
----
SERIAL_TX=PA_2 USER_BUTTON=PC_13
SERIAL_RX=PA_3 LED1 =PA_5
A0=PA_0 USART2RX D0=PA_3 D8 =PA_9
A1=PA_1 USART2TX D1=PA_2 D9 =PC_7
A2=PA_4 D2=PA_10 WIFI_CS=D10=PB_6 SPI_CS
A3=PB_0 WIFI_INT=D3=PB_3 D11=PA_7 SPI_MOSI
A4=PC_1 SDCS=D4=PB_5 D12=PA_6 SPI_MISO
A5=PC_0 WIFI_EN=D5=PB_4 LED1=D13=PA_5 SPI_SCK
LED2=D6=PB_10 I2C1_SDA=D14=PB_9 Probe
D7=PA_8 I2C1_SCL=D15=PB_8 Probe
From: https://mbed.org/platforms/ST-Nucleo-F401RE/
Buttons
-------
B1 USER: the user button is connected to the I/O PC13 (pin 2) of the STM32
microcontroller.
LEDs
----
The Nucleo F446RE provides a single user LED, LD2. LD2
is the green LED connected to Arduino signal D13 corresponding to MCU I/O
PA5 (pin 21) or PB13 (pin 34) depending on the STM32target.
- When the I/O is HIGH value, the LED is on.
- When the I/O is LOW, the LED is off.
These LEDs are not used by the board port unless CONFIG_ARCH_LEDS is
defined. In that case, the usage by the board port is defined in
include/board.h and src/sam_leds.c. The LEDs are used to encode OS-related
events as follows when the red LED (PE24) is available::
SYMBOL Meaning LD2
------------------- ----------------------- -----------
LED_STARTED NuttX has been started OFF
LED_HEAPALLOCATE Heap has been allocated OFF
LED_IRQSENABLED Interrupts enabled OFF
LED_STACKCREATED Idle stack created ON
LED_INIRQ In an interrupt No change
LED_SIGNAL In a signal handler No change
LED_ASSERTION An assertion failed No change
LED_PANIC The system has crashed Blinking
LED_IDLE MCU is is sleep mode Not used
Thus if LD2, NuttX has successfully booted and is, apparently, running
normally. If LD2 is flashing at approximately 2Hz, then a fatal error
has been detected and the system has halted.
Serial Consoles
===============
USART1
------
Pins and Connectors::
RXD: PA11 CN10 pin 14
PB7 CN7 pin 21
TXD: PA10 CN9 pin 3, CN10 pin 33
PB6 CN5 pin 3, CN10 pin 17
NOTE: You may need to edit the include/board.h to select different USART1
pin selections.
TTL to RS-232 converter connection::
Nucleo CN10 STM32F4x1RE
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
To configure USART1 as the console::
CONFIG_STM32_USART1=y
CONFIG_USART1_SERIALDRIVER=y
CONFIG_USART1_SERIAL_CONSOLE=y
CONFIG_USART1_RXBUFSIZE=256
CONFIG_USART1_TXBUFSIZE=256
CONFIG_USART1_BAUD=115200
CONFIG_USART1_BITS=8
CONFIG_USART1_PARITY=0
CONFIG_USART1_2STOP=0
USART2
------
Pins and Connectors::
RXD: PA3 CN9 pin 1 (See SB13, 14, 62, 63). CN10 pin 37
PD6
TXD: PA2 CN9 pin 2(See SB13, 14, 62, 63). CN10 pin 35
PD5
UART2 is the default in all of these configurations.
TTL to RS-232 converter connection::
Nucleo CN9 STM32F4x1RE
----------- ------------
Pin 1 PA3 USART2_RX *Warning you make need to reverse RX/TX on
Pin 2 PA2 USART2_TX some RS-232 converters
Solder Bridges. This configuration requires:
- SB62 and SB63 Closed: PA2 and PA3 on STM32 MCU are connected to D1 and D0
(pin 7 and pin 8) on Arduino connector CN9 and ST Morpho connector CN10
as USART signals. Thus SB13 and SB14 should be OFF.
- SB13 and SB14 Open: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
disconnected to PA3 and PA2 on STM32 MCU.
To configure USART2 as the console::
CONFIG_STM32_USART2=y
CONFIG_USART2_SERIALDRIVER=y
CONFIG_USART2_SERIAL_CONSOLE=y
CONFIG_USART2_RXBUFSIZE=256
CONFIG_USART2_TXBUFSIZE=256
CONFIG_USART2_BAUD=115200
CONFIG_USART2_BITS=8
CONFIG_USART2_PARITY=0
CONFIG_USART2_2STOP=0
USART6
------
Pins and Connectors::
RXD: PC7 CN5 pin2, CN10 pin 19
PA12 CN10, pin 12
TXD: PC6 CN10, pin 4
PA11 CN10, pin 14
To configure USART6 as the console::
CONFIG_STM32_USART6=y
CONFIG_USART6_SERIALDRIVER=y
CONFIG_USART6_SERIAL_CONSOLE=y
CONFIG_USART6_RXBUFSIZE=256
CONFIG_USART6_TXBUFSIZE=256
CONFIG_USART6_BAUD=115200
CONFIG_USART6_BITS=8
CONFIG_USART6_PARITY=0
CONFIG_USART6_2STOP=0
Virtual COM Port
----------------
Yet another option is to use UART2 and the USB virtual COM port. This
option may be more convenient for long term development, but is painful
to use during board bring-up.
Solder Bridges. This configuration requires:
- SB62 and SB63 Open: PA2 and PA3 on STM32 MCU are disconnected to D1
and D0 (pin 7 and pin 8) on Arduino connector CN9 and ST Morpho
connector CN10.
- SB13 and SB14 Closed: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
connected to PA3 and PA2 on STM32 MCU to have USART communication
between them. Thus SB61, SB62 and SB63 should be OFF.
Configuring USART2 is the same as given above.
Question: What BAUD should be configure to interface with the Virtual
COM port? 115200 8N1?
Default
-------
As shipped, SB62 and SB63 are open and SB13 and SB14 closed, so the
virtual COM port is enabled.
Shields
=======
RS-232 from Cutedigi.com
------------------------
Supports a single RS-232 connected via::
Nucleo CN9 STM32F4x1RE Cutedigi
----------- ------------ --------
Pin 1 PA3 USART2_RX RXD
Pin 2 PA2 USART2_TX TXD
Support for this shield is enabled by selecting USART2 and configuring
SB13, 14, 62, and 63 as described above under "Serial Consoles"
Itead Joystick Shield
---------------------
See http://imall.iteadstudio.com/im120417014.html for more information
about this joystick.
Itead Joystick Connection::
--------- ----------------- ---------------------------------
ARDUINO ITEAD NUCLEO-F4x1
PIN NAME SIGNAL SIGNAL
--------- ----------------- ---------------------------------
D3 Button E Output PB3
D4 Button D Output PB5
D5 Button C Output PB4
D6 Button B Output PB10
D7 Button A Output PA8
D8 Button F Output PA9
D9 Button G Output PC7
A0 Joystick Y Output PA0 ADC1_0
A1 Joystick X Output PA1 ADC1_1
--------- ----------------- ---------------------------------
All buttons are pulled on the shield. A sensed low value indicates
when the button is pressed.
NOTE: Button F cannot be used with the default USART1 configuration
because PA9 is configured for USART1_RX by default. Use select
different USART1 pins in the board.h file or select a different
USART or select CONFIG_NUCLEO_F401RE_AJOY_MINBUTTONS which will
eliminate all but buttons A, B, and C.
Itead Joystick Signal interpretation::
--------- ----------------------- ---------------------------
BUTTON TYPE NUTTX ALIAS
--------- ----------------------- ---------------------------
Button A Large button A JUMP/BUTTON 3
Button B Large button B FIRE/BUTTON 2
Button C Joystick select button SELECT/BUTTON 1
Button D Tiny Button D BUTTON 6
Button E Tiny Button E BUTTON 7
Button F Large Button F BUTTON 4
Button G Large Button G BUTTON 5
--------- ----------------------- ---------------------------
Itead Joystick configuration settings::
System Type -> STM32 Peripheral Support
CONFIG_STM32_ADC1=y : Enable ADC1 driver support
Drivers
CONFIG_ANALOG=y : Should be automatically selected
CONFIG_ADC=y : Should be automatically selected
CONFIG_INPUT=y : Select input device support
CONFIG_INPUT_AJOYSTICK=y : Select analog joystick support
There is nothing in the configuration that currently uses the joystick.
For testing, you can add the following configuration options to enable the
analog joystick example at apps/examples/ajoystick::
CONFIG_NSH_ARCHINIT=y
CONFIG_EXAMPLES_AJOYSTICK=y
CONFIG_EXAMPLES_AJOYSTICK_DEVNAME="/dev/ajoy0"
STATUS:
2014-12-04:
- Without ADC DMA support, it is not possible to sample both X and Y
with a single ADC. Right now, only one axis is being converted.
- There is conflicts with some of the Arduino data pins and the
default USART1 configuration. I am currently running with USART1
but with CONFIG_NUCLEO_F401RE_AJOY_MINBUTTONS to eliminate the
conflict.
- Current showstopper: I appear to be getting infinite interrupts as
soon as joystick button interrupts are enabled.
Configurations
==============
nsh:
----
Configures the NuttShell (nsh) located at apps/examples/nsh for the
Nucleo-F446RE board. The Configuration enables the serial interfaces
on UART2. Support for builtin applications is enabled, but in the base
configuration no builtin applications are selected (see NOTES below).
NOTES:
1. This configuration uses the mconf-based configuration tool. To
change this configuration using that tool, you should:
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
see additional README.txt files in the NuttX tools repository.
b. Execute 'make menuconfig' in nuttx/ in order to start the
reconfiguration process.
2. By default, this configuration uses the ARM EABI toolchain
for Linux. That can easily be reconfigured, of course.::
CONFIG_HOST_LINUX=y : Builds under Linux
CONFIG_ARM_TOOLCHAIN_GNU_EABI=y : GNU EABI toolchain for Linux
3. Although the default console is USART2 (which would correspond to
the Virtual COM port) I have done all testing with the console
device configured for USART1 (see instruction above under "Serial
Consoles). I have been using a TTL-to-RS-232 converter connected
as shown below::
Nucleo CN10 STM32F446RE
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
can
---
This is basically an nsh configuration (see above) with added support
for CAN driver. Both CAN 1 (RX: PB_8, TX: PB_9) and CAN 2 (RX: PB_5, TX: PB_6)
are turn on.
Functionality of CAN driver can be tested by calling application
"can" in NuttShell. This application sends 100 messages over CAN 1.
dac
---
This is an nsh configuration (see above) with added support
for digital analog converter driver.
Functionality of DAC driver can be tested by calling application
"dac" in NuttShell. GPIO_DAC1_OUT1 pin is set on PA_4.
gpio
----
This is an nsh configuration (see above) with added support for GPIO
driver and GPIO test application "gpio". Three pins are configured for
testing purposes::
PA_7 - GPIO_INPUT
PB_6 - GPIO_OUTPUT
PC_7 - GPIO_INPUT_INTERRUPT
ihm08m1_f32 and ihm08m1_b16
---------------------------
These examples are dedicated for the X-NUCLEO-IHM08M1 expansion board with
L6398 gate drivers and discrete transistors.
WARNING: L6398 gate drivers require channel 2 negative polarisation and
negative sign for the deadtime. Make sure that your gate drivers logic
is compatible with this configuration.
X-NUCLEO-IHM08M1 must be configured to work with FOC and 3-shunt
resistors. See ST documentation for details.
Pin configuration for the X-NUCLEO-IHM08M1 (TIM1 configuration)::
Board Function Chip Function Chip Pin Number
------------- ---------------- -----------------
Phase U high TIM1_CH1 PA8
Phase U low TIM1_CH1N PA7
Phase V high TIM1_CH2 PA9
Phase V low TIM1_CH2N PB0
Phase W high TIM1_CH3 PA10
Phase W low TIM1_CH3N PB1
Current U ADC1_IN0 PA0
Current V ADC1_IN11 PC1
Current W ADC1_IN10 PC0
Temperature ADC1_IN12 PC2
VBUS ADC1_IN1 PA1
BEMF1 (NU) PC3
BEMF2 (NU) PC4
BEMF3 (NU) PC5
LED GPIO_PB2 PB2
+3V3 (CN7_16)
GND (CN7_20)
GPIO_BEMF (NU) PC9
ENCO_A/HALL_H1 TIM2_CH1 PA15
ENCO_B/HALL_H2 TIM2_CH2 PB3
ENCO_Z/HALL_H3 TIM2_CH3 PB10
DAC (NU) PA5
GPIO3 (NU) PB13
CPOUT (NU) PA12
BKIN1 (NU) PA6
BKIN2 (NU) PA11
BKIN3 (NU) PB14
POT/DAC DAC1_CH1/ADC1_IN4 PA4
CURR_REF (NU) PB4
DEBUG0 GPIO PB12
DEBUG1 GPIO PB9
DEBUG2 GPIO PC6
DEBUG3 GPIO PB5
DEBUG4 GPIO PC8
Current shunt resistance = 0.01
Current sense gain = -5.18 (inverted current)
Vbus sense gain = 9.31k/(9.31k+169k) = 0.0522
Vbus min = 10V
Vbus max = 48V
Iout max = 15A RMS
IPHASE_RATIO = 1/(R_shunt*gain) = -19.3
VBUS_RATIO = 1/VBUS_gain = 19.152
For now only 3-shunt resistors configuration is supported.
lcd
---
This is basically an nsh configuration (see above) with added support
of ILI9225 176x220 TFT display and test framebuffer application.
Display connection is set to SPI 3 and pinout is following::
CS D8
RST D6
RS D7
SDA D4
CLK D3
Framebuffer application can be started from terminal by typing "fb".
pwm
---
This is an nsh configuration (see above) with added capability of pulse width
modulation. PWM output is on Timer 3 channel 1, which is pin PA_6 (D12) on
Nucleo board. Example program can be stared by "pwm" command.
@@ -0,0 +1,210 @@
=================
Olimex STM32-E407
=================
The Olimex STM32-E407 configuration is based on the configuration
olimex-stm32-h407 and stm32f4discovery.
Configurations
==============
Instantiating Configurations
----------------------------
Each Olimex-STM32-E407 configuration is maintained in a sub-directory and
can be selected as follow::
tools/configure.sh [OPTIONS] olimex-stm32-e407:<subdir>
Typical options include -l for a Linux host platform or -c for Cygwin
host platform. See 'tools/configure.sh -h' for other options. And
<subdir> is one of the sub-directories listed below.
Compile Firmware
----------------
Once you've set the proper configuration, you just need to execute the next
command::
make
If everything goes find, it should return the next two files::
nuttx.hex
nuttx.bin
You can return more kinds of files by setting on menuconfig.
Flashing the Board
------------------
You can flash this board in different ways, but the easiest way is using
ARM-USB-TINY-H JTAG flasher device.
Connect this device to the JTAG connector and type the next command::
openocd -f interface/ftdi/olimex-arm-usb-tiny-h.cfg -f target/stm32f4x.cfg -c init -c "reset halt" -c "flash write_image erase nuttx.bin 0x08000000"
Configuration Directories
-------------------------
nsh
---
Configures the NuttShell (nsh) located at apps/examples/nsh. This
configuration enables a console on UART2. Support for
builtin applications is enabled, but in the base configuration no
builtin applications are selected.
usbnsh
------
Configures the NuttShell (nsh) located at apps/examples/nsh. This
configuration enables a console on USB_OTG1. Support for
builtin applications is enabled, but in the base configuration no
builtin applications are selected.
netnsh
------
Configures the NuttShell (nsh) located at examples/nsh. This
configuration is focused on network testing.
bmp180
------
This is a configuration example for the BMP180 barometer sensor. This
sensor works with I2C, you need to do the next connections::
BMP180 VIN -> Board 3.3V
BMP180 GND -> Board GND
BMP180 SCL -> Board PB6 (Arduino header D1)
BMP180 SDA -> Board PB7 (Arduino header D0)
This example is configured to work with the USBNSH instead of UART NSH, so
the console will be shown over the USB_OTG1 connector.
On the console, type "ls /dev " and if the registration process goes fine,
you should see a device called "press0". Now execute the app
BMP180 to see the ambient pressure value.
dac
---
This is a configuration example to use the DAC1 of the board. The DAC1
is attached to the PA4 pin (Arduino header D10).
This example is configured to work with the USBNSH instead of UART NSH, so
the console will be shown over the USB_OTG1 connector.
On the console, type "ls /dev " and if the registration process goes fine,
you should see a device called "dac0". Now execute the app
dac put a value at the output.
ina219
------
This is a configuration example for the INA219 DC current sensor. This
sensor works with I2C, you need to do the next connections::
INA219 VIN -> Board 3.3V
INA219 GND -> Board GND
INA219 SCL -> Board PB6 (Arduino header D1)
INA219 SDA -> Board PB7 (Arduino header D0)
This example is configured to work with the USBNSH instead of UART NSH, so
the console will be shown over the USB_OTG1 connector.
On the console, type "ls /dev " and if the registration process goes fine,
you should see a device called "ina219". Now execute the app
ina219 to see the ambient pressure value.
timer
-----
This configuration set the proper configuration to use the timer1 of the
board. This example is configured to work with the USBNSH instead of
UART NSH, so the console will be shown over the USB_OTG1 connector.
On the console, type "ls /dev " and if the registration process goes fine,
you should see a device called "timer1".
mrf24j40-mac
------------
This configuration set the proper configuration to set the 802.15.4
communication layer with the MRF24J40 radio. This radio works with
SPI, you need to do the next connections::
MRF24J40 VCC -> Board 3.3V
MRF24J40 GND -> Board GND
MRF24J40 SCLK -> Board PA5 (Arduino header D13)
MRF24J40 MISO -> Board PA6 (Arduino header D12)
MRF24J40 MOSI -> Board PB5 (Arduino header D11)
MRF24J40 CS -> Board PA4 (Arduino header D10)
MRF24J40 INT -> Board PG12 (Arduino header D8)
This example is configured to work with the USBNSH instead of UART NSH,
so the console will be shown over the USB_OTG1 connector.
Once you're on the console, you need to check if the initialization
process was fine. To do so, you need to type "ls /dev" and you should
see a device call "ieee0". At this point we need to set-up the network,
follow the next steps::
This is an example of how to configure a coordinator:
i8sak /dev/ieee0 startpan cd:ab
i8sak set chan 11
i8sak set saddr 42:01
i8sak acceptassoc
This is an example of how to configure the endpoint:
i8sak /dev/ieee0
i8sak set chan 11
i8sak set panid cd:ab
i8sak set saddr 42:02
i8sak set ep_saddr 42:01
i8sak assoc
mrf24j40-6lowpan
----------------
This configuration set the proper configuration to use 6lowpan protocol with the MRF24J40
radio. This radio works with SPI, you need to do the next connections::
MRF24J40 VCC -> Board 3.3V
MRF24J40 GND -> Board GND
MRF24J40 SCLK -> Board PA5 (Arduino header D13)
MRF24J40 MISO -> Board PA6 (Arduino header D12)
MRF24J40 MOSI -> Board PB5 (Arduino header D11)
MRF24J40 CS -> Board PA4 (Arduino header D10)
MRF24J40 INT -> Board PG12 (Arduino header D8)
This example is configured to work with the USBNSH instead of UART NSH, so
the console will be shown over the USB_OTG1 connector.
Once you're on the console, you need to check if the initialization process
was fine. To do so, you need to type "ls /dev" and you should see a device
call "ieee0". At this point we need to set-up the network, follow the next steps::
This is an example of how to configure a coordinator:
i8sak wpan0 startpan cd:ab
i8sak set chan 11
i8sak set saddr 42:01
i8sak acceptassoc
When the association was complete, you need to bring-up the network:
ifup wpan0
This is an example of how to configure the endpoint:
i8sak wpan0
i8sak set chan 11
i8sak set panid cd:ab
i8sak set saddr 42:02
i8sak set ep_saddr 42:01
i8sak assoc
When the association was complete, you need to bring-up the network:
ifup wpan0
If you execute the command "ifconfig", you will be able to see the info of the WPAN0 interface
and see the assigned IP. This interface can be use with an UDP or TCP server/client application.
@@ -1,5 +1,6 @@
README
======
=================
Olimex STM32-P207
=================
The NuttX configuration for the Olimex STM32-H405 is based on the configuration
Olimex STM32-P207.
@@ -15,14 +16,13 @@ Make sure that '# CONFIG_NSH_CONDEV is not set' is in the .config file - it defa
to '/dev/console' which makes problems with the shell over USB.
The following peripherals are enabled in this configuration.
- LED: Shows the system status
- LED: Shows the system status
- Button: Built in app 'buttons' works.
- Button: Built in app 'buttons' works.
- ADC: ADC1 samples ADC_IN1. Built in app 'adc' works.
- ADC: ADC1 samples ADC_IN1. Built in app 'adc' works.
- USB-FS-OTG: The console is running on the virtual serial port. Note that you
have to press enter three times until NSH appears.
- USB-FS-OTG: The console is running on the virtual serial port. Note that you
have to press enter three times until NSH appears.
- CAN: Built in app 'can' is enabled but not tested, since no CAN transceiver
is on board.
- CAN:Built in app 'can' is enabled but not tested, since no CAN transceiver is on board.
@@ -1,5 +1,6 @@
README
======
=================
Olimex STM32-H407
=================
The Olimex STM32-H407 configuration is based on
stm32Fdiscovery and Olimex STM32-H405.
@@ -10,13 +11,6 @@ This release provides baseline for H407 12MHZ clock in include/board.h
nsh - Only basic shell response tested on USART2
nsh_uext - Basic shell response tested on USART6 (UEXT)
Development Environment
=======================
Either Linux or Cygwin on Windows can be used for the development environment.
The source has been built only using the GNU toolchain (see below). Other
toolchains will likely cause problems.
LEDs
====
@@ -37,6 +31,3 @@ or you can use USART6 exposed via UEXT connector.
Olimex offers MOD-RS232 voltage level converter for the UEXT so it can be
attached to computer serial port.
STM32-H407-specific Configuration Options
===============================================
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,82 @@
=========
OMNIBUSF4
=========
"OmnibusF4" is not a product name per se, but rather a design spec
that many product vendors within the drone flight management unit
(FMU) community adhere to. The spec defines the major components, and
how those components are wired into the STM32F405RGT6 microcontroller.
Airbot is one such vendor, and they publish a schematic here:
http://bit.ly/obf4pro
Other software that supports the OmnibusF4 family include Betaflight,
iNAV, and many others. PX4 recently added support as well. No code
from any of those sources is included in this port.
Since OmnibusF4 is a drone FMU, most of its IO is already allocated to
FMU-specific tasks. As such, we don't need to make the board support
package as flexible as, say, an STM32F4 Discovery board.
..
The following are some of the committed IO pins. Most of the pins not
mentioned here are inaccessible, the details vary by board vendor:
io peripheral signal notes
==================================
XIN 8MHz crystal oscillator
PB0 TIM3 CH3 S1_OUT motor 1 PWM output
PB1 TIM3 CH4 S2_OUT motor 2 PWM output
PA3 TIM2 CH4 S3_OUT motor 3 PWM output
PA2 TIM2 CH3 S4_OUT motor 4 PWM output
PA1 TIM2 CH2 S5_OUT motor 5 PWM output
PA8 TIM1 CH4 S6_OUT motor 6 PWM output
PA4 SPI1 SPI1_NSS mpu6000
PA5 SPI1 SPI1_SCL
PA6 SPI1 SPI1_MISO
PA7 SPI1 SPI1_MOSI
PC4 GPIO GYRO_INT mpu6000 EXTI
PB10 UART3/I2C UART3_TX ttl UART tx or i2c_scl (used as console)
PB11 UART3/I2C UART3_RX ttl UART rx or i2c_sda (used as console)
PB9 RC_CH2 (rx pwm input)
PB8 RC_CH1 (rx pwm input)
PC9 RC_CH6 (rx pwm input)
PC8 RC_CH5 (rx pwm input)
PC7 RC_CH4 or USART6_RX (ttl)
PC6 RC_CH3 or USART6_TX (ttl)
PB7 GPIO SD_DET SD card detection pin (low when card inserted)
PB5 GPIO STAT LED output (active low)
PB4 GPIO BUZZER buzzer output (active low)
PD2 GPIO LED_STRIP one-wire interface for LED strips
PC12 SPI3 SPI3_MOSI bmp280 barometer (if populated) and/or max7456 OSD
PC11 SPI3 SPI3_MISO
PC10 SPI3 SPI3_SCL
PA15 GPIO SPI3_NSS OSD NSS
PB3 GPIO BARO_CS bmp280 NSS (if populated)
PA12 OTG USB_DP
PA11 OTG USB_DN
PA10 UART1 USART1_RX SBUS_IN (through inverter) or PPM
PA9 UART1 USART1_TX
PB15 SPI2 SPI2_MOSI sd/mmc card interface
PB14 SPI2 SPI2_MISO
PB13 SPI2 SPI2_SCLK
PB12 SPI2 SPI2_NSS
Build Instructions
==================
The boards/arm/stm32/omnibusf4/nsh/defconfig file creates a basic setup, and
includes drivers for all supported onboard chips. The console and
command prompt are sent to USART3.
File diff suppressed because it is too large Load Diff
@@ -1,19 +1,10 @@
README
======
=================
stm32f411-minimum
=================
This README discusses issues unique to NuttX configurations for the
WeAct Studio MiniF4 minimum system development board.
Contents
========
- Board information
- LEDs
- UARTs
- USB
- SPI NOR Flash
- Configurations
Board information
=================
@@ -34,14 +25,14 @@ https://stm32-base.org/boards/STM32F401CEU6-WeAct-Black-Pill-V3.0.html
The board features:
- On-board 64 Mbits (8 MBytes) External SPI-NOR Flash (optional),
- nRST reset button and BOOT0 ST BootROM entry button,
- One user LED and one user push-button,
- HSE 25 Mhz and LSE 32.768 kHz,
- USB OTG FS with micro-AB connector,
- Around 30 remappable GPIOs on 2.54mm headers (after excluding 7 power pins,
two LSE pins, the LED pin, NRST, BOOT1 and the SWD header),
- Serial Wire Debug header for use with an external SWD/JTAG adapter.
- On-board 64 Mbits (8 MBytes) External SPI-NOR Flash (optional),
- nRST reset button and BOOT0 ST BootROM entry button,
- One user LED and one user push-button,
- HSE 25 Mhz and LSE 32.768 kHz,
- USB OTG FS with micro-AB connector,
- Around 30 remappable GPIOs on 2.54mm headers (after excluding 7 power pins,
two LSE pins, the LED pin, NRST, BOOT1 and the SWD header),
- Serial Wire Debug header for use with an external SWD/JTAG adapter.
As F4 series have a USB DFuSe-capable BootROM [AN2606], the board can be flashed
via `dfu-util` over USB, or via `stm32flash` over UART without any debuggers.
@@ -49,33 +40,43 @@ via `dfu-util` over USB, or via `stm32flash` over UART without any debuggers.
LEDs
====
The STM32F411 Minimum board has only one software controllable LED on PC13.
This LED can be used by the board port when CONFIG_ARCH_LEDS option is
enabled.
The STM32F411 Minimum board has only one software controllable LED on PC13.
This LED can be used by the board port when CONFIG_ARCH_LEDS option is
enabled.
If enabled the LED is simply turned on when the board boots
successfully, and is blinking on panic / assertion failed.
If enabled the LED is simply turned on when the board boots
successfully, and is blinking on panic / assertion failed.
UARTs
=====
UART/USART PINS
---------------
USART1
------
USART1
TX PA9
RX PA10
USART2
CTS PA0
RTS PA1
TX PA2
RX PA3
CK PA4
========== =====
UART/USART PINS
========== =====
TX PA9
RX PA10
========== =====
USART2
------
========== =====
UART/USART PINS
========== =====
CTS PA0
RTS PA1
TX PA2
RX PA3
CK PA4
========== =====
Default USART/UART Configuration
--------------------------------
USART1 (RX & TX only) is available through pins PA9 (TX) and PA10 (RX).
USART1 (RX & TX only) is available through pins PA9 (TX) and PA10 (RX).
USB
===
@@ -105,17 +106,18 @@ Configurations
==============
Each stm32f411-minimum configuration is maintained in a sub-directory and
can be selected as follow:
can be selected as follow::
tools/configure.sh stm32f411-minimum:<subdir>
Where <subdir> is one of the following:
Configuration Directories
-------------------------
Configuration Directories
-------------------------
nsh:
---
Configures the NuttShell (nsh) located at apps/examples/nsh. This
configuration enables a serial console on UART1.
nsh
---
Configures the NuttShell (nsh) located at apps/examples/nsh. This
configuration enables a serial console on UART1.
@@ -1,5 +1,6 @@
README
======
=======================
ST STM32F411E-Discovery
=======================
This README discusses issues unique to NuttX configurations for the STMicro
STM32F411E-Discovery board. See
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
@@ -1,6 +1,6 @@
========
STM32WL5
========
===========
ST STM32WL5
===========
The STM32WL5 is a dual CPU (not core!) chip based on ARM Cortex-M4 and
Cortex-M0 with integrated sub-GHz radio for LoRa (G)FSK, (G)MSK and BPSK
File diff suppressed because it is too large Load Diff
-250
View File
@@ -1,250 +0,0 @@
README
======
This README discusses issues unique to NuttX configurations for the ST
NucleoF410RB board from ST Micro. See
http://www.st.com/en/evaluation-tools/nucleo-f410rb.html
NucleoF410RB:
Microprocessor: 32-bit ARM Cortex M4 at 100MHz STM32F410RB
Memory: 128 KB Flash and 32 KB SRAM
ADC: 1x12-bit, 2.4 MSPS A/D converter: up to 16 channels
DAC: 1x12-bit, 2.4 MSPS A/D converter: up to 1 channels
DMA: 16-stream DMA controllers with FIFOs and burst support
Timers: Up to 11 timers: up to 5 16-bit, 1 32-bit timers, two
watchdog timers, and a SysTick timer
GPIO: Up to 81 I/O ports with interrupt capability
I2C: Up to 3 I2C interfaces
USARTs: Up to 3 USARTs
SPIs: Up to 4 SPIs (2 I2S)
CRC calculation unit
RTC
Peripherals: 1 led, 1 push button
Debug: Serial wire debug and JTAG interfaces
Expansion I/F Ardino and Morpho Headers
Uses a STM32F103 to provide a ST-Link for programming, debug similar to the
OpenOcd FTDI function - USB to JTAG front-end.
See https://os.mbed.com/platforms/ST-Nucleo-F410RB for more
information about this board.
Contents
========
- Nucleo-64 Boards
- Button
- LED
- USARTs and Serial Consoles
- Configurations
Nucleo-64 Boards
================
The Nucleo-F410RB board is member of the Nucleo-64 board family. The
Nucleo-64 is a standard board for use with several STM32 parts in the
LQFP64 package. Variants include
Order code Targeted STM32
------------- --------------
NUCLEO-F030R8 STM32F030R8T6
NUCLEO-F070RB STM32F070RBT6
NUCLEO-F072RB STM32F072RBT6
NUCLEO-F091RC STM32F091RCT6
NUCLEO-F103RB STM32F103RBT6
NUCLEO-F302R8 STM32F302R8T6
NUCLEO-F303RE STM32F303RET6
NUCLEO-F334R8 STM32F334R8T6
NUCLEO-F401RE STM32F401RET6
NUCLEO-F410RB STM32F410RBT6
NUCLEO-F411RE STM32F411RET6
NUCLEO-F446RE STM32F446RET6
NUCLEO-L053R8 STM32L053R8T6
NUCLEO-L073RZ STM32L073RZT6
NUCLEO-L152RE STM32L152RET6
NUCLEO-L452RE STM32L452RET6
NUCLEO-L476RG STM32L476RGT6
Hardware
========
Buttons
-------
B1 USER: the user button is connected to the I/O PC13 (pin 2) of the STM32
microcontroller.
LEDs
----
The Nucleo F410RB provide a single user LED, LD2. LD2
is the green LED connected to Arduino signal D13 corresponding to MCU I/O
PA5 (pin 21) or PB13 (pin 34) depending on the STM32target.
- When the I/O is HIGH value, the LED is on.
- When the I/O is LOW, the LED is off.
These LEDs are not used by the board port unless CONFIG_ARCH_LEDS is
defined. In that case, the usage by the board port is defined in
include/board.h and src/sam_leds.c. The LEDs are used to encode OS-related
events as follows when the red LED (PE24) is available:
SYMBOL Meaning LD2
------------------- ----------------------- -----------
LED_STARTED NuttX has been started OFF
LED_HEAPALLOCATE Heap has been allocated OFF
LED_IRQSENABLED Interrupts enabled OFF
LED_STACKCREATED Idle stack created ON
LED_INIRQ In an interrupt No change
LED_SIGNAL In a signal handler No change
LED_ASSERTION An assertion failed No change
LED_PANIC The system has crashed Blinking
LED_IDLE MCU is is sleep mode Not used
Thus if LD2, NuttX has successfully booted and is, apparently, running
normally. If LD2 is flashing at approximately 2Hz, then a fatal error
has been detected and the system has halted.
Serial Consoles
===============
USART1
------
Pins and Connectors:
RXD: PA11 CN10 pin 14
PB7 CN7 pin 21
TXD: PA10 CN9 pin 3, CN10 pin 33
PB6 CN5 pin 3, CN10 pin 17
NOTE: You may need to edit the include/board.h to select different USART1
pin selections.
TTL to RS-232 converter connection:
Nucleo CN10 STM32F410RB
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
To configure USART1 as the console:
CONFIG_STM32_USART1=y
CONFIG_USART1_SERIALDRIVER=y
CONFIG_USART1_SERIAL_CONSOLE=y
CONFIG_USART1_RXBUFSIZE=256
CONFIG_USART1_TXBUFSIZE=256
CONFIG_USART1_BAUD=115200
CONFIG_USART1_BITS=8
CONFIG_USART1_PARITY=0
CONFIG_USART1_2STOP=0
USART2
-----
Pins and Connectors:
RXD: PA3 CN9 pin 1 (See SB13, 14, 62, 63). CN10 pin 37
PD6
TXD: PA2 CN9 pin 2(See SB13, 14, 62, 63). CN10 pin 35
PD5
UART2 is the default in all of these configurations.
TTL to RS-232 converter connection:
Nucleo CN9 STM32F410RB
----------- ------------
Pin 1 PA3 USART2_RX *Warning you make need to reverse RX/TX on
Pin 2 PA2 USART2_TX some RS-232 converters
Solder Bridges. This configuration requires:
- SB62 and SB63 Closed: PA2 and PA3 on STM32 MCU are connected to D1 and D0
(pin 7 and pin 8) on Arduino connector CN9 and ST Morpho connector CN10
as USART signals. Thus SB13 and SB14 should be OFF.
- SB13 and SB14 Open: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
disconnected to PA3 and PA2 on STM32 MCU.
To configure USART2 as the console:
CONFIG_STM32_USART2=y
CONFIG_USART2_SERIALDRIVER=y
CONFIG_USART2_SERIAL_CONSOLE=y
CONFIG_USART2_RXBUFSIZE=256
CONFIG_USART2_TXBUFSIZE=256
CONFIG_USART2_BAUD=115200
CONFIG_USART2_BITS=8
CONFIG_USART2_PARITY=0
CONFIG_USART2_2STOP=0
USART6
------
Pins and Connectors:
RXD: PC7 CN5 pin2, CN10 pin 19
PA12 CN10, pin 12
TXD: PC6 CN10, pin 4
PA11 CN10, pin 14
To configure USART6 as the console:
CONFIG_STM32_USART6=y
CONFIG_USART6_SERIALDRIVER=y
CONFIG_USART6_SERIAL_CONSOLE=y
CONFIG_USART6_RXBUFSIZE=256
CONFIG_USART6_TXBUFSIZE=256
CONFIG_USART6_BAUD=115200
CONFIG_USART6_BITS=8
CONFIG_USART6_PARITY=0
CONFIG_USART6_2STOP=0
Virtual COM Port
----------------
Yet another option is to use UART2 and the USB virtual COM port. This
option may be more convenient for long term development, but is painful
to use during board bring-up.
Solder Bridges. This configuration requires:
- SB62 and SB63 Open: PA2 and PA3 on STM32 MCU are disconnected to D1
and D0 (pin 7 and pin 8) on Arduino connector CN9 and ST Morpho
connector CN10.
- SB13 and SB14 Closed: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
connected to PA3 and PA2 on STM32 MCU to have USART communication
between them. Thus SB61, SB62 and SB63 should be OFF.
Configuring USART2 is the same as given above.
Question: What BAUD should be configure to interface with the Virtual
COM port? 115200 8N1?
Default
-------
As shipped, SB62 and SB63 are open and SB13 and SB14 closed, so the
virtual COM port is enabled.
Configurations
==============
nsh:
---------
Configures the NuttShell (nsh) located at apps/examples/nsh for the
Nucleo-F410RB board. The Configuration enables the serial interfaces
on UART2. Support for builtin applications is enabled, but in the base
configuration no builtin applications are selected (see NOTES below).
NOTES:
1. This configuration uses the mconf-based configuration tool. To
change this configuration using that tool, you should:
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
see additional README.txt files in the NuttX tools repository.
b. Execute 'make menuconfig' in nuttx/ in order to start the
reconfiguration process.
-253
View File
@@ -1,253 +0,0 @@
README
======
This README discusses issues unique to NuttX configurations for the ST
NucleoF410RB board from ST Micro. See
http://www.st.com/en/evaluation-tools/nucleo-f412zg.html
NucleoF412ZG:
Microprocessor: 32-bit ARM Cortex M4 at 100MHz STM32F412ZG
Memory: 1 MB Flash and 256 KB SRAM
ADC: 1x12-bit, 2.4 MSPS A/D converter: up to 16 channels
DMA: 2x8-stream DMA controllers with FIFOs and burst support
Timers: Up to 17 timers: up to 12 16-bit, 2 32-bit timers, two
watchdog timers, and a SysTick timer
GPIO: Up to 114 I/O ports with interrupt capability
I2C: Up to 4 I2C interfaces
USARTs: Up to 4 USARTs
SPIs: Up to 5 SPIs (5 I2S)
SDIO interface (SD/MMC/eMMC)
Advanced connectivity: USB 2.0 full-speed device/host/OTG controller with PHY
2x CAN (2.0B Active)
True random number generator
CRC calculation unit
96-bit unique ID
RTC
JAKE: TODO
See:
https://www.st.com/content/ccc/resource/technical/document/user_manual/group0/26/49/90/2e/33/0d/4a/da/DM00244518/files/DM00244518.pdf/jcr:content/translations/en.DM00244518.pdf
Peripherals: 3 led, 2 push button
Debug: Serial wire debug and JTAG interfaces
Expansion I/F Ardino and Morpho Headers
Contents
========
- Nucleo-64 Boards
- Button
- LED
- USARTs and Serial Consoles
- Configurations
Nucleo-64 Boards
================
The Nucleo-F410RB board is member of the Nucleo-64 board family. The
Nucleo-64 is a standard board for use with several STM32 parts in the
LQFP64 package. Variants include
Order code Targeted STM32
------------- --------------
NUCLEO-F030R8 STM32F030R8T6
NUCLEO-F070RB STM32F070RBT6
NUCLEO-F072RB STM32F072RBT6
NUCLEO-F091RC STM32F091RCT6
NUCLEO-F103RB STM32F103RBT6
NUCLEO-F302R8 STM32F302R8T6
NUCLEO-F303RE STM32F303RET6
NUCLEO-F334R8 STM32F334R8T6
NUCLEO-F401RE STM32F401RET6
NUCLEO-F410RB STM32F410RBT6
NUCLEO-F411RE STM32F411RET6
NUCLEO-F446RE STM32F446RET6
NUCLEO-L053R8 STM32L053R8T6
NUCLEO-L073RZ STM32L073RZT6
NUCLEO-L152RE STM32L152RET6
NUCLEO-L452RE STM32L452RET6
NUCLEO-L476RG STM32L476RGT6
Hardware
========
Buttons
-------
B1 USER: the user button is connected to the I/O PC13 (pin 2) of the STM32
microcontroller.
LEDs
----
The Nucleo F410RB provide a single user LED, LD2. LD2
is the green LED connected to Arduino signal D13 corresponding to MCU I/O
PA5 (pin 21) or PB13 (pin 34) depending on the STM32target.
- When the I/O is HIGH value, the LED is on.
- When the I/O is LOW, the LED is off.
These LEDs are not used by the board port unless CONFIG_ARCH_LEDS is
defined. In that case, the usage by the board port is defined in
include/board.h and src/sam_leds.c. The LEDs are used to encode OS-related
events as follows when the red LED (PE24) is available:
SYMBOL Meaning LD2
------------------- ----------------------- -----------
LED_STARTED NuttX has been started OFF
LED_HEAPALLOCATE Heap has been allocated OFF
LED_IRQSENABLED Interrupts enabled OFF
LED_STACKCREATED Idle stack created ON
LED_INIRQ In an interrupt No change
LED_SIGNAL In a signal handler No change
LED_ASSERTION An assertion failed No change
LED_PANIC The system has crashed Blinking
LED_IDLE MCU is is sleep mode Not used
Thus if LD2, NuttX has successfully booted and is, apparently, running
normally. If LD2 is flashing at approximately 2Hz, then a fatal error
has been detected and the system has halted.
Serial Consoles
===============
USART1
------
Pins and Connectors:
RXD: PA11 CN10 pin 14
PB7 CN7 pin 21
TXD: PA10 CN9 pin 3, CN10 pin 33
PB6 CN5 pin 3, CN10 pin 17
NOTE: You may need to edit the include/board.h to select different USART1
pin selections.
TTL to RS-232 converter connection:
Nucleo CN10 STM32F410RB
----------- ------------
Pin 21 PA9 USART1_RX *Warning you make need to reverse RX/TX on
Pin 33 PA10 USART1_TX some RS-232 converters
Pin 20 GND
Pin 8 U5V
To configure USART1 as the console:
CONFIG_STM32_USART1=y
CONFIG_USART1_SERIALDRIVER=y
CONFIG_USART1_SERIAL_CONSOLE=y
CONFIG_USART1_RXBUFSIZE=256
CONFIG_USART1_TXBUFSIZE=256
CONFIG_USART1_BAUD=115200
CONFIG_USART1_BITS=8
CONFIG_USART1_PARITY=0
CONFIG_USART1_2STOP=0
USART2
-----
Pins and Connectors:
RXD: PA3 CN9 pin 1 (See SB13, 14, 62, 63). CN10 pin 37
PD6
TXD: PA2 CN9 pin 2(See SB13, 14, 62, 63). CN10 pin 35
PD5
UART2 is the default in all of these configurations.
TTL to RS-232 converter connection:
Nucleo CN9 STM32F410RB
----------- ------------
Pin 1 PA3 USART2_RX *Warning you make need to reverse RX/TX on
Pin 2 PA2 USART2_TX some RS-232 converters
Solder Bridges. This configuration requires:
- SB62 and SB63 Closed: PA2 and PA3 on STM32 MCU are connected to D1 and D0
(pin 7 and pin 8) on Arduino connector CN9 and ST Morpho connector CN10
as USART signals. Thus SB13 and SB14 should be OFF.
- SB13 and SB14 Open: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
disconnected to PA3 and PA2 on STM32 MCU.
To configure USART2 as the console:
CONFIG_STM32_USART2=y
CONFIG_USART2_SERIALDRIVER=y
CONFIG_USART2_SERIAL_CONSOLE=y
CONFIG_USART2_RXBUFSIZE=256
CONFIG_USART2_TXBUFSIZE=256
CONFIG_USART2_BAUD=115200
CONFIG_USART2_BITS=8
CONFIG_USART2_PARITY=0
CONFIG_USART2_2STOP=0
USART6
------
Pins and Connectors:
RXD: PC7 CN5 pin2, CN10 pin 19
PA12 CN10, pin 12
TXD: PC6 CN10, pin 4
PA11 CN10, pin 14
To configure USART6 as the console:
CONFIG_STM32_USART6=y
CONFIG_USART6_SERIALDRIVER=y
CONFIG_USART6_SERIAL_CONSOLE=y
CONFIG_USART6_RXBUFSIZE=256
CONFIG_USART6_TXBUFSIZE=256
CONFIG_USART6_BAUD=115200
CONFIG_USART6_BITS=8
CONFIG_USART6_PARITY=0
CONFIG_USART6_2STOP=0
Virtual COM Port
----------------
Yet another option is to use UART2 and the USB virtual COM port. This
option may be more convenient for long term development, but is painful
to use during board bring-up.
Solder Bridges. This configuration requires:
- SB62 and SB63 Open: PA2 and PA3 on STM32 MCU are disconnected to D1
and D0 (pin 7 and pin 8) on Arduino connector CN9 and ST Morpho
connector CN10.
- SB13 and SB14 Closed: PA2 and PA3 on STM32F103C8T6 (ST-LINK MCU) are
connected to PA3 and PA2 on STM32 MCU to have USART communication
between them. Thus SB61, SB62 and SB63 should be OFF.
Configuring USART2 is the same as given above.
Question: What BAUD should be configure to interface with the Virtual
COM port? 115200 8N1?
Default
-------
As shipped, SB62 and SB63 are open and SB13 and SB14 closed, so the
virtual COM port is enabled.
Configurations
==============
nsh:
---------
Configures the NuttShell (nsh) located at apps/examples/nsh for the
Nucleo-F410RB board. The Configuration enables the serial interfaces
on UART2. Support for builtin applications is enabled, but in the base
configuration no builtin applications are selected (see NOTES below).
NOTES:
1. This configuration uses the mconf-based configuration tool. To
change this configuration using that tool, you should:
a. Build and install the kconfig-mconf tool. See nuttx/README.txt
see additional README.txt files in the NuttX tools repository.
b. Execute 'make menuconfig' in nuttx/ in order to start the
reconfiguration process.
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
@@ -1,196 +0,0 @@
README
======
The Olimex STM32-E407 configuration is based on the configuration
olimex-stm32-h407 and stm32f4discovery.
Configurations
==============
Instantiating Configurations
----------------------------
Each Olimex-STM32-E407 configuration is maintained in a sub-directory and
can be selected as follow:
tools/configure.sh [OPTIONS] olimex-stm32-e407:<subdir>
Typical options include -l for a Linux host platform or -c for Cygwin
host platform. See 'tools/configure.sh -h' for other options. And
<subdir> is one of the sub-directories listed below.
Compile Firmware
----------------
Once you've set the proper configuration, you just need to execute the next
command:
make
If everything goes find, it should return the next two files:
nuttx.hex
nuttx.bin
You can return more kinds of files by setting on menuconfig.
Flashing the Board
-----------------
You can flash this board in different ways, but the easiest way is using
ARM-USB-TINY-H JTAG flasher device.
Connect this device to the JTAG connector and type the next command:
openocd -f interface/ftdi/olimex-arm-usb-tiny-h.cfg -f target/stm32f4x.cfg -c init -c "reset halt" -c "flash write_image erase nuttx.bin 0x08000000"
Configuration Directories
-------------------------
nsh:
---
Configures the NuttShell (nsh) located at apps/examples/nsh. This
configuration enables a console on UART2. Support for
builtin applications is enabled, but in the base configuration no
builtin applications are selected.
usbnsh:
------
Configures the NuttShell (nsh) located at apps/examples/nsh. This
configuration enables a console on USB_OTG1. Support for
builtin applications is enabled, but in the base configuration no
builtin applications are selected.
netnsh:
------
Configures the NuttShell (nsh) located at examples/nsh. This
configuration is focused on network testing.
bmp180:
------
This is a configuration example for the BMP180 barometer sensor. This
sensor works with I2C, you need to do the next connections:
BMP180 VIN -> Board 3.3V
BMP180 GND -> Board GND
BMP180 SCL -> Board PB6 (Arduino header D1)
BMP180 SDA -> Board PB7 (Arduino header D0)
This example is configured to work with the USBNSH instead of UART NSH, so
the console will be shown over the USB_OTG1 connector.
On the console, type "ls /dev " and if the registration process goes fine,
you should see a device called "press0". Now execute the app
BMP180 to see the ambient pressure value.
dac:
---
This is a configuration example to use the DAC1 of the board. The DAC1
is attached to the PA4 pin (Arduino header D10).
This example is configured to work with the USBNSH instead of UART NSH, so
the console will be shown over the USB_OTG1 connector.
On the console, type "ls /dev " and if the registration process goes fine,
you should see a device called "dac0". Now execute the app
dac put a value at the output.
ina219:
------
This is a configuration example for the INA219 DC current sensor. This
sensor works with I2C, you need to do the next connections:
INA219 VIN -> Board 3.3V
INA219 GND -> Board GND
INA219 SCL -> Board PB6 (Arduino header D1)
INA219 SDA -> Board PB7 (Arduino header D0)
This example is configured to work with the USBNSH instead of UART NSH, so
the console will be shown over the USB_OTG1 connector.
On the console, type "ls /dev " and if the registration process goes fine,
you should see a device called "ina219". Now execute the app
ina219 to see the ambient pressure value.
timer:
-----
This configuration set the proper configuration to use the timer1 of the
board. This example is configured to work with the USBNSH instead of
UART NSH, so the console will be shown over the USB_OTG1 connector.
On the console, type "ls /dev " and if the registration process goes fine,
you should see a device called "timer1".
mrf24j40-mac:
------------
This configuration set the proper configuration to set the 802.15.4
communication layer with the MRF24J40 radio. This radio works with
SPI, you need to do the next connections:
MRF24J40 VCC -> Board 3.3V
MRF24J40 GND -> Board GND
MRF24J40 SCLK -> Board PA5 (Arduino header D13)
MRF24J40 MISO -> Board PA6 (Arduino header D12)
MRF24J40 MOSI -> Board PB5 (Arduino header D11)
MRF24J40 CS -> Board PA4 (Arduino header D10)
MRF24J40 INT -> Board PG12 (Arduino header D8)
This example is configured to work with the USBNSH instead of UART NSH,
so the console will be shown over the USB_OTG1 connector.
Once you're on the console, you need to check if the initialization
process was fine. To do so, you need to type "ls /dev" and you should
see a device call "ieee0". At this point we need to set-up the network,
follow the next steps:
This is an example of how to configure a coordinator:
i8sak /dev/ieee0 startpan cd:ab
i8sak set chan 11
i8sak set saddr 42:01
i8sak acceptassoc
This is an example of how to configure the endpoint:
i8sak /dev/ieee0
i8sak set chan 11
i8sak set panid cd:ab
i8sak set saddr 42:02
i8sak set ep_saddr 42:01
i8sak assoc
mrf24j40-6lowpan:
----------------
This configuration set the proper configuration to use 6lowpan protocol with the MRF24J40
radio. This radio works with SPI, you need to do the next connections:
MRF24J40 VCC -> Board 3.3V
MRF24J40 GND -> Board GND
MRF24J40 SCLK -> Board PA5 (Arduino header D13)
MRF24J40 MISO -> Board PA6 (Arduino header D12)
MRF24J40 MOSI -> Board PB5 (Arduino header D11)
MRF24J40 CS -> Board PA4 (Arduino header D10)
MRF24J40 INT -> Board PG12 (Arduino header D8)
This example is configured to work with the USBNSH instead of UART NSH, so
the console will be shown over the USB_OTG1 connector.
Once you're on the console, you need to check if the initialization process
was fine. To do so, you need to type "ls /dev" and you should see a device
call "ieee0". At this point we need to set-up the network, follow the next steps:
This is an example of how to configure a coordinator:
i8sak wpan0 startpan cd:ab
i8sak set chan 11
i8sak set saddr 42:01
i8sak acceptassoc
When the association was complete, you need to bring-up the network:
ifup wpan0
This is an example of how to configure the endpoint:
i8sak wpan0
i8sak set chan 11
i8sak set panid cd:ab
i8sak set saddr 42:02
i8sak set ep_saddr 42:01
i8sak assoc
When the association was complete, you need to bring-up the network:
ifup wpan0
If you execute the command "ifconfig", you will be able to see the info of the WPAN0 interface
and see the assigned IP. This interface can be use with an UDP or TCP server/client application.
File diff suppressed because it is too large Load Diff
-80
View File
@@ -1,80 +0,0 @@
OMNIBUSF4 Target Support README
===============================
"OmnibusF4" is not a product name per se, but rather a design spec
that many product vendors within the drone flight management unit
(FMU) community adhere to. The spec defines the major components, and
how those components are wired into the STM32F405RGT6 microcontroller.
Airbot is one such vendor, and they publish a schematic here:
http://bit.ly/obf4pro
Other software that supports the OmnibusF4 family include Betaflight,
iNAV, and many others. PX4 recently added support as well. No code
from any of those sources is included in this port.
Since OmnibusF4 is a drone FMU, most of its IO is already allocated to
FMU-specific tasks. As such, we don't need to make the board support
package as flexible as, say, an STM32F4 Discovery board.
The following are some of the committed IO pins. Most of the pins not
mentioned here are inaccessible, the details vary by board vendor:
io peripheral signal notes
==================================
XIN 8MHz crystal oscillator
PB0 TIM3 CH3 S1_OUT motor 1 PWM output
PB1 TIM3 CH4 S2_OUT motor 2 PWM output
PA3 TIM2 CH4 S3_OUT motor 3 PWM output
PA2 TIM2 CH3 S4_OUT motor 4 PWM output
PA1 TIM2 CH2 S5_OUT motor 5 PWM output
PA8 TIM1 CH4 S6_OUT motor 6 PWM output
PA4 SPI1 SPI1_NSS mpu6000
PA5 SPI1 SPI1_SCL
PA6 SPI1 SPI1_MISO
PA7 SPI1 SPI1_MOSI
PC4 GPIO GYRO_INT mpu6000 EXTI
PB10 UART3/I2C UART3_TX ttl UART tx or i2c_scl (used as console)
PB11 UART3/I2C UART3_RX ttl UART rx or i2c_sda (used as console)
PB9 RC_CH2 (rx pwm input)
PB8 RC_CH1 (rx pwm input)
PC9 RC_CH6 (rx pwm input)
PC8 RC_CH5 (rx pwm input)
PC7 RC_CH4 or USART6_RX (ttl)
PC6 RC_CH3 or USART6_TX (ttl)
PB7 GPIO SD_DET SD card detection pin (low when card inserted)
PB5 GPIO STAT LED output (active low)
PB4 GPIO BUZZER buzzer output (active low)
PD2 GPIO LED_STRIP one-wire interface for LED strips
PC12 SPI3 SPI3_MOSI bmp280 barometer (if populated) and/or max7456 OSD
PC11 SPI3 SPI3_MISO
PC10 SPI3 SPI3_SCL
PA15 GPIO SPI3_NSS OSD NSS
PB3 GPIO BARO_CS bmp280 NSS (if populated)
PA12 OTG USB_DP
PA11 OTG USB_DN
PA10 UART1 USART1_RX SBUS_IN (through inverter) or PPM
PA9 UART1 USART1_TX
PB15 SPI2 SPI2_MOSI sd/mmc card interface
PB14 SPI2 SPI2_MISO
PB13 SPI2 SPI2_SCLK
PB12 SPI2 SPI2_NSS
Build Instructions
==================
The boards/arm/stm32/omnibusf4/nsh/defconfig file creates a basic setup, and
includes drivers for all supported onboard chips. The console and
command prompt are sent to USART3.
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
@@ -1,105 +0,0 @@
README.txt
==========
STM32F429I-DISCO LTDC Framebuffer demo example
Configure and build
-------------------
cd tools
./configure -a <appdir> stm32f429i-disco/fb
cd ..
make
Framebuffer calculation
----------------------
Use the helper script boards/stm32f429i-disco/tools/fbcalc.sh for calculating
the heap2 and framebuffer memory region. The script assumes that all overlay
buffers (LTDC and DMA2D) located in heap2 memory region starting at address
0xD0000000. When changing the display size (when using a custom display), DMA2D
overlay size or the pixel format you have to recalculate the heap2 settings.
In this configuration all overlays (LTDC and DMA2D) positioned at the end of
heap2.
LTDC hardware acceleration
--------------------------
The LTDC driver provides two 2 LTDC overlays and supports the following hardware
acceleration and features:
Configured at build time
- background color
- default color (outside visible screen)
Configurable by nuttx framebuffer interface
- cmap support (color table is shared by both LTDC overlays and DMA2D when
enabled)
Configurable via the nuttx framebuffer interface (for each layer separately)
- chromakey
- transparency (const alpha and pixel alpha)
- blank
- color (if DMA2D is enabled and cmap is disabled)
- blit (if DMA2D is enabled)
- blend (if DMA2D is enabled and cmap is disabled)
LTDC overlays are similar to a non-destructive overlay. Both LTDC overlays will
be permanently blended in the order (background -> overlay 0 -> overlay 1) and
converted to a resulting video signal by the LTDC controller. That means each
operation with a LTDC overlay (Overlay 0 and Overlay 1) via nuttx framebuffer
interface will be visible immediately.
Think about continuous blending between both overlays.
DMA2D hardware acceleration
---------------------------
The DMA2D driver implements the following hardware acceleration:
Configurable via the nuttx framebuffer interface
- cmap support (color table is shared by all DMA2D overlays and LTDC overlays)
Configurable via the nuttx framebuffer interface (for each layer separately)
- color (fill memory region with a specific ARGB8888 color immediately), if
cmap is disabled
- blit (copy memory region to another memory region with pixel format
conversion if necessary)
- blend (blend two memory regions and copy the result to a third memory region
with pixel format conversion if necessary), if cmap is disabled
Blit and blend operation using a fixes memory size defined by the background
layer. DMA2D controller doesn't support scaling.
DMA2D overlays are similar to destructive overlays. They are invisible. They can
be used for image preprocessing. The memory region affected by the operations
(color, blit, blend) can be addressed by the area control command before. The
configured overlay transparency of DMA2D overlays will be used for subsequently
blend operation and is valid for the whole overlay.
Configuration
------------
This configuration provides 2 LTDC (visible overlays) and 2 DMA2D overlays with
pixel format RGB565 and a resolution of 240x320.
Loading
-------
st-flash write nuttx.bin 0x8000000
Executing
---------
The ltdc is initialized during boot up. Interaction with NSH is via the serial
console at 115200 8N1 baud. From the nsh comandline execute the fb example:
nsh> fb
The test will put a pattern of concentric squares in the framebuffer and
terminate.
You can also test overlay hardware acceleration functionality by executing the
following command (shows a commandline help):
nsh> fboverlay
File diff suppressed because it is too large Load Diff
@@ -1,75 +0,0 @@
Nucleo-WL55JC README
====================
This README file discusses the port of NuttX to the STMicro Nucleo-WL55JC
board. That board features the STM32WL55JCI7 MCU with 256KiB of FLASH and
64KiB of SRAM. This is dual CPU (not core) chip. There is integrated LORA
hardware on board which is only available via CPU0.
Contents
========
- Status
- LEDs
- Buttons
- Serial Console
- Configurations
- Flashing
Status
======
2022.06.07: Board boots and nsh works without problems. Both arduino and
virtual com port UARTs work.
LEDs
====
There are user controlled 3 LEDs. Blue (PB15), Green(PB9) and Red(PB11).
To turn on the LED, GPIO has to be driven to HIGH state.
Green and Red LEDs are used by the system at boot to show system state.
Once system is booted these LEDs are for user to control. When
CONFIG_ARCH_LEDS is set, Blue LED is reserved by OS for reporting system
status. When CONFIG_ARCH_LEDS is not set, OS state won't be reported on
any of the LEDs and all 3 LEDs are available for user right from the start.
Buttons
=======
There are 3 buttons that are available for the user to program, and one
reset button.
Serial Console
==============
There are 2 serial ports - USART1 and LPUART1.
USART1 is connected to arduino D0/D1 pin and LPUART is connected to
stlink that provides virtual serial port.
NSH is configured to use LPUART and virtual serial port. After flashing
you can open /dev/ttyACM0 (may change depending on your system) and nsh
prompt will be waiting for you there. Serial device does not disappear
when flashing and resetting board - it can be left opened and flashing
will work without problems.
Configuration
=============
Configuration sub-directories
-----------------------------
nsh:
Configures the NuttShell (nsh) located at examples/nsh. NSH is will
work on virtual serial port over usb.
Flashing
========
Easiest way to flash nucleo is to use openocd tool. Openocd supports
stlink v3 which is on the board. It's as easy as running:
openocd -f interface/stlink.cfg -f target/stm32wlx.cfg \
-c "program nuttx.bin exit 0x08000000"