Introduction: Switcher
The task is to design and build a switch mode power supply (SMPS) which will operate in boost and buck mode. The controller will contain a selection of menu options allowing the user to control as many features as possible of the SMPS operation. The software running on the controlling processor must consist of no more than 1024 bytes of machine code.
The attached images are the steady output of the SMPS under load with a varying input voltage.
Step 1: Schematic
The chosen processor is a Silicon Labs C8051F850-C-GU which uses the 8051 architecture. An 8051 processor is a good choice for a code size reduction exercise as there are many thoroughly tested compilers available. The Keil c51 compiler will be used to generate assembly for this project.
A soldering iron and solder is required to build the switcher hardware. The schematic is held
in Figure 1 along with the BoM in Table 1. Photos of the top and bottom of the strip board build are contained in Figures 2 and 3. Note the visible modification to the development board is not required to replicated the design however R5, R6 and R9 must be removed from the board development board.
Step 2: BoM
The bill of materials is contained in the attached image. The components are inexpensive and readily available from most electronic component stockists.
Step 3: Construction
The attached image can be used as a construction manual for building the strip board. The headers on the development board will need to modified and attached to strip board.
Step 4: Code
All code is available https://github.com/ashleyjr/Switcher
The c51 development tools are available form Keil http://www.keil.com/c51/devproc.asp
The attached images contain the a UART menu for controlling the power supply. A block diagram explains how the software operates.
Step 5: Code Size
As described in the initial images the power supply works an is ideal for working varying voltages to gain a steady output voltage; such a battery.
An additional challenge imposed on the project is to reduce the size of the code used to control the power supply. The attached image shows how the code size has changed against the number of commits.
A PDF version of the project is available here http://www.ajrobinson.org/switcher/switcher.pdf