command interface for remote control
[digitaldcpower] / README.htm
1 <h2>Tuxgraphics Digital DC Power Supply Unit</h2>
2 <pre>
3
4 Compile the software and program the microcontroller:
5
6 1) edit and adapt the file hardware_settings.h 
7    (calibration and selection of the right hardware type).
8
9 2) load and compile:
10 make 
11 make load
12
13 3) set the fuse bytes to 8MHz internal:
14 make fuse
15
16 This should result in the following settings:
17
18 avrdude: Device signature = 0x1e9307
19 avrdude: safemode: lfuse reads as E4
20 avrdude: safemode: hfuse reads as D9
21
22
23 The make fuse needs to be done only once
24 unless you change the Atmega8 chip. make/make load
25 need to be repeated everytime you change something
26 in the software (e.g update of hardware_settings.h). 
27
28 The poweresupply must be powered up during programming
29 but nothing should be connected to the output. Make
30 sure that you do not accidently press any button
31 during the programming (loading the software into the uC).
32
33 Compile under windows
34 =====================
35 Please use the provided Makefile.
36
37 There are as well 3 batch files which you can use
38 to run the makefile. To use them edit them and change
39 the path as per your avr-gcc installation on your PC.
40 After that run them by double-clickin in the file manager
41 on those batch files.
42
43  winmake.bat  -- comile, this is mandatory to use
44
45  winload.bat  -- load software using avrdude, may also use
46                  some other means of loading the softare. In that
47                  case you do not need to use this batch file.
48
49  winsetfuse.bat -- set fuse bytes using avrdude, may also use
50                    some other means of loading the softare. In that
51                    case you do not need to use this batch file.
52
53 Calibration
54 ===========
55 To calibrate the display edit the file hardware_settings.h
56 Here you can change also the settings between the 30V and the 22V version.
57
58 In general you should only need to change 
59 U_DIVIDER and I_RESISTOR by very small amounts. 
60
61
62 Overview
63 ========
64 This is the software for the tuxgraphics.org electronic digital DC power supply. 
65 A microncontroller controlled bench DC power supply unit. 
66
67 All of the control logic is implemented in software. This
68 saves a lot of parts compared to conventional lab-power 
69 supplies. This means it is cheaper, easier to build and
70 offers more functionallity.
71
72 Note however that this means also that the short circuit
73 protection is implemented in software. So be careful when
74 you change something in the software. If the microcontroller 
75 is not running properly due to a software fault then there
76 might not be any short circuit protection.
77
78
79 The software is prepared for 2 versions:
80 - 0-22V 0-2.5A
81 - 0-30V 0-2A
82
83 If you want to build a version that has a smaller output
84 range than any of the two version then you can just
85 modify the file hardware_settings.h.
86
87 The unit can be controlled remotely from a computer using
88 a USB serial interface. An add-on card is available from
89 http://shop.tuxgraphics.org which offers galvanic separation
90 such that you can use this power supply relative to
91 any reference point (e.g build two power supply and use
92 one as negative and one as positive power supply).
93
94 Terminal settings for remote control via your computer
95 ======================================================
96 You can e.g use putty under windows
97 http://www.chiark.greenend.org.uk/~sgtatham/putty/ 
98 it supports as well serial connections
99 For Linux I can recommend picocom
100 http://code.google.com/p/picocom/
101 (use command picocom -l -b 9600 /dev/ttyUSB0)
102
103 port       : Virtual com port (e.g /dev/ttyUSB1 or /dev/ttyUSB0
104              or COM5 under windows or ... to whatever port the
105              virtual com port maps)
106 flowcontrol: none
107 baudrate   : 9600
108 parity     : none
109 databits   : 8
110
111 </pre>
112 <br>
113 <img src=screenshot-cmd-interface.gif>
114 <br>
115 <pre>
116 -------------------------------------------------------------------
117 Copyright: GPL V2
118 Author: Guido Socher
119 Homepage: http://www.tuxgraphics.org/electronics/
120 -------------------------------------------------------------------
121 Change history:
122 digitaldcpower-0.6.0 -- 2010-05-22 first version of the new power V3.
123                         This version is made for a new type of hardware
124                         and will not run on any previous hardware version.
125
126 digitaldcpower-0.6.1 -- 2010-06-06 Number conversion to display string
127                         improved.
128                      -- Basic uart interface prompt, no remote control yet
129
130 digitaldcpower-0.6.2 -- 2010-06-26 Full UART command interface
131                         
132 -------------------------------------------------------------------
133 </pre>