1.. _stm32l475ve_pandora_board: 2 3Alientek STM32L475 Pandora 4########################## 5 6Overview 7******** 8 9The STM32L475 Pandora board features an ARM Cortex-M4 based STM32L475VE MCU 10with a wide range of connectivity support and configurations. Here are 11some highlights of the STM32L475 Pandora board: 12 13 14- STM32L475Vx microcontroller featuring 1 Mbyte of Flash memory, 128 Kbytes of RAM in LQFP100 package 15- On-board ST-LINK/V2-1 supporting USB re-enumeration capability 16- Three different interfaces supported on USB: 17 18 - Virtual com port 19 - Mass storage 20 - Debug port 21 22- Pushbutton (reset) 23- Four directions Joystick with selection 24- USB OTG FS with micro-AB connector 25- SAI Audio DAC, Stereo with output jack 26- Digital microphone, accelerometer, magnetometer and gyroscope MEMS 27- 128-Mbit Quad-SPI Flash memory 28- MCU current ammeter with 4 ranges and auto-calibration 29- Connector for external board or RF-EEPROM 30- Four power supply options: 31 - ST-LINK/V2-1 32 - USB FS connector 33 - External 5 V 34 - CR2032 battery (not provided) 35 36.. image:: img/pandora_stm32l475.jpg 37 :align: center 38 :alt: STM32L475 Pandora 39 40More information about the board can be found at the `STM32L475 Pandora website`_. 41 42Hardware 43******** 44 45The STM32L475VE SoC provides the following hardware features: 46 47- Ultra-low-power with FlexPowerControl (down to 130 nA Standby mode and 100 uA/MHz run mode) 48- Core: ARM |reg| 32-bit Cortex |reg|-M4 CPU with FPU, frequency up to 80 MHz, 100DMIPS/1.25DMIPS/MHz (Dhrystone 2.1) 49- Clock Sources: 50 - 4 to 48 MHz crystal oscillator 51 - 32 kHz crystal oscillator for RTC (LSE) 52 - Internal 16 MHz factory-trimmed RC ( |plusminus| 1%) 53 - Internal low-power 32 kHz RC ( |plusminus| 5%) 54 - Internal multispeed 100 kHz to 48 MHz oscillator, auto-trimmed by 55 LSE (better than |plusminus| 0.25 % accuracy) 56 - 3 PLLs for system clock, USB, audio, ADC 57- RTC with HW calendar, alarms and calibration 58- 16x timers: 59 - 2x 16-bit advanced motor-control 60 - 2x 32-bit and 7x 16-bit general purpose 61 - 2x 16-bit basic 62 - 2x low-power 16-bit timers (available in Stop mode) 63 - 2x watchdogs 64 - SysTick timer 65- Up to 82 fast I/Os, most 5 V-tolerant, up to 14 I/Os with independent supply down to 1.08 V 66- Memories 67 - Up to 1 MB Flash, 2 banks read-while-write, proprietary code readout protection 68 - Up to 128 KB of SRAM including 32 KB with hardware parity check 69 - External memory interface for static memories supporting SRAM, PSRAM, NOR and NAND memories 70 - Quad SPI memory interface 71- 4x digital filters for sigma delta modulator 72- Rich analog peripherals (independent supply) 73 - 3x 12-bit ADC 5 MSPS, up to 16-bit with hardware oversampling, 200 uA/MSPS 74 - 2x 12-bit DAC, low-power sample and hold 75 - 2x operational amplifiers with built-in PGA 76 - 2x ultra-low-power comparators 77- 18x communication interfaces 78 - USB OTG 2.0 full-speed, LPM and BCD 79 - 2x SAIs (serial audio interface) 80 - 3x I2C FM+(1 Mbit/s), SMBus/PMBus 81 - 6x USARTs (ISO 7816, LIN, IrDA, modem) 82 - 3x SPIs (4x SPIs with the Quad SPI) 83 - CAN (2.0B Active) and SDMMC interface 84 - SWPMI single wire protocol master I/F 85- 14-channel DMA controller 86- True random number generator 87- CRC calculation unit, 96-bit unique ID 88- Development support: serial wire debug (SWD), JTAG, Embedded Trace Macrocell |trade| 89 90 91Supported Features 92================== 93 94The Zephyr stm32l475ve_pandora board configuration supports the following hardware features: 95 96+-----------+------------+----------------------------------------------+ 97| Interface | Controller | Driver/Component | 98+===========+============+==============================================+ 99| NVIC | on-chip | nested vector interrupt controller | 100+-----------+------------+----------------------------------------------+ 101| UART | on-chip | serial port-polling; | 102| | | serial port-interrupt | 103+-----------+------------+----------------------------------------------+ 104| PINMUX | on-chip | pinmux | 105+-----------+------------+----------------------------------------------+ 106| GPIO | on-chip | gpio | 107+-----------+------------+----------------------------------------------+ 108| I2C | on-chip | I2C-AHT10(Temperature and humidity sensor) | 109| | | I2C-ICM2068(light environment sensor) | 110+-----------+------------+----------------------------------------------+ 111| I2S | on-chip | I2S-ES8388(Audio Decoder) | 112+-----------+------------+----------------------------------------------+ 113| USB | on-chip | I2S-OTG | 114+-----------+------------+----------------------------------------------+ 115| SDIO | on-chip | SDIO-AP6181(WIFI) | 116+-----------+------------+----------------------------------------------+ 117| SPI | on-chip | LCD-TFT | 118+-----------+------------+----------------------------------------------+ 119| QSPI NOR | on-chip | flash | 120+-----------+------------+----------------------------------------------+ 121| IR-RX/TX | on-board | Infrared Receiver(38Khz)/Transmitter | 122+-----------+------------+----------------------------------------------+ 123| STLINK-V2 | on-board | STLINK-V2 Debugger | 124+-----------+------------+----------------------------------------------+ 125 126Other hardware features are not yet supported on this Zephyr port. 127 128The default configuration can be found in the defconfig file: 129 130 ``boards/arm/pandora_stm32l475/pandora_stm32l475_defconfig`` 131 132 133Connections and IOs 134=================== 135 136STM32L475 Pandora Board has 8 GPIO controllers. These controllers are responsible for pin muxing, 137input/output, pull-up, etc. 138 139For mode details please refer to `STM32L475 Pandora board User Manual`_. 140 141Default Zephyr Peripheral Mapping: 142---------------------------------- 143 144- UART_1_TX : PA9 145- UART_1_RX : PA10 146- LED_R : PE7 147- LED_G : PE8 148- LED_B : PE9 149 150System Clock 151------------ 152 153STM32L475 Pandora System Clock could be driven by an internal or external oscillator, 154as well as the main PLL clock. By default the System clock is driven by the PLL clock at 80MHz, 155driven by 16MHz high speed internal oscillator. 156 157Serial Port 158----------- 159 160STM32L475 Pandora board has 6 U(S)ARTs. The Zephyr console output is assigned to UART2. 161Default settings are 115200 8N1. 162 163 164Programming and Debugging 165************************* 166 167Flashing 168======== 169 170STM32L475 Pandora board includes an ST-LINK/V2-1 embedded debug tool interface. 171This interface is supported by the openocd version included in Zephyr SDK. 172 173Flashing an application to STM32L475 Pandora 174-------------------------------------------- 175 176Connect the STM32L475 Pandora to your host computer using the USB 177port, then run a serial host program to connect with your Discovery 178board. For example: 179 180.. code-block:: console 181 182 $ minicom -D /dev/ttyACM0 183 184Then, build and flash in the usual way. Here is an example for the 185:ref:`hello_world` application. 186 187.. zephyr-app-commands:: 188 :zephyr-app: samples/hello_world 189 :board: stm32l475ve_pandora 190 :goals: build flash 191 192You should see the following message on the console: 193 194.. code-block:: console 195 196 Hello World! arm 197 198Debugging 199========= 200 201You can debug an application in the usual way. Here is an example for the 202:ref:`hello_world` application. 203 204.. zephyr-app-commands:: 205 :zephyr-app: samples/hello_world 206 :board: stm32l475ve_pandora 207 :maybe-skip-config: 208 :goals: debug 209 210.. _STM32L475 Pandora website: 211 http://www.openedv.com/docs/boards/iot/zdyz_panduola.html 212 213.. _STM32L475 Pandora board User Manual: 214 http://www.openedv.com/thread-284556-1-1.html 215