STM32F429 (GOAL)

Changelog

Version

Changes

 

1.0

 

 

Initial release

Introduction

This document describes integration delivered example projects for SoM using the STM32F4xx target with development environment STM32 Cube IDE.

Preparations

Hardware Requirements

Make sure following settings are set:

J13: Connect “VCC33_Sockel” with “VCC33_RJ45”

J8: Connect “CS” with “PB2”

J7: Connect “RST” with “PD7”

All DIP-Switches to OFF

STM32F429I-Nucleo board

Make sure following settings are set:

JP6: Remove this Jumper on the front side of the board

Due to a double assignment of pins the simultaneous use of SPI and Ethernet is not possible with STM32 Nucleo-144. The JP6 jumper activates Ethernet.

Target System

Connect both boards (see Figure 3 Target system). Voltage supply is done through the shown USB connector (USB Pwr) on the development board, which also supports flashing and debugging of the CPU.

Software Requirements

Development environment “STM32F4”

The development of software for the AC requires an installation of the STM32 Cube IDE. Version 1.0 was used. The toolchain can be obtained here:

https://www.st.com/en/development-tools/stm32cubeide.html

Delivery

The delivery consists of 2 files:

File

Content

“2015013_20190611_2_20_0_port_STM32F429_Nucleo144_CCM_ci125.zip"

GOAL Library and Headers

“iCommExplorer-win32.win32.x86_64_ci117-v1.3.1.zip"

Industrial Communication Explorer

Management Tool

To use the PROFINET master functionality, WinPCap[1] needs to be installed.

Please unpack the delivery "iCommExplorer-*-win32.win32.x86_64.zip" to a local folder. The resulting folder contains the executable, which can be started.

Prepare GOAL and project

Unpack the goal headers and library (2015013*.zip) to a local folder. This folder contains the goal library and the associated headers for synergy required to build an application for the SoM. Beside that example projects for e2studio are contained.

Import project

 

Use the import dialog of STM Cube IDE to import the project located in the unpacked project delivery into the IDE. Chose "Existing projects into workspace" when prompted for import type.

Select the root directory of the unpacked delivery project for import and “Finish” import (see Figure 5 Import project dialog). There are several types of projects, which can be imported all or selectively.

After importing the projects can be built. Use the project context menu, menu item “Build Project” to do so. As a result, a binary should be generated and the “Console” log should show the following text:

Finished building target: 2015013_irj45__ac__01_pnio_io_mirror__stm32f429_nucleo.elf  arm-none-eabi-size   2015013_irj45__ac__01_pnio_io_mirror__stm32f429_nucleo.elf arm-none-eabi-objdump -h -S  2015013_irj45__ac__01_pnio_io_mirror__stm32f429_nucleo.elf  > "2015013_irj45__ac__01_pnio_io_mirror__stm32f429_nucleo.list" arm-none-eabi-objcopy  -O binary  2015013_irj45__ac__01_pnio_io_mirror__stm32f429_nucleo.elf  "2015013_irj45__ac__01_pnio_io_mirror__stm32f429_nucleo.bin"    text    data          bss          dec          hex      filename  190440     888      136000      327328        4fea0 2015013_irj45__ac__01_pnio_io_mirror__stm32f429_nucleo.elf Finished building: default.size.stdout Finished building: 2015013_irj45__ac__01_pnio_io_mirror__stm32f429_nucleo.bin Finished building: 2015013_irj45__ac__01_pnio_io_mirror__stm32f429_nucleo.list 13:00:37 Build Finished. 0 errors, 358 warnings. (took 16s.925ms)

 

If so, compilation was successful. The resulting binary now can be started:

Debug configuration must be edited regarding debug probe for proper function.

Please configure the debug probe as shown below to ST-LINK (OpenOCD). When prompted allow firewall exception to be configured.

After initiating the debug session, the “Debug perspective” will be shown, where the application can be started by “Resuming” execution. 

If the communication module was previously started up using another application, a manual reboot will be required of the module (reset button on the Arduino shield).

Industrial Communication Explorer

The Industrial Communication Explorer allows development related configuration and management of the application. This management is based on a UDP broadcast communication. Thus, it works independently from IP settings of the management PC and SoM.

This tool is organized in panels. The “Network Navigator” shows a list of available networks. The panel “Messages” shows information regarding actions. The panel “Outline” shows additional information depending on the selected function panel.

Following function panels are available:

Panel

Function

EtherCAT Master

Provides simple EtherCAT master functionality.

EtherNet/IP Master

Provides simple EtherNet/IP master functionality

Exception Log

Shows error messages, which are saved in the non volatile storage of the communication controller.

Device Log

Shows log messages of the running application from both communication controller (CC) and application controller (AC).

Network state

Shows link state of the available network interfaces of the SoM.

PNIO Master

Provides simple PNIO master functionality.

ConfigManager

Provides access to the config manager variables of the SoM.

Firmware Update

Allows update of the firmware of the SoM.

Device Detection

At first a communication needs to be established with the SoM. Thus, connect the SoM to the network. Between the management PC and the SoM a network connection must be possible.

To communicate with the SoM, at first open the “Networks” list in the “Network Navigator”. Choose the network interface where the SoM is reachable. Then select the “Scan Network” button in the toolbar.

The following dialog appears and 1 found device will be reported:

As a result, a new SoM will be shown in the „Network Navigator“ within the scanned network.

Please select the newly found SoM for further steps.

Logging

With the selected SoM and within the “Device Log” function panel, it is now possible to read the logging buffer using “Start reading log”. For the demo application, it shows both the log messages from the communication controller (SoM) and the application controller (Raspberry Pi). Those can be distinguished by the “Source” column, which either shows “CC” ore “AC”. A successful started application reports a successful initialization of PROFINET:

[I| goal_miMctcLoop:499] running appl_setup [I| goal_pnioNewAc:369] PROFINET Application Core successfully started [I| appl_setup:226] Initializing device structure [I| appl_setup:275] PROFINET ready [I| appl_setup:281] Configuring DD [I| appl_setup:309] DD ready

To stop logging push the button again.

Config Manager / IP Configuration

The function panel “ConfigManager” provides access to the config manager variables of the SoM (volatile and nonvolatile stored configuration variables).

To read a list of all variables, select the “Read configuration” button in the toolbar.

As a result, all variables with value are shown.

To communicate with the SoM, the IP address of it must be within the same IP network as the IP address of the Management PC IP address. Thus, choose a valid IP address and configure the SoM accordingly.

To configure an IP address, navigate to the variables of the “Module” GOAL_ID_NET. Make sure, that the variable DHCP_ENABLED is set to 0x00, as this option is prioritized. Now it is possible to configure IP, NETMASK and GW. Modify required values. Set the variable “VALID” to 0x01.

The Management Tool will show locally modified variables with a yellow highlight.

Those locally modified variables are downloaded to the SoM using the “Write configuration” button in the toolbar. When prompted if changed values shall be written, answer “Yes”. Afterwards the locally modified values are transferred to the SoM, where there are only modified in RAM. To make changes permanently, answer the following prompt with “Yes”. Modified IP settings are applicated after restart of the system (power cycle the STM32F4xx/SoM).

Examples

01_pnio_simple_io

Please start the example “01_pnio_simple_io” according to the previous description.

To establish a PROFINET communication, at first the SoM must be selected in the “Network Navigator”. Then select the PNIO Master function panel. At first use “Scan device” to detect the PROFINET device.

Use the “Wink” command to identify the connected SoM, which will be shown with a flashing “LED1” on the Arduino shield.

To establish a cyclic PROFINET communication use the I/O panel of the PNIO Master. 

Please start the example “01_pnio_simple_io” according to the previous descriptions.

To establish a PROFINET communication, at first the SoM must be selected in the “Network Navigator”. Then select the function panel PNIO Master. At first use “Scan device” to detect the PROFINET device.

Use the “Wink” command to identify the connected SoM, which will be shown with a flashing “LED1” on the Arduino shield.

To establish a cyclic PROFINET communication use the I/O panel of the PNIO Master.

To continue, load the GSDML file provided with the distribution, located in “goal\appl\2015013_irj45\ac\gsdml\".

In the selector “Device Access Point” select “2-port Device”.

Afterwards press the “Connect” button. This button initiated a cyclic PROFINET communication.

The example application on the application controller will mirror the output data to the input data. I/O data can be manipulated and monitored in the I/O Data table.  Beside that if a connection is established, the “LED1” Led on the Arduino shield will be enabled.

Process data can be monitored and manipulated using the “IO Data” panel.

02_eip_io_data

Please start the example “02_eip_io_data” according to the previous description.

To establish an Ethernet/IP communication, at first the SoM must be selected in the “Network Navigator”. Then select the “EtherNet/IP Master” function panel. At first use “Scan device” to detect the EtherNet/IP device.

To establish an EtherNet/IP communication with the device, IP settings must be set according to the previous description. You can verify the current settings using the Management Tool.

To establish a cyclic EtherNet/IP communication use the I/O panel of the Master.

Default settings are compatible with the example. Press the “Connect” button. This button initiated a cyclic EtherNet/IP communication.

The example application on the application controller will mirror the output data to the input data.

I/O data can be manipulated and monitored in the I/O Data tables.  Beside that if a connection is established, the “LED1” and “LED2” Leds on the Arduino shield will both be green.

01_udp_receive

Please start the example “01_udp_receive” according to the previous description.

This example demonstrated networking from application controller. It provides a server, listening on IP address 192.168.0.25 and port 1234 and 1235. It will mirror any data received on those ports using UDP.

Please note that this example overwrites any taken IP settings for demonstration purpose.

01_http_get

Please start the example “01_http_get” according to the previous description.

Once started this example will provide simple web server functionality. It will deliver a simple web site showing the version number of the SoM.

Please consider the correct IP settings. Those can always be checked and manipulated using the management tool.