Quick Start Guide

Introduction

The STM32 family of 32-bit microcontrollers based on the Arm Cortex®-M processor is designed to offer new degrees of freedom to MCU users. It offers products combining very high performance, real-time capabilities, digital signal processing, low-power / low-voltage operation, and connectivity, while maintaining full integration and ease of development.

Many Boards are supported out-of-the-box with the middleware GOAL.

Requirements

For evaluation of the software following items are required:

  • a NUCLEO board

  • optional an adapter board with an Ethernet Switch

  • PC with Linux, Windows or MacOS

  • Micro USB cable

  • Ethernet cable

Software delivery

Extracting

The software comes in different versions, e.g. “0210_119_PROFINET_2.23.0_STM32_CUBE.zip”. The delivery also contains a fully functional project generator, to build projects on your own.

Please keep the path length as short as possible and extract the GOAL delivery in for e.g. a root directory to ensure proper project functionality. This is important as some windows versions have a restriction regarding path sizes.

Generate projects with GOAL

This step is optional as several pre-built example projects are provided within the delivery. This might be interesting, if you want to create your own projects.

To generate a project:

  1. Choose an approriate project at commandline

    user: ~ cd GOAL/projects/goal_ecat/01_simple_ioo/gcc
  2. Invoke project generator and choose appropriate IDE and template

    user: ~/GOAL/projects/goal_ecat/01_simple_io/gcc make gen_project No platform selected, choose a platform - OR - press <CTRL+c> and set the PLATFORM environment variable. Choose template: [ 1] stm32_cube_h723_eth_2port_lan9354 (gcc,gdb,ocd) ... python3 /home/user/GOAL/projects/goal_ecat/01_simple_io/gcc/../../../../../tools/make/gen_project/gen_project.py gen_project ----------- Project: goal_ecat__01_simple_io__stm32_cube_h723_eth_2port_lan9354 Templates: tools/make/gen_project/templates/stmcubeide/port/stmcubeide_stm32generic_h723_nucleo_eth_ lan9354 Output dir: /home/user/GOAL/projects/goal_ecat/01_simple_io/gcc/../stmcubeide/port/stm32_cube_h723_eth_2port_lan9354

The created project can now be imported.

Import Projects into STM32CubeIDE

Several pre-built GOAL example projects for STM32CubeIDE are provided with this delivery, these are located at projects/<protocol>/<application>/stmcubeide/port/<platform>/.project.

Importing the Projects is described here: GOAL Project Generator | STM32CubeIDE.

Platforms

Following table shows the various project types that are part of the software package.

project suffix

target board

remarks

project suffix

target board

remarks

stm32_cube_f429_eth_2port

NUCLEO-F429ZI with switch adapter board

 

stm32_cube_f429_eth_standalone_rtos

NUCLEO-F429ZI board with EEPROM board X-NUCLEO-EEPRMA2

FreeRTOS version

Because of limited resources on the NUCLEO-F429ZI board with this configuration only small examples are provided. Examples with communication stacks (PROFINET, EtherNet/IP, EtherCAT) require more RAM in combination with FreeRTOS.

stm32_cube_f429_eth_standalone

NUCLEO-F429ZI board with EEPROM board X-NUCLEO-EEPRMA2

 

stm32_cube_h723_eth_2port

NUCLEO-H723ZG with switch adapter board

 

stm32_cube_h723_eth_2port_rtos

NUCLEO-H723ZG with switch adapter board

FreeRTOS version

stm32_cube_h723_eth_standalone_rtos

NUCLEO-H723ZG with EEPROM board X-NUCLEO-EEPRMA2

FreeRTOS version

stm32_cube_h723_eth_standalone

NUCLEO-H723ZG with EEPROM board X-NUCLEO-EEPRMA2

 

stm32_cube_h743_eth_2port

NUCLEO-H743ZI/NUCLEO-H753ZI with switch adapter board

 

stm32_cube_h743_eth_2port_rtos

NUCLEO-H743ZI/NUCLEO-H753ZI with switch adapter board

FreeRTOS version

stm32_cube_h743_eth_standalone_rtos

NUCLEO-H743ZI/NUCLEO-H753ZI with EEPROM board X-NUCLEO-EEPRMA2

FreeRTOS version

The EEPROM board is optional, the software can also use the internal secondary flash bank for storage of parameters. However, this is only allowed to be used for evaluation. Productive code needs to have an extern EEPROM for storage of parameters.

stm32_cube_h743_eth_standalone

NUCLEO-H743ZI/NUCLEO-H753ZI with EEPROM board X-NUCLEO-EEPRMA2

The EEPROM board is optional, the software can also use the internal secondary flash bank for storage of parameters. However, this is only allowed to be used for evaluation. Productive code needs to have an extern EEPROM for storage of parameters.

Evaluation

Evaluation on NUCLEO boards

Depending on the Nucleo board an external EEPROM board is required for proper operation. The following NUCLEO boards require this extension:

Development board

Required

Development board

Required

NUCLEO-H753ZI

-

NUCLEO-H743ZI

-

NUCLEO-H723ZG

X-NUCLEO-EEPRMA2

NUCELO-F429ZI

X-NUCLEO-EEPRMA2

The extension board X-NUCLEO-EEPRMA2 (https://www.st.com/en/evaluation-tools/x-nucleo-eeprma2.html ) is an extension board for the Nucleo boards Arduino header containing some I2C and SPI eeproms. In order to be abple for the software to write to the EEPROM, the jumper J11 needs to be set to Wpn pin to VCC.

Evaluation with Switch controller

Using an external switch requires a modified custom hardware from port. There a preconfigured switch (KSZ8863) is available. The management of the switch is done through SPI channel 4. Data is transferred using RMII between STM32 and the switch.

The hardware connections between STM32 and peripherals are listed here:

  • I2C EEPROM

    • I2C data interface

      • I2C channel 2

        • SCL: PF1

        • SDA: PF0

  • Switch KSZ8863

    • SPI management interface

      • SPI channel 4

        • MISO: PE5

        • MOSI: PE6

        • SCLK: PE2

        • NSS: PE4

      • RST: PC0

      • ITR: -

    • DATA interface RMII

      • TXD0: PG13

      • TXD1: PG12

      • TX_EN: PG11

      • RXD0: PC4

      • RXD1: PC5

      • CRS_DV: PA7

      • RMII_CLOCK: PA1

      • MDC: -

      • MDIO: -

Evaluation with EtherCAT

Using EtherCAT requires a modified custom hardware from port. There, the possibility to connect a modified LAN9253 EtherCAT controller is provided. The access to the ESC done through SPI channel 3.

It is possible to use a stand alone NUCLEO board for evaluation of EtherCAT. Then the EtherCAT stamp needs to be connected by hand to the NUCLEO board according to the connection requirements listed below.

  • LAN9253 EtherCAT controller:

    • SPI channel 3

      • MISO: PC11

      • MOSI: PB2

      • SCLK: PC110

      • NSS: PA4

    • RST: PG1

    • INT: PC6

    • SYNC0: PB8

    • SYNC1: PB9

Customer Hardware porting

Based on the example projects and the provided CubeMX configuration files (ioc) the software can easily be adapted to any custom hardware.

Evaluation of examples

Please check the following chapter on how to test a PROFINET application with ports Industrial Communication Explorer: Quick Start Guide for GOAL on Raspberry Pi | Profinet Binary .