Skip to content

Infineon/REF_36V_220W_SLFOC

Repository files navigation

REF_36V_220W_SLFOC

This is the readme file for the firmware project of board REF_36V_220W_SLFOC.

System Overview

alt text

Key Features and Benefits

  • Generic motor control with speed control scheme
  • Robotic wheel application with position control scheme
  • Equation based stall detection
  • High efficiency
  • Compact design
  • High power density

Board Connection

Board Overview

alt text

Debugger

An external debugger must be connected to the board for

  • debugging/programming
  • GUI demonstration

XMC Link is validated and is suggested as the external debugger.

  • Use the first 4 pins of the 10-pin connector to connect to the board connector.

alt text

Motor

A planetary gear motor Z42BLDPN is used for testing. Connect the motor terminals (U, V and W) to the board inverter output.

Motor Parameters

alt text

Some motor parameters should be modified in the firmware if a different motor is used.

Software Tools

Tools

Tool Version Description
Infineon Developer Center 2024.8.0 One stop shop for engineers for downloading and design-in of all Infineon development tools, embedded software, services and solutions
ModusToolbox 3.2.0.16028 A modern, extensible development ecosystem supporting a wide range of Infineon microcontroller devices. It can be downloaded from “Infineon Developer Center”
Micriμm μC/Probe XMC 4.3.0.90 A Windows application designed to read and write the memory of the controller during run-time. In this project it is used to run the motor and read the status
J-Link 7.96d The widely used line of debug probes. It is used for debug/programming and communication between the PC and the board

Firmware

Obtain the Firmware

The firmware is shared via GitHub.

  1. Access to the repository with this link
  2. Clone or download the firmware

Create the Project

  1. Run ModusToolbox
  2. Create a new workspace or use an existing workspace
  3. Create a new application: File-> New-> ModusToolbos Application alt text
  4. “Project Creator” pops up
  5. Choose the “Board Support Package (BSP)”. Select “EVAL_IMD700A_FOC_3SH”, as the REF board is based on this EVAL board
  6. Click on “Next” alt text
  7. Click on “Browse for Application”
    • Then select the application code in the package as the template application
    • The imported application can be found in the “Import” drop-down menu. A new application name can be assigned.
  8. The new project will be created by clicking on the “Create” button. alt text
  9. After the project is created, “mtb_shared” and the application example can be found on the “Project Explorer”.

Parameters Configuration

  • The most important parameters are defined in the header file PMSM_FOC\Configuration\pmsm_foc_user_input_config_xxx.h. _xxx is for differentiating the configurations for different motors. The motor for this project is defined in the file PMSM_FOC\Configuration\pmsm_foc_user_input_config.h.

  • If a different motor is used, the parameters in the motor group should be modified.

  • Other parameters (e.g. control loops) in the header file should be modified if necessary.

alt text

Build and Debug

  1. Build the project
  2. Debug the project
  3. Click on “Resume” to run the project

alt text

Demo GUI

Overview

Micriμm μC/Probe XMC is used for demonstration and control of the motor. The layout of the GUI is designed for the robotic wheel drive application with this specific motor.

  • If the motor parameters (e.g. the pole-pair number, the gear ratio…) is changed, the scaling in the GUI may need to be changed in order to display the values correctly.

alt text

GUI Operation

  1. Open the configuration file DEMO_GUI_uC-Probe.wspx.
    • The file can be found in the GUI folder of the firmware package.
  2. Load the ELF file mtb-example-xmc-foc-3-shunt.elf.
    • The file can be found in the location build/APP_EVAL_IMD700A_FOC_3SH/Debug/mtb-example-xmc-foc-3-shunt.elf.
    • If there is an existing “.elf” file in the “All Symbols” window, remove it before loading your own “.elf” file.
  3. Click on “Run” button to connect the GUI with the board.

alt text

GUI Functionality

  • Speed reference setting
  • Motor RUN/STOP
  • Demo examples demonstrate position control automatically
  • Clear the fault if there is a fault by mistake

alt text

End of file

Releases

No releases published

Packages

No packages published