User manual

dsPICDEM™ MCSM Development Board User’s Guide
DS70610A-page 16 © 2009 Microchip Technology Inc.
4. Connect the 24V power supply to J6.
5. Press S1 to run the motor.
6. Vary the motor’s speed with the potentiometer.
7. Press S1 to switch to full-step wave mode, full-step, half-step and various
microstepping modes. Pushing S1 after the 256
th
microstep step setting stops
the motor. Press S1 again to repeat the cycle.
Operating the dsPICDEM MCSM Development Board using the on-board POT and
switch button cannot offer the flexibility required in most applications and it is only
intended as a quick start demonstration. To have more control over the motor using a
real-time communication tool, please refer to the next section.
2.2 PROGRAMMING AND DEBUGGING APPLICATION CODE
The following procedure describes how to program the dsPICDEM MCSM
Development Board in Debug mode:
1. Place the dsPICDEM MCSM Development Board on a sturdy insulated platform.
2. Make sure that the dsPIC33FJ32MC204 device or an appropriate PIM is
mounted in the respective socket.
3. Connect the stepper motor (42HS03) to J8. Connect motor phases in a bipolar
series connection as described in Table 2-1.
4. Connect the 24V power supply to J6.
5. Connect PICkit™ 3 In-Circuit Debugger/Programmer, MPLAB
®
ICD 3 or MPLAB
REAL ICE™ In-Circuit Emulator to the computer and to the board at J1 or J2.
6. Connect the USB cable to J4 and to the computer.
7. Download the code for the dsPIC33FJ32MC204 from the Microchip web site .
8. Build the project and download the program into the processor.
9. Click the Run icon when in Debug mode.
Note: For more information on running stepper motors, refer to
Section 1.4 “Reference Documents and Webinars”.