Академический Документы
Профессиональный Документы
Культура Документы
STEP
CW/CCW
RPM +
RPM -
Start/Stop
Control
Step
Control
Direction
Control
Commutation
Logic
Stat e
Machine
Speed
Control
DRIVE
CIRCUIT
Phase
Outputs
PHASEA_H
MSTP_OR_BL_MD_H
Stepper_module
FULL_HALF_OR_CAD_H
PHASEA_L
PHASEB_H
STEPPER_RNG_H
Stepper Motor
State Machine
hw_ctrl
PHASEB_L
CW_OR_CCW_H
Debounce
blk
STOP_H
PHASEC_H
HW/SW
MUX
PHASEC_L
RUN_H
Micro Step
Ctrl
PLUS_H
PHASED_H
PHASED_L
MINUS_H
STEP_H
stepper_clk
pwm_out
MST_OR_BD_BL_H
HW_SW
sw_ctrl
Stepper_
clk_gen
pwm_gen
_stepper
RxD
Serial
TxD
clkgen
SYS_CLK
clk_10mhz
Clkdiv
20M_to_10M
RST
Sequence
1
2
3
4
1
1
0
0
0
0
1
1
1
0
0
1
0
1
1
0
Clockwise
Sequence
1
2
3
4
5
6
7
8
1
1
1
0
0
0
0
0
0
0
0
0
1
1
1
0
1
0
0
0
0
0
1
1
0
0
1
1
1
0
0
0
Clockwise
!Start
RST
Stop
Start
IDLE
Step
STEP
PHASE
RUN
PHASE
Apply stepper
sequences based on
Full/Half Step mode
Stop
Apply next stepper sequence based on
Full/Half Step mode setting
Figure 3. Stepper Motor Control State Machine
4.0 Waveforms
One Sequence
A_HIGH
A_LOW
B_HIGH
B_LOW
C_HIGH
C_LOW
D_HIGH
D_LOW
4/8/16 Steps
5.0 I/Os
The following table describes the main I/Os in the design.
Signal Name
RxD
TxD
CW_OR_CCW_H
Input/
Output
Input
Output
Input
MSTP_OR_BL_MD_H
Input
STOP_H
MST_OR_BD_BL_H
Input
Input
RUN_H
RANGE_SELECT_H
Input
Input
SYS_RESET
PHASEA_H
PHASEA_L
PHASEB_H
PHASEB_L
PHASEC_H
PHASEC_L
PHASED_H
PHASED_L
FULL_HALF_OR_CAD_H
Input
Output
Output
Output
Output
Output
Output
Output
Output
Input
STEP_H
Input
HW_SW
Input
PLUS_H
MINUS_H
SYS_CLK
Input
Input
Input
Description
RS232 Receive
RS232 Transmit
Motor Direction Control
1 Clockwise
0 Counterclockwise
For Stepper Motor, in micro step mode
No. of Micro step
0 8steps
1 16steps
Motor Stop
For stepper motor
Microstepping ON/OFF
1 ON, 0 OFF
Motor Start/Run
Stepper Motor Range Select
ON 1440 RPM, OFF 720 RPM
System Reset (Pulse through Switch SW6)
PhaseA High Side Signal
Phase A Low Side Signal
PhaseB High Side Signal
PhaseB Low Side Signal
PhaseC High Side Signal
PhaseC Low Side Signal
PhaseD High Side Signal
PhaseD Low Side Signal
For stepper motor
Step Size when microstepping off
1 Full Step (20 steps per revolution) 18
degrees per step
0 Half Step (40 steps per revolution) 9
degrees per step (If supported by motor)
Step Motor in Half or Full Step depending on
FULL_HALF_STEP_H
Hardware or Software Control
ON Hardware, OFF Software
Increment Speed
Decrement Speed
Sys Clock 20mhz
Fusion Pin
C31
B34
A31
A21
A7
B2
C4
B37
C1
C26
B30
A36
C32
C2
A16
A4
A20
A37
A11
A35
A23
A26
A5
6.0 Conclusion:
This design example allows the user to run a stepper motor using the low-power IGLOO device.
The design has been specifically developed with the drive circuit in mind. Please refer to the
Icicle motor control documentation for detailed usage of the IP and the features available
through hardware and software.
Functionality
This block generates baud clk for Serial Comm.
Divides input clock by 2 - Toggle F/F.
Clock Generator.
Debounce Logic Block.
Interconnects all debounce blocks.
Divide by 16 block for serial communication baud clock.
Derived Clock for internal use.
Generate 10 MHz from 20 MHz Input.
Defines/Parameters for the design.
This block receives data serially on RxD.
This block generates software controls for stepper motor
This block multiplexes between hardware and software controls.
This block transmits data serially on TxD.
Generates required stepper clock based on +/- switch inputs.
Stepper clock PWM for Microstep mode.
Generate signals to drive motor .
This block connects xmit_control, recv_control, serial, baud_clk_gen
and div_by_16 .
Top interconnect block pwm_gen_stepper, stepper_module and
stepper_clk_gen
This block interconnects top_stepper and clk_gen
This block interconnects clkdiv_20M_to_10M and stepper_ip
Testbench for stepper_ip
About Ishnatek
Ishnatek offers FPGA design and hardware prototyping services. Ishnatek offers Design and
Verification Services for embedded solutions. We have IPs such as 8031, RTC, Timers,
Enhanced PWM, UART/SIO/IrDA, I2C, LED Driver and Key scan, Parallel Port, ECP/EPP, etc.,
which can be building blocks for your embedded controller solutions.