Application Note
R12AN0124EJ0100 Rev.1.00 Page 1 of 43
Jun.7, 2022
RZ/T2M Group
CN032 AC Servo Solution Startup Guide for Motion Control via EtherCAT
Introduction
This manual explains the procedure for performing motion control by EtherCAT® communication using
Renesas Electronics CN032 AC Servo Solution.
The sample program is dual core control, and by performing motion control with Cortex®-R52 and
performing EtherCAT communication with Cortex®-R52, communication processing is possible without
degrading the processing performance of motion control.
Data is exchanged between the two cores via the shared memory, and by access right management using
the semaphore register, access conflict to the shared memory is prevented.
EtherCAT communication processing implements the CiA402 drive profile and it is possible to evaluate more
practical control.
For details of each function, you can download documents separately from the Renesas Electronics website.
Target Device
RZ/T2M Group
Related Document
CN032 AC Servo Solution: Hardware Manual
CN032 AC Servo Solution: Firmware Manual
CN032 AC Servo Solution: Startup Guide for Motion Control via Tuning Tool
CN032 AC Servo Solution: Startup Guide for Motion Control via EtherCAT (this manual)
RZ/T2M Group Users Manual: Hardware
R12AN0124EJ0100
Rev.1.00
Jun.7, 2022
RZ/T2M Group Startup Guide for Motion Control via EtherCAT
R12AN0124EJ0100 Rev.1.00 Page 2 of 43
Jun.7, 2022
Contents
1. Operating Environment ............................................................................................................ 4
2. Preparation of CN032 AC Servo Solution ................................................................................ 5
2.1 Connecting the Logic and Motor Power .............................................................................................. 5
2.2 Connecting the Motor Windings........................................................................................................... 5
2.3 Connecting the Encoder ...................................................................................................................... 6
2.4 Connecting the UART communication cable ....................................................................................... 6
2.5 Connecting the JTAG interface ............................................................................................................ 7
2.6 Connecting the Ethernet Interface ....................................................................................................... 7
2.7 Overall connection configuration ......................................................................................................... 7
2.8 Power supply to the board ................................................................................................................... 8
3. Preparing EtherCAT Communication ....................................................................................... 9
3.1 TwinCAT
®
3 Installation ........................................................................................................................ 9
3.2 Copying the ESI File .......................................................................................................................... 13
4. Confirm Communication with TwinCAT
®
3 .............................................................................. 14
4.1 Starting TwinCAT
®
3 ........................................................................................................................... 14
4.2 Checking the Communication Status ................................................................................................ 18
4.3 Sending Data to CN032 AC Servo Solution ...................................................................................... 20
5. Appendix ............................................................................................................................... 24
5.1 Preparation in advance ...................................................................................................................... 24
5.1.1 Power Supply ............................................................................................................................... 24
5.1.2 Generating the Slave Stack Code ................................................................................................ 25
5.2 Program Writing Procedure ............................................................................................................... 28
5.2.1 Program writing by IAR EWARM ................................................................................................ 28
5.3 Debugging the Sample Project .......................................................................................................... 30
5.3.1 Debugging the Sample Project in IAR EWARM........................................................................... 30
5.3.2 Debugging the Sample Project in Renesas e2studio .................................................................. 33
5.4 EEPROM Data Update on CN032 AC Servo Solution ...................................................................... 39
Revision History ............................................................................................................................ 43