MTRCKTSPNZVM128 Quick Start Guide

MagniV
MC9S12ZVML128 MCU
Quick Start Guide
3-phase Sensorless PMSM
Motor Control Development Kit
Quick Start Guide
3-Phase Sensorless BLDC Kit with MagniV
MC9S12ZVML128 MCU
3-Phase
PMSM/BLDC Motor
S12 MagniV
MC9S12ZVML128
Evaluation Board
2
freescale.com
3-Phase Sensorless BLDC Kit with
MagniV MC9S12ZVML128 MCU
Hardware
Resources
• MagniV MC9S12ZVML128 Evaluation
Board with integrated 3-phase 12V/10A
power stage
• Sensorless control using Back-EMF
zero-crossing detection application
source code
• 3-Phase PMSM/BLDC Motor with HALL
sensor, 24 VDC, 9350 RPM, 90W,
45ZWN2490B
• Automotive math and motor control
library set for MC9S12ZVM installation
package
• USB cable
• FreeMASTER installation pack
• 12 VDC power supply
• FreeMASTER project
• 3-phase sensorless PMSM kit with
MagniV MC9S12ZVML128 MCU quick
start guide
• 3-phase sensorless PMSM Kit with
MagniV MC9S12ZVML128 MCU fact
sheet
• 3-phase sensorless PMSM Kit with
MagniV MC9S12ZVML128 MCU
application note
• MagniV MC9S12ZVML128 Evaluation
Board user guide
3
Quick Start Guide
Get to Know the MagniV MC9S12ZVML128
Evaluation Board
CAN
Option
User
Buttons
User
Switch
Power
Indicator
LEDs
OSBDM
LIN
Connector
Hall/
Encoder
Interface
Freemaster
USB-to-SCI
Interface
Motor
BDM
Interface
Potentiometer
Routed to
ADC Input
Power
Supply
User LEDs
Resolver
Interface
4
6x Power
MOSFETs
Power
Supply
Terminal
freescale.com
Software Tools Installation
1
Install the FreeMASTER debugging
tool. For FreeMASTER application
download, please visit
freescale.com/freemaster.
Install the CP210x virtual COM
port driver. For the CP210x virtual
COM port driver installation file,
please visit Downloads section at
freescale.com/automcdevkits.
2
Run “Device Manager” on your
system.Check which COM port
was assigned to the CP210x
COM port driver.
3
4
Connect the USB cable to the
MagniV MC9S12ZVML128
Evaluation Board and the host PC.
5
Connect the power supply to
the MagniV MC9S12ZVML128
Evaluation Board.
6
Start the FreeMASTER project
MC9S12ZVML128_PMSM_
Sensorles s.pmp located in
MTRCKTSPNZVM128\SW\
MC9S12ZVML128_PMSM_Sensorless
project directory.
Enable communication by pressing
the “STOP” button in the
FreeMASTER, or by pressing
“CTRL+K.”
7
Successful communication is
signalized in the status bar. If the
communication is not established,
check the USB connection between the
PC and MagniV MC9S12ZVML128
Evaluation Board, communication port and
speed. The communication port and speed
can be set in the Project\Options menu (or
pressing “CTRL+T”). The communication
speed must be set at 19200 Bd.
8
5
Quick Start Guide
Application Control
1
When the power supply is
connected to EVB Board the
PMSM motor is in stop mode.To
start the motor use the user switch. Blue
LED1 (D14) connected to port PS4) of
MC9S12ZVML128 Evaluation Board has
following functionality:
• OFF if the application is in the READY,
INIT states
• Slow flashing if the application is in the
• CALIB, ALIGN states (flashing with a
period of 2 Hz)
• ON if the application is in the RUN state
• Fast flashing if the application is in the
• FAULT state (flashing with a period
of 8 Hz)
2
If no actual faults are present in the
system, all the LED-like indicators
on the FreeMASTER control page
will be dark red. If there is a fault present,
identify the source of the fault and remove
it. Successful removal is signalized by the
switching off of the respective LED-like
indicator on the FreeMASTER control page.
6
3
Press the UP+ DOWN (SW1 +
SW2) buttons on the
MC9S12ZVML128 Evaluation Board
simultaneously to clear the fault status
register once in the FAULT state. The
application can be restarted by positioning
the ON/OFF switch (SW3) on
MC9S12ZVML128 Evaluation Board to the
RUN position (transition from STOP to RUN
in case the switch was in the RUN state
when the fault event occurred).
4
If all the LED-like indicators on the
FreeMASTER control page are off,
clear pending faults by pressing the
green circled button “FAULT CLEAR” on
the FreeMASTER control page, or
alternatively by pressing the UP+DOWN
buttons (SW2+SW1) on the
MC9S12ZVML128 Evaluation Board
simultaneously. The ON/OFF switch (SW3)
on the MC9S12ZVML128 Evaluation Board
must be in OFF position.
freescale.com
Application Control (cont.)
5
Start the application by pressing 1“RUN” on the flip/flop (ON/OFF)
switch on the FreeMASTER control
page or by positioning the ON/OFF switch
(SW3) on the MC9S12ZVML128 Evaluation
Board to the ON position (transition from
OFF to ON in case the switch was in the
ON state when a fault event occurred).
7
Stop the application by pressing
0-“STOP” on the flip/flop (ON/OFF)
switch on the FreeMASTER control
page, or by positioning the ON/OFF switch
(SW3) on the MC9S12ZVML128 Evaluation
Board to the OFF position.
6
Enter the required speed by
assigning this value to the “Speed
Required” variable in the variables
watch window. The value is in revolutions
per minute. Alternatively, the rotor speed
can be increased/decreased by pressing
the UP/DOWN switches on the
MC9S12ZVML128 Evaluation Board.
7
Quick Start Guide
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options
Jumper
J2
J3
J4
J5
J6
8
Option
CAN Transceiver
5V supply option
VDDC supplied
from USB option
RESET LED
indicator option
VDDX LED
indicator option
VSUP LED
indicator option
Setting
Description
Open
VDDC ballast transistor is not supplied from VSUP
Close
VDDC ballast transistor is supplied from VSUP
Open
VDDC node is not supplied from the USB-to-SCI interface
Close
VDDC node is supplied from the USB-to-SCI interface
Open
RESET LED indicator disabled
Close
RESET LED indicator enabled
Open
VDD LED indicator disabled
Close
VDD LED indicator enabled
Open
VSUP LED indicator disabled
Close
VSUP LED indicator enabled
freescale.com
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options (cont)
Jumper
J9
J10
J12
J14
J15
Option
ON/OFF
switch option
OSDBM bootloader option
Resolver circuit
5V supply option
EVDD or FAULT
selector
Resolver or
Hall/Encoder
Phase A
selector
Setting
Description
Open
ON/OFF switch disabled
Close
ON/OFF switch enabled
Open
OSBDM Boot-loader disabled
Close
OSBDM Boot-loader enabled
Open
Resolver Inputs circuitry (+5VDC) supply disabled
Close
Resolver Inputs circuitry (+5VDC) supply enabled
1-2
FAULT input is connected to port PP0
2-3
Port PP0 is connected to EVDD at Hall sensor interface
1-2
Phase A from Resolver is connected to port PT1
2-3
Phase A from Hall / Encoder interface is connected to port PT1
9
Quick Start Guide
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options (cont)
Jumper
J16
J18
J19
J20
J27
10
Option
Setting
Description
Resolver or
Hall/Encoder
Phase B
Selector
1-2
Phase B from Hall/Encoder interface is connected to port PT2
2-3
Phase B from Resolver is connected to port PT2
USB-to-SCI
interface supply
option
Open
USB-to-SCI isolator supply disable
Close
USB-to-SCI isolator supply disable
Open
“UP” push button disabled
Close
“UP” push button enabled
Open
“DOWN” push button disabled
Close
“DOWN” push button enabled
“UP” pushbutton option
“DOWN” pushbutton option
SCI RXD
selector
1-2
RXD from OSBDM is connected to port PS2
2-3
RXD from USB-to-SCI is connected to port PS2
freescale.com
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options (cont)
Jumper
J28
J29
J30
J33
J35
Option
SCI TXD
selector
BDM interface
supply option
ADC
potentiometer
pull-up option
Microcontroller
supply option
ADC mapping–
PAD0
Setting
Description
1-2
TXD from OSBDM is connected to port PS3
2-3
TXD from USB-to-SCI is connected to port PS3
Open
BDM supply disabled
Close
BDM supply enabled
Open
POT 1 (ADC potentiometer) supply disabled
Close
POT 1 (ADC potentiometer) supply enabled
Open
MCU supply disabled
Close
MCU supply enabled
1-2
Connects PAD0 to AMP0 external gain-setting resistors
2-3
Connects PAD0 to POS_SIN resolver output
11
Quick Start Guide
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options (cont)
Jumper
J36
J37
J38
J39
J40
12
Option
VREF generation
supply option
USER LED1
option
Setting
Description
Open
Disconnects VSUP to supply a regulated voltage at VREF2
Close
Connects VSUP to supply a regulated voltage at VREF2
Open
“User LED1” disabled
Close
“User LED1” enabled
Open
PDO-PDOCLK not shorted
Close
PDO-PDOCLK shorted
PDO-PDOCLK
Resolver
phase B
selector
VDDX ballast
supply option
1-2
pins 1-2 closed – SINCOS I/O connector Phase B connected to
Resolver Phase B input
2-3
pins 2-3 closed – POS_COS connected to Resolver Phase B
input
Open
VDDX ballast is disconnected
Close
VDDX ballast is connected
freescale.com
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options (cont)
Jumper
J43
J44
J45
J46
Option
Resolver circuit
12V supply
option
ADC mapping –
PAD1
ADC mapping –
PAD2
ADC mapping –
PAD3
Setting
Open
Description
Resolver generator circuit supply disconnected
Close
Resolver generator circuit supply connected
Open
PAD1 is disconnected from the AMPM0 external gain-setting
resistors
Close
PAD1 is connected to the AMPM0 external gain-setting resistors
Open
PAD2 is disconnected from the AMPP0 external gain-setting
resistors
Close
PAD2 is connected to the AMPP0 external gainsetting resistors
1-2
Connects PAD3 to ADC_IA (phase A current sense from
external op-amp)
2-3
Connects PAD3 to POS_SIN resolver output
13
Quick Start Guide
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options (cont)
Jumper
J47
J48
J49
J50
14
Option
ADC mapping –
PAD4
ADC mapping –
PAD5
Resolver
phase A
selector
ADC mapping –
PAD6
Setting
Description
1-2
Connects PAD4 to ADC_IB (phase B current sense from external
op-amp)
2-3
Connects PAD4 to ADC potentiometer POT1
1-2
Connects PAD5 to AMP1 external gain setting resistors
2-3
Connects PAD5 to ADC_IB (phase B current sense from external
op-amp)
1-2
Resolver phase A connected to SINCOS I/O connector
Phase A input
2-3
Resolver phase A connected to Resolver POS_SIN SchmittTrigger
1-2
Connects PAD6 to AMPM1 external gain-setting resistors
2-3
Connects PAD6 to POS_COS resolver output
freescale.com
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options (cont)
Jumper
J51/42
Option
ADC mapping –
PAD7
Setting
Connects PAD7 to AMPP1 external gain-setting resistors
J51(2-3)
Connects PAD7 to POS_SIN resolver output
J42(1)J51(2)
J52
J53
J55
ADC mapping –
PAD8
USER LED2
option
Description
J51(1-2)
Connects PAD7 to ADC potentiometer POT1
1-2
Connects PAD8 to ADC_IC (phase C current sense from external
op-amp)
2-3
Connects PAD8 to POS_COS resolver output
Open
“User LED 2” disabled
Close
“User LED 2” enabled
1-2
VREF supplied from VDDX
2-3
VREF supplied from the VREF2 regulator
VREF selector
15
Quick Start Guide
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options (cont)
Jumper
J56
J57
J59
J60
16
Option
Resolver COS
reference
Internal AMP0
input selector
(inverting)
Resolver SIN
reference
Internal AMP0
input selector
(non-inverting)
Setting
1-2
Description
Input to POS_COS circuit is from OFFSET1
2-3
Input to POS_COS circuit is from RES_COS_REF
1-2
Connects DC Bus to the internal AMP0 inverting input
(Phase A current sense)
2-3
Connects Ground to the internal AMP0 inverting input
(DC Bus current sense)
1-2
Input to POS_SIN circuit is from RES_SIN_REF
2-3
Input to POS_SIN circuit is from OFFSET1
1-2
Connects Phase A to the internal AMP0 noninverting input
(Phase A Current sense)
2-3
Connects DC Bus as non-inverting input for internal AMP0 (DC
Bus current sense)
freescale.com
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options (cont)
Jumper
J63
Option
FAULT
comparators 5V
supply option
Setting
Description
Open
FAULT circuit supply disconnected
Close
FAULT circuit supply connected
17
Quick Start Guide
MagniV MC9S12ZVML128 Evaluation Board
Jumper Options
FreeMASTER
USB-to-SCI
Interface
J18
J27
J28
BDM
Interface
J29
J38
User
LEDs
J37
J53
User Buttons
User Switch
J19 J20
J9
J35 J44 J45 J57 J60
Phase A
Current Sense
18
J51 J50 J48
Phase B
Current Sense
Support
Visit freescale.com/support for a list of phone
numbers within your region.
Warranty
Visit freescale.com/warranty for complete
warranty information.
For more information, visit
freescale.com/automcdevkits
Freescale, the Freescale logo and CodeWarrior are trademarks of Freescale
Semiconductor, Inc. , Reg. U.S. Pat. & Tm. Off. MagniV is a trademark of
Freescale Semiconductor, Inc. All other product or service names are the
property of their respective owners. © 2015 Freescale Semiconductor, Inc.
Doc Number: MTRCKTSPNZVM128QSG REV 0
Agile Number: 926-28715 REV A