MCP1630 Boost Mode LED Driver Demo Board User’s Guide © 2007 Microchip Technology Inc. DS51665B Note the following details of the code protection feature on Microchip devices: • Microchip products meet the specification contained in their particular Microchip Data Sheet. • Microchip believes that its family of products is one of the most secure families of its kind on the market today, when used in the intended manner and under normal conditions. • There are dishonest and possibly illegal methods used to breach the code protection feature. All of these methods, to our knowledge, require using the Microchip products in a manner outside the operating specifications contained in Microchip’s Data Sheets. Most likely, the person doing so is engaged in theft of intellectual property. • Microchip is willing to work with the customer who is concerned about the integrity of their code. • Neither Microchip nor any other semiconductor manufacturer can guarantee the security of their code. Code protection does not mean that we are guaranteeing the product as “unbreakable.” Code protection is constantly evolving. We at Microchip are committed to continuously improving the code protection features of our products. Attempts to break Microchip’s code protection feature may be a violation of the Digital Millennium Copyright Act. If such acts allow unauthorized access to your software or other copyrighted work, you may have a right to sue for relief under that Act. Information contained in this publication regarding device applications and the like is provided only for your convenience and may be superseded by updates. It is your responsibility to ensure that your application meets with your specifications. MICROCHIP MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND WHETHER EXPRESS OR IMPLIED, WRITTEN OR ORAL, STATUTORY OR OTHERWISE, RELATED TO THE INFORMATION, INCLUDING BUT NOT LIMITED TO ITS CONDITION, QUALITY, PERFORMANCE, MERCHANTABILITY OR FITNESS FOR PURPOSE. Microchip disclaims all liability arising from this information and its use. Use of Microchip devices in life support and/or safety applications is entirely at the buyer’s risk, and the buyer agrees to defend, indemnify and hold harmless Microchip from any and all damages, claims, suits, or expenses resulting from such use. No licenses are conveyed, implicitly or otherwise, under any Microchip intellectual property rights. Trademarks The Microchip name and logo, the Microchip logo, Accuron, dsPIC, KEELOQ, KEELOQ logo, microID, MPLAB, PIC, PICmicro, PICSTART, PRO MATE, rfPIC and SmartShunt are registered trademarks of Microchip Technology Incorporated in the U.S.A. and other countries. AmpLab, FilterLab, Linear Active Thermistor, Migratable Memory, MXDEV, MXLAB, SEEVAL, SmartSensor and The Embedded Control Solutions Company are registered trademarks of Microchip Technology Incorporated in the U.S.A. Analog-for-the-Digital Age, Application Maestro, CodeGuard, dsPICDEM, dsPICDEM.net, dsPICworks, ECAN, ECONOMONITOR, FanSense, FlexROM, fuzzyLAB, In-Circuit Serial Programming, ICSP, ICEPIC, Mindi, MiWi, MPASM, MPLAB Certified logo, MPLIB, MPLINK, PICkit, PICDEM, PICDEM.net, PICLAB, PICtail, PowerCal, PowerInfo, PowerMate, PowerTool, REAL ICE, rfLAB, Select Mode, Smart Serial, SmartTel, Total Endurance, UNI/O, WiperLock and ZENA are trademarks of Microchip Technology Incorporated in the U.S.A. and other countries. SQTP is a service mark of Microchip Technology Incorporated in the U.S.A. All other trademarks mentioned herein are property of their respective companies. © 2007, Microchip Technology Incorporated, Printed in the U.S.A., All Rights Reserved. Printed on recycled paper. Microchip received ISO/TS-16949:2002 certification for its worldwide headquarters, design and wafer fabrication facilities in Chandler and Tempe, Arizona; Gresham, Oregon and design centers in California and India. The Company’s quality system processes and procedures are for its PIC® MCUs and dsPIC® DSCs, KEELOQ® code hopping devices, Serial EEPROMs, microperipherals, nonvolatile memory and analog products. In addition, Microchip’s quality system for the design and manufacture of development systems is ISO 9001:2000 certified. DS51665B-page ii © 2007 Microchip Technology Inc. MCP1630 BOOST MODE LED DRIVER DEMO BOARD USER’S GUIDE Table of Contents Preface ........................................................................................................................... 1 Introduction............................................................................................................ 1 Document Layout .................................................................................................. 1 Conventions Used in this Guide ............................................................................ 2 Recommended Reading........................................................................................ 3 The Microchip Web Site ........................................................................................ 3 Customer Support ................................................................................................. 3 Document Revision History ................................................................................... 4 Chapter 1. Product Overview ....................................................................................... 5 1.1 Introduction ..................................................................................................... 5 1.2 Features ......................................................................................................... 5 1.3 Device Summary ............................................................................................ 5 1.4 Technical Specifications ................................................................................. 6 Chapter 2. Installation and Operation ......................................................................... 7 2.1 Getting Started ............................................................................................... 7 2.2 What the MCP1630 Boost Mode LED Driver Demo Board Kit includes ......... 7 2.3 Setup Procedures ........................................................................................... 8 2.4 Circuit Description .......................................................................................... 9 2.5 Firmware Description ................................................................................... 10 Appendix A. Schematic and Layouts ........................................................................ 13 A.1 Introduction .................................................................................................. 13 A.2 Board - Schematic ....................................................................................... 14 A.3 Board - Top Layer ........................................................................................ 15 A.4 Board - Top Silk Layer ................................................................................. 16 A.5 Board - Bottom Layer ................................................................................... 17 Appendix B. Bill Of Materials (BOM) ......................................................................... 19 Appendix C. Firmware Flowchart .............................................................................. 21 Worldwide Sales and Service .................................................................................... 24 © 2007 Microchip Technology Inc. DS51665B-page iii MCP1630 Boost Mode LED Driver Demo Board User’s Guide NOTES: DS51665B-page iv © 2007 Microchip Technology Inc. MCP1630 BOOST MODE LED DRIVER DEMO BOARD USER’S GUIDE Preface NOTICE TO CUSTOMERS All documentation becomes dated, and this manual is no exception. Microchip tools and documentation are constantly evolving to meet customer needs, so some actual dialogs and/or tool descriptions may differ from those in this document. Please refer to our web site (www.microchip.com) to obtain the latest documentation available. Documents are identified with a “DS” number. This number is located on the bottom of each page, in front of the page number. The numbering convention for the DS number is “DSXXXXXA”, where “XXXXX” is the document number and “A” is the revision level of the document. For the most up-to-date information on development tools, see the MPLAB® IDE on-line help. Select the Help menu, and then Topics to open a list of available on-line help files. INTRODUCTION This chapter contains general information that will be useful to know before using the MCP1630 Boost Mode LED Driver Demo Board. Items discussed in this chapter include: • • • • • • Document Layout Conventions Used in this Guide Recommended Reading The Microchip Web Site Customer Support Document Revision History DOCUMENT LAYOUT This document describes how to use the MCP1630 Boost Mode LED Driver Demo Board as a development tool to evaluate the MCP1630 and other Microchip components.. The manual layout is as follows: • Chapter 1. “Product Overview” – Important information about the MCP1630 Boost Mode LED Driver Demo Board. • Chapter 2. “Installation and Operation” – Includes instructions on how to get started with this user’s guide and a description of the user’s guide. • Appendix A. “Schematic and Layouts” – Shows the schematic and layout diagrams for the MCP1630 Boost Mode LED Driver Demo Board. • Appendix B. “Bill Of Materials (BOM)” – Lists the parts used to build the MCP1630 Boost Mode LED Driver Demo Board. • Appendix C. “Firmware Flowchart” - Provides a flow chart of the firmware for the MCP1630 Boost Mode LED Driver Demo Board © 2007 Microchip Technology Inc. DS51665B-page 1 MCP1630 Boost Mode LED Driver Demo Board User’s Guide CONVENTIONS USED IN THIS GUIDE This manual uses the following documentation conventions: DOCUMENTATION CONVENTIONS Description Arial font: Italic characters Represents Referenced books Emphasized text A window A dialog A menu selection A field name in a window or dialog A menu path MPLAB® IDE User’s Guide ...is the only compiler... the Output window the Settings dialog select Enable Programmer “Save project before build” A dialog button A tab A number in verilog format, where N is the total number of digits, R is the radix and n is a digit. A key on the keyboard Click OK Click the Power tab 4‘b0010, 2‘hF1 Italic Courier New Sample source code Filenames File paths Keywords Command-line options Bit values Constants A variable argument Square brackets [ ] Optional arguments Curly brackets and pipe character: { | } Ellipses... Choice of mutually exclusive arguments; an OR selection Replaces repeated text #define START autoexec.bat c:\mcc18\h _asm, _endasm, static -Opa+, -Opa0, 1 0xFF, ‘A’ file.o, where file can be any valid filename mcc18 [options] file [options] errorlevel {0|1} Initial caps Quotes Underlined, italic text with right angle bracket Bold characters N‘Rnnnn Text in angle brackets < > Courier New font: Plain Courier New Represents code supplied by user DS51665B-page 2 Examples File>Save Press <Enter>, <F1> var_name [, var_name...] void main (void) { ... } © 2007 Microchip Technology Inc. Preface RECOMMENDED READING This user's guide describes how to use MCP1630 Boost Mode LED Driver Demo Board. The following Microchip documents are available and recommended as supplemental reference resources. MCP1630/MCP1630V Data Sheet, "High-Speed, Microcontroller-Adaptable, Pulse Width Modulator" (DS21896) This data sheet provides detailed information regarding the MCP1630 family. PIC12F683 Data Sheet, (DS41211) This data sheet provides detailed information regarding the PIC12F683 product. MCP1702 Data Sheet, "250 mA Low Quiescent Current LDO Regulator" (DS22008) This data sheet provides detailed information regarding the MCP1702 product. THE MICROCHIP WEB SITE Microchip provides online support via our web site at www.microchip.com. This web site is used as a means to make files and information easily available to customers. Accessible by using your favorite Internet browser, the web site contains the following information: • Product Support – Data sheets and errata, application notes and sample programs, design resources, user’s guides and hardware support documents, latest software releases and archived software • General Technical Support – Frequently Asked Questions (FAQs), technical support requests, online discussion groups, Microchip consultant program member listing • Business of Microchip – Product selector and ordering guides, latest Microchip press releases, listing of seminars and events, listings of Microchip sales offices, distributors and factory representatives CUSTOMER SUPPORT Users of Microchip products can receive assistance through several channels: • • • • Distributor or Representative Local Sales Office Field Application Engineer (FAE) Technical Support Customers should contact their distributor, representative or field application engineer for support. Local sales offices are also available to help customers. A listing of sales offices and locations is included in the back of this document. Technical support is available through the web site at: http://support.microchip.com © 2007 Microchip Technology Inc. DS51665B-page 3 MCP1630 Boost Mode LED Driver Demo Board User’s Guide DOCUMENT REVISION HISTORY Revision B (June 2007) • • • • • Changed MCP1630 device to MCP1630V throughout document Added additional verbiage in Section 1.1 Introduction Updated Figure 1-1 Updated schematic to show MPC1630V device Changed MCP1630 device part number in BOM to MCP1630V device Revision A (May 2007) • Initial Release of this Document. DS51665B-page 4 © 2007 Microchip Technology Inc. MCP1630 BOOST MODE LED DRIVER DEMO BOARD USER’S GUIDE Chapter 1. Product Overview 1.1 INTRODUCTION The MCP1630 Boost Mode LED Driver Demo Board is a step-up, switch-mode, dc-dc converter used for power LED applications. The demo board provides a 350 mA or 700 mA constant current source with a jumper selection. Other output currents can be obtained with minor modifications to the board. The MCP1630 Boost Mode LED Driver Demo Board utilizes Microchip's MCP1630V high-speed pulse width modulator. The 8-pin MCP1630V device contains the analog components necessary for an analog switch-mode control loop including an error amplifier, PWM comparator, and a high current driver pin. The switching frequency and maximum duty cycle for the MCP1630V are determined by an external clock source. An 8-pin PIC12F683 microcontroller is used to provide a 500 kHz switching clock for the MCP1630. In addition, the PIC12F683 firmware supervises the circuit output voltage and can optionally dim the LEDs when a potentiometer is attached. In this demo application, the MCP1630V device is used for Average Current mode control using a voltage boost circuit. A ramp generator provides a reference signal to the MCP1630V comparator. The ramp signal and error amplifier output voltage determine the PWM duty cycle for the voltage boost circuit. The MCP1630V device is used because its error amplifier provides a higher output voltage range than the MCP1630 device (2.7V vs. 0.9V). Note: 1.2 MCP1630 is used throughout this document for both the MCP1630 and MCP1630V devices. FEATURES The MCP1630 Boost Mode LED Driver Demo Board has the following features: • • • • • • • Compact size with high output power High efficiency over entire operating input voltage range Selectable output current: 350 mA or 700 mA Maximum output power: 30W Optional software dimming control Factory programmed source code provided Switching frequency, maximum duty cycle, and MCP1630 reference voltage can be modified in firmware • Additional application functions can be provided in firmware © 2007 Microchip Technology Inc. DS51665B-page 5 MCP1630 Boost Mode LED Driver Demo Board User’s Guide 1.3 DEVICE SUMMARY The MCP1630 Boost Mode LED Driver Demo Board uses the following primary devices on the board. • A MCP1702 LDO regulator is used to supply the regulated voltage to the PIC12F683 and the MCP1630. The MCP1702 is capable of delivering 250 mA with only 650 mV (typical) of input to output voltage differential • A MCP1630, a high-speed pulse width modulator IC, is used. When used in conjunction with a microcontroller, the MCP1630 will control the power system duty cycle to provide output current and/or voltage regulation • A PIC12F683 microcontroller (MCU) is used to generate the MCP1630 reference voltage and the oscillator signal at 500 kHz 1.4 TECHNICAL SPECIFICATIONS • • • • • Input Voltage: +9V to 16V Maximum Output Voltage: 50V (limited to 40V by application software) Typical Output Current: 700 mA Maximum Output Current: 1A Maximum Output Power: 30W Figure 1-1 shows a simplified block diagram of the application Bias Supply 9 - 16 VDC MCP1702 +5 MCP1630V +5 Vdd 7 2 +5 EA + PIC12F683 1 VDD Vss 8 2 GP5 GP0 7 3 GP4 GP1 6 4 GP3 GP2/ CCP1 5 8 Vref Ramp Generator 3 Clock 1 CS + 4 Osc Comp Output Driver 6 Vss 5 LED String Reference Circuit Output Voltage Feedback FIGURE 1-1: DS51665B-page 6 MCP1630 Boost Mode LED Driver Demo Board Simplified Block Diagram. © 2007 Microchip Technology Inc. MCP1630 BOOST MODE LED DRIVER DEMO BOARD USER’S GUIDE Chapter 2. Installation and Operation 2.1 GETTING STARTED The MCP1630 Boost Mode LED Driver Demo Board is fully assembled and tested. The board requires the use of an external input voltage source (+9V to 16V) and an external LED load (provided). 2.2 WHAT THE MCP1630 BOOST MODE LED DRIVER DEMO BOARD KIT INCLUDES The MCP1630 Boost Mode LED Driver Demo Board Kit includes: • MCP1630 Boost Mode LED Driver Demo Board (102-00152) • A PCB containing a string of LEDs • Analog and Interface Products Demonstration Boards CD-ROM (DS21912): - MCP1630 Boost Mode LED Driver Demo Board User’s Guide (DS51665) 2.2.1 Additional Components Required for Operation 1. A DC Power Supply. A 2.5 mm plug with positive polarity on the center pin is required to connect the power supply to J1. A bench supply that can produce 12V, 2.5A is recommended to operate the board at the full rated power. A 9V, 750 mA power supply can be purchased through Microchip Inc., part # AC162039, if needed. This power supply will drive the supplied string of LEDs at 350 mA only (5W output). 2. Oscilloscope and/or multi-meter to observe waveforms and measure electrical parameters (optional). © 2007 Microchip Technology Inc. DS51665B-page 7 MCP1630 Boost Mode LED Driver Demo Board User’s Guide 2.3 SETUP PROCEDURES To operate the demonstration board, you need to complete the following steps: 1. Configure the board for the desired current output level. 2. Attach a LED load to the output terminals. 3. Connect a power supply to the input. Detailed instructions are provided below for each step. 2.3.1 Demo Board Output Current Configuration 1. Remove jumper J4 for an output current of 350 mA. Install jumper J4 for an output current of 700 mA. 2.3.2 Connecting the Load A string of five LEDs mounted on a metal PCB has been provided for use with the demo board. (See Figure 2-1). When driven at 350 mA, the total power delivered to the five LEDs will be approximately 5 W. At 700 mA drive, the load power will be approximately 10W. Care must be taken not to operate the LEDs beyond the maximum junction temperature specified in the data sheet. It is recommended that you mount the metal PCB to a heat-sink to allow continuous operation. A heat-sink can be constructed using a length of 1-inch square aluminum square tubing. The aluminum square tubing is available at most hardware stores. The LED PCB can be mounted to the aluminum tubing using machine screws or self-tapping sheet metal screws. Note: Do not operate the LEDs for an extended period of time without mounting the PCB to a suitable heat-sink. Operation beyond the maximum junction temperature could cause early failure of the LEDs. 1. Connect the LED PCB to the demo board output terminals (TP1 and TP2) using test clips (provided). The anode of the LEDs is indicated on the PCB with a '+' marking and should be connected to the TP1 terminal on the demo board. The cathode of the LEDs should be connected to the TP2 output terminal on the demo board. Note: Do not connect the TP2 output terminal on the demo board or the cathode of the LEDs to circuit ground. The TP2 terminal is connected to a current sensing resistor and is not at ground potential during normal operation. Damage to the circuit will occur if the TP2 terminal is connected to ground. Connect to TP1 Connector wire with 'alligator' clip Connect to TP2 D1 + FIGURE 2-1: DS51665B-page 8 D2 + D3 + D4 + D5 + LED Load Board. © 2007 Microchip Technology Inc. Installation and Operation 2.3.3 Powering the MCP1630 Boost Mode LED Driver Demo Board 1. Connect a power supply to J1 to power up the MCP1630 Boost Mode LED Driver Demo Board. Ensure that the power supply has a 2.5 mm barrel connector with the center pin positive. The input voltage source should be limited to the 9V to +16V range. Ensure that the chosen power supply can provide enough current at the selected voltage to properly power the LEDs. Note: The LEDs will be very bright during operation and provide a focused light source! Avoid looking directly into the LEDs when power is applied to the circuit. It is recommended that you cover the string of LEDs with a sheet of paper or some other opaque material during testing to avoid discomfort. An external potentiometer can be connected to the MCU to provide LED dimming control. The 'Dimming Control' section of this document provides more information. 2.3.4 Verifying the Application The best way to evaluate the MCP1630 is to dig into the circuit and measure voltages and currents with a multi-meter and probe the board with an oscilloscope. You can use the following procedure to verify the LED input power: 1. To measure the output voltage (VLED), connect the multi-meter across TP1 and TP2. 2. The load current (ILED) passes through the LED load as well as current sense resistor, R14. To measure the output current, connect the multi-meter across TP2 and TP3 to determine the voltage drop across R14. The current through resistor R14 and the load is VR14 / R14. 3. The output power can be calculated as PLED = ILED * VLED. 2.4 CIRCUIT DESCRIPTION Appendix A shows the circuit schematic for the MCP1630 Boost Mode LED Driver Demo Board. The input voltage to the circuit may vary from +9 V to +16 V. The MCP1702 voltage regulator U1 generates a regulated 5 V output for the MCP1630 and the PIC12F683 devices. A 12V Zener diode, D1, is used to limit the maximum input voltage to the MCP1702 device. The MCP1630 PWM controller (U3) is comprised of a high-speed comparator, high bandwidth amplifier and set/reset flip flop, and high current driver pin. It has the necessary components to develop an analog switch-mode power supply control loop. The MCP1630 is designed to operate from an external clock source. The clock frequency sets the power supply switching frequency and the clock duty cycle sets the maximum duty cycle for the supply. The PIC12F683 MCU (U2) operates from its own 8 MHz internal oscillator and has an on chip Capture/Compare/PWM (CCP) peripheral module. When operating in PWM mode, the CCP module can generate a pulse-width modulated signal with variable frequency and duty cycles. The CCP output of the MCU is connected to the oscillator input of the MCP1630 device. For this application, the CCP module is configured to provide a 500 kHz clock source with 20% duty cycle. The 20% duty cycle produced by the CCP module limits the maximum duty cycle of the MCP1630 to 80%. Once configured, the CCP peripheral does not need any control by the MCU software. If desired, the CCP can be reconfigured to obtain different clock frequencies up to the 2 MHz maximum specification for the MCP1630. © 2007 Microchip Technology Inc. DS51665B-page 9 MCP1630 Boost Mode LED Driver Demo Board User’s Guide The CCP output is also connected to a simple ramp generator that is reset at the beginning of each MCP1630 clock cycle. The ramp generator is composed of transistor Q2, resistors R2, R3 and capacitor C6. It provides the reference signal to the MCP1630 comparator. The MCP1630 comparator compares this ramp reference signal to the error amplifier output to generate a PWM signal. A resistor voltage divider (R4, R5 and R6) and filter is used to set the reference voltage for the constant current control and is driven by the GP5 pin of the MCU. Jumper J4 is used to select two different reference voltages to drive the LED load at different current levels. With J4 removed, resistors R4 and R5 provide a 206 mV reference voltage. This setting provides 350 mA output current. With J4 installed, resistors R4, R5 and R6 provide a 412 mV reference voltage. (700 mA output) R8 and C7 form an integrator circuit in the negative feedback path, providing high loop gain at DC. This simple compensation network is sufficient for a constant current LED driver. Places have been provided on the PCB for additional compensation components, if required. R12 and R13 form a voltage divider that is used to monitor the output voltage of the boost circuit. The output of the voltage divider is connected to pin GP4 of the MCU and monitored with the ADC. L1, Q1, D2, C12, and C13 form the basic voltage boost circuit. C13 is not populated on the PCB. The value of C12 has been selected to keep the LED current ripple less than 20% at the rated load conditions. 2.5 FIRMWARE DESCRIPTION Appendix C shows the firmware flowchart. Different parts of the firmware operation are described below. 2.5.1 Clock Generation At a minimum, the PIC12F683 code must initialize the CCP module in PWM mode to produce a clock signal for the MCP1630. The CCP is configured to produce 500 kHz with a 20% duty cycle. The clock duty cycle limits the maximum on time of the power MOSFET to 80% duty. I/O pins GP5 is driven high to enable the voltage reference for the MCP1630 control loop. After these tasks are completed, the MCP1630 can begin the current regulation function and the MCU can execute other tasks. 2.5.2 Open Circuit Detection One potential problem that can occur with a constant current application is an open-circuit load condition. In this case, the power supply will try to raise the output voltage to provide the required current. A boost converter circuit can continue to raise the output voltage until component damage occurs. The software monitors the output voltage to the MCP1630 using an ADC channel and disables the power supply when a maximum output voltage of 40V is reached. Once the output reference voltage reaches the allowable maximum limit, the GP2 pin is driven high by writing a 100% duty cycle value to the CCP control registers. This high signal effectively resets the MCP1630. The reference to the MCP1630 is also disabled by clearing pin GP5. After the over-voltage event, the software provides a delay before restarting the input clock to the MCP1630 PWM generator and turning on the reference voltage. The delay reduces stress on the power supply components. DS51665B-page 10 © 2007 Microchip Technology Inc. Installation and Operation 2.5.3 Dimming Control An external potentiometer can optionally be attached to the PCB to provide LED dimming control. When a potentiometer is present, the demonstration software will sample the voltage and modulate pin GP5 (MCP1630 reference) with a low-frequency PWM signal. The PWM signal is generated in software using Timer0 as a timing reference. The software PWM signal provides 63 LED brightness levels. If a potentiometer is not present, pin GP5 is maintained at 100% duty to provide full LED brightness. If potentiometer dimming is desired, connect a 10 kohm potentiometer to the ICSP programming header, J3. The resistive element of the potentiometer is connected between pins 2 and 3 of J3 (Vdd and ground). The potentiometer wiper is connected to pin 5 of J3 (GP1 pin). Note: Set the potentiometer to provide 0 output voltage when power is first applied to the demo board. This will allow the potentiometer to be properly detected as explained below. The demonstration software detects whether a potentiometer has been attached to the PCB using the weak pull-up (WPU) feature on pin GP1. At startup, the software enables pin GP1 as a digital input with the WPU turned on. If no potentiometer is present, the pin will float high due to the WPU and a logical '1' will be detected. If a potentiometer is connected and the wiper is turned to the minimum setting, a logical '0' will be detected on the I/O pin. If the potentiometer is detected, the ADC result is allowed to set the dimming duty cycle. 2.5.4 Modifications The hardware and software on this demonstration board can be modified to solve a wide variety of application problems. A few modifications that you might desire to support your application are described below. 1. The reference voltage divider network comprising R4, R5, and R6 can be modified to provide current output levels other than 350 mA and 700 mA. The reference voltage supplied to the MCP1630 should be 560 mV or less to keep the output current from exceeding 1A. 2. Some applications are sensitive to electromagnetic interference (EMI). One way to reduce the impact of radiated EMI is to spread the noise across a portion of the frequency spectrum. This is easy to do with the PIC12F683 by writing a value to a tuning register that affects the frequency of the internal 8 MHz oscillator. If you need this feature, uncomment the first four lines of code after the MainLoop label in the code. This code reads a value from the free-running Timer0 and uses it as a pseudo-random tuning value for the oscillator. 3. The switching frequency is set to 500 kHz to keep the size of inductor L1 small. The clock frequency is set by the PR2 register, which is the timebase period register for the PIC12F683 CCP module. Other switching frequencies can be used by writing a different value to PR2. The CCPR1L and CCP1CON registers also need to be modified to adjust the duty cycle of the clock signal. Refer to the PIC12F683 data sheet (DS41211) for more information. 4. A temperature sensor can also be used for thermal management of the LEDs. Microchip Technology, Inc. provides a range of analog and digital output temperature sensors for different application needs. The ICSP programming header (J3) on the PCB provides a convenient method to access 5V, ground, and two I/O pins. These pins could be used to interface a temperature sensor to the PIC12F683, if desired. © 2007 Microchip Technology Inc. DS51665B-page 11 MCP1630 Boost Mode LED Driver Demo Board User’s Guide 2.5.5 Programming Header J3 is provided for in-circuit programming. The MCP1630 Boost Mode LED Driver Demo Board comes pre-programmed with firmware to operate the system. The PIC12F683 can be reprogrammed with the PICkit 2 Debug Express (Microchip P/N: DV164121), which is a low-cost Flash microcontroller programmer and a debugger. DS51665B-page 12 © 2007 Microchip Technology Inc. MCP1630 BOOST MODE LED DRIVER DEMO BOARD USER’S GUIDE Appendix A. Schematic and Layouts A.1 INTRODUCTION This appendix contains the following schematics and layouts for the MCP1630 Boost Mode LED Driver Demo Board: • • • • Board – Schematic Board – Top Layer Board – Top Silk Layer Board – Bottom Layer © 2007 Microchip Technology Inc. DS51665B-page 13 MCP1630 Boost Mode LED Driver Demo Board User’s Guide BOARD - SCHEMATIC 1 3 2 M A.2 DS51665B-page 14 © 2007 Microchip Technology Inc. Schematic and Layouts A.3 BOARD - TOP LAYER © 2007 Microchip Technology Inc. DS51665B-page 15 MCP1630 Boost Mode LED Driver Demo Board User’s Guide A.4 BOARD - TOP SILK LAYER DS51665B-page 16 © 2007 Microchip Technology Inc. Schematic and Layouts A.5 BOARD - BOTTOM LAYER © 2007 Microchip Technology Inc. DS51665B-page 17 MCP1630 Boost Mode LED Driver Demo Board User’s Guide NOTES: DS51665B-page 18 © 2007 Microchip Technology Inc. MCP1630 BOOST MODE LED DRIVER DEMO BOARD USER’S GUIDE Appendix B. Bill Of Materials (BOM) TABLE B-1: Qty BILL OF MATERIALS (BOM) Reference Description Manufacturer Rohm Part Number 1 C1 CAP TANT 4.7UF 16V 20% SMD 1206 5 C2, C3, C5, C10, C11 CAP CERM .10UF 50V 20% 0805 SMD AVX Corporation TCA1C475M8R 1 C4 CAP 4700PF 50V CERM CHIP 0805 Panasonic® - ECG 1 C6 CAP 1500PF 50V CERM CHIP 0805 Panasonic - ECG ECJ-2VB1H152K 1 C7 CAP 220PF 50V CERM CHIP 0805 SMD Panasonic - ECG ECJ-2VC1H221J 3 C8, C9, C12 DO NOT POPULATE — — 1 C13 CAP 4.7UF 50V CERAMIC F 1210 Panasonic - ECG ECJ-4YF1H475Z 2 C14,C15 CAP 4.7UF 25V CERAMIC X5R 1206 Panasonic - ECG ECJ-3YB1E475M 1 D1 DIODE ZENER 500MW 12V SOD123 ON Semiconductor® MMSZ5242BT1G 1 D2 DIODE SCHOTTKY 60V 1.5A SMA International Rectifier 10MQ060NTRPBF 1 J1 CONN POWER JACK 2.5MM PCB CIRC CUI Inc PJ-102B 1 J3 CONN HEADER RTANG 6POS .156 TIN Tyco Electronics/Amp 640385-6 1 J4 CONN HEADER 2POS .100 VERT TIN Molex®/Waldom® Electronics Corp 22-28-4020 1 J4 SHUNT CONN JUMPER SHORTING GOLD FLASH Sullins Electronics Corp. SPC02SYAN 1 L1 DO5010H-153MLD (MLD - Full Reel 250 MLB partial) Coilcraft DO5010H-153MLD 1 LED Strip Cree® XLamp® XR-E LED ETG, Corp CR5UP-XRE 1* LED Strip 1 Set of Alligator Test Clips per board. — — 08055C104MAT2A ECJ-2VB1H472K * These come in sets of ten, Ea. Will be cut in half resulting in two pieces. ( 20 pieces per set of ten ) 1 PCB RoHS Compliant Bare PCB, MCP1630 Boost Mode LED Driver Demo Board — 104-00152 1 Q1 MOSFET Transistor Polarity:N Channel Power Dissipation:2.1W Drain-Source Breakdown Voltage:55V International Rectifier IRLL024NPBF 1 Q2 TRANS NPN SW 600MA 40V SOT23 NXP Semiconductors PMBT4401 T/R 1 R1 RES 200 OHM 1/4W 5% 1206 SMD Rohm MCR18EZHJ201 1 R2 RES 470 OHM 1/8W 5% 0805 SMD Rohm MCR10EZPJ471 1 R3 RES 2.0K OHM 1/8W 5% 0805 SMD Rohm MCR10EZPJ202 2 R4, R6 RES 10K OHM 1/8W 5% 0805 SMD Rohm MCR10EZPJ103 1 R5 RES 430 OHM 1/8W 5% 0805 SMD Rohm MCR10EZPJ431 1 R8 RES 160K OHM 1/8W 5% 0805 SMD Rohm MCR10EZPJ164 Note 1: The components listed in this Bill of Materials are representative of the PCB assembly. The released BOM used in manufacturing uses all RoHS-compliant components. © 2007 Microchip Technology Inc. DS51665B-page 19 Bill Of Materials (BOM) TABLE B-1: Qty BILL OF MATERIALS (BOM) (CONTINUED) Reference Description Manufacturer Part Number 3 R9, R10, R15 DO NOT POPULATE — — 1 R11 RES 0.0 OHM 1/8W 5% 0805 SMD Rohm MCR10EZPJ000 1 R12 RES 8.2K OHM 1/8W 5% 0805 SMD Rohm MCR10EZPJ822 1 R13 RES 1.0K OHM 1/8W 5% 0805 SMD Rohm MCR10EZPJ102 1 R14 RESISTOR .56 OHM 1/2W 5% 2010 Panasonic - ECG ERJ-12ZQJR56U 1 TP-1 Test Point PC,multi-puporse Red Keystone Electronics® 5010 1 TP-2 Test Point PC,multi-puporse White Keystone Electronics 5012 1 TP-3 Test Point PC,multi-puporse Black Keystone Electronics 5011 1 U1 5V Regulator, SOT-23A Microchip Technology Inc. MCP1702T-5002E/CB 1 U2 MCU, 8-SOIC Microchip Technology Inc. PIC12F683-E/SN 1 U3 PWM Peripheral, 8-MSOP Microchip Technology Inc. MCP1630V-E/MS Note 1: The components listed in this Bill of Materials are representative of the PCB assembly. The released BOM used in manufacturing uses all RoHS-compliant components. © 2007 Microchip Technology Inc. DS51665B-page 20 MCP1630 BOOST MODE LED DRIVER DEMO BOARD USER’S GUIDE Appendix C. Firmware Flowchart Start Initialize: GP2 (for Output PWM) And GP5 (for Output VREF Internal Osc Clock to 8 MHz, TMR0 = 0 Configure Ansel & CMCON0 as Digital I/O Set Weak Pull-Up on GP1 Setup CCP module and 20% duty cycle (Clock for MCP1630) Output VREF Signal through GP5 (Reference Voltage for MCP1630 ) Is GP1 = 1? YES NO 1. Clear Weak Pull-Up on GP1 2. Set a Flag for Potentiometer Detected 3. Set GP1 for Analog Input Clear the Potentiometer flag Start ADC ADC Channel1 or Channel3 CH3 CH1 B A Set ADC for CH3 Is Potentiometer Flag set? NO YES Set DimDuty for the potentiometer output value FIGURE C-1: Set DimDuty for maximum duty cycle Firmware Flowchart - Page 1. © 2007 Microchip Technology Inc. DS51665B-page 21 MCP1630 Boost Mode LED Driver Demo Board User’s Guide A Set ADC for CH1 Is Overvoltage Flag set already? YES NO Check ADC for Overvoltage Is Delay expired? NO YES B NO Overvoltage? 1. Restart clock to MCP1630 2. Restart reference voltage to MCP1630 YES 1. Stop clock to MCP1630 2. Stop reference voltage to MCP1630 3. Initialize Delay for 25 mSec FIGURE C-2: DS51665B-page 22 Firmware Flowchart - Page 2. © 2007 Microchip Technology Inc. Firmware Flowchart NOTES: © 2007 Microchip Technology Inc. DS51665B-page 23 WORLDWIDE SALES AND SERVICE AMERICAS ASIA/PACIFIC ASIA/PACIFIC EUROPE Corporate Office 2355 West Chandler Blvd. Chandler, AZ 85224-6199 Tel: 480-792-7200 Fax: 480-792-7277 Technical Support: http://support.microchip.com Web Address: www.microchip.com Asia Pacific Office Suites 3707-14, 37th Floor Tower 6, The Gateway Habour City, Kowloon Hong Kong Tel: 852-2401-1200 Fax: 852-2401-3431 India - Bangalore Tel: 91-80-4182-8400 Fax: 91-80-4182-8422 India - New Delhi Tel: 91-11-4160-8631 Fax: 91-11-4160-8632 Austria - Wels Tel: 43-7242-2244-39 Fax: 43-7242-2244-393 Denmark - Copenhagen Tel: 45-4450-2828 Fax: 45-4485-2829 India - Pune Tel: 91-20-2566-1512 Fax: 91-20-2566-1513 France - Paris Tel: 33-1-69-53-63-20 Fax: 33-1-69-30-90-79 Japan - Yokohama Tel: 81-45-471- 6166 Fax: 81-45-471-6122 Germany - Munich Tel: 49-89-627-144-0 Fax: 49-89-627-144-44 Atlanta Duluth, GA Tel: 678-957-9614 Fax: 678-957-1455 Boston Westborough, MA Tel: 774-760-0087 Fax: 774-760-0088 Chicago Itasca, IL Tel: 630-285-0071 Fax: 630-285-0075 Dallas Addison, TX Tel: 972-818-7423 Fax: 972-818-2924 Detroit Farmington Hills, MI Tel: 248-538-2250 Fax: 248-538-2260 Kokomo Kokomo, IN Tel: 765-864-8360 Fax: 765-864-8387 Los Angeles Mission Viejo, CA Tel: 949-462-9523 Fax: 949-462-9608 Santa Clara Santa Clara, CA Tel: 408-961-6444 Fax: 408-961-6445 Toronto Mississauga, Ontario, Canada Tel: 905-673-0699 Fax: 905-673-6509 Australia - Sydney Tel: 61-2-9868-6733 Fax: 61-2-9868-6755 China - Beijing Tel: 86-10-8528-2100 Fax: 86-10-8528-2104 China - Chengdu Tel: 86-28-8665-5511 Fax: 86-28-8665-7889 Korea - Gumi Tel: 82-54-473-4301 Fax: 82-54-473-4302 China - Fuzhou Tel: 86-591-8750-3506 Fax: 86-591-8750-3521 Korea - Seoul Tel: 82-2-554-7200 Fax: 82-2-558-5932 or 82-2-558-5934 China - Hong Kong SAR Tel: 852-2401-1200 Fax: 852-2401-3431 Malaysia - Penang Tel: 60-4-646-8870 Fax: 60-4-646-5086 China - Qingdao Tel: 86-532-8502-7355 Fax: 86-532-8502-7205 Philippines - Manila Tel: 63-2-634-9065 Fax: 63-2-634-9069 China - Shanghai Tel: 86-21-5407-5533 Fax: 86-21-5407-5066 Singapore Tel: 65-6334-8870 Fax: 65-6334-8850 China - Shenyang Tel: 86-24-2334-2829 Fax: 86-24-2334-2393 Taiwan - Hsin Chu Tel: 886-3-572-9526 Fax: 886-3-572-6459 China - Shenzhen Tel: 86-755-8203-2660 Fax: 86-755-8203-1760 Taiwan - Kaohsiung Tel: 886-7-536-4818 Fax: 886-7-536-4803 China - Shunde Tel: 86-757-2839-5507 Fax: 86-757-2839-5571 Taiwan - Taipei Tel: 886-2-2500-6610 Fax: 886-2-2508-0102 China - Wuhan Tel: 86-27-5980-5300 Fax: 86-27-5980-5118 Thailand - Bangkok Tel: 66-2-694-1351 Fax: 66-2-694-1350 Italy - Milan Tel: 39-0331-742611 Fax: 39-0331-466781 Netherlands - Drunen Tel: 31-416-690399 Fax: 31-416-690340 Spain - Madrid Tel: 34-91-708-08-90 Fax: 34-91-708-08-91 UK - Wokingham Tel: 44-118-921-5869 Fax: 44-118-921-5820 China - Xian Tel: 86-29-8833-7250 Fax: 86-29-8833-7256 12/08/06 DS51665A-page 24 © 2007 Microchip Technology Inc.