I did not add much capacitors on any of the boards simply because they take to much space + I wanted a separate capacitor board to be able to scale up/Down and be more flexible about mounting them due to their size.. I found some very nice sized 10,000uF/50V that I am using that have a decent size to them. We need to add one of these on the out step (before the out relay) to make the PSU capable of dealing with nasty behaviour from test equipment. I also wonder if I might need some caps between the relay board and the regulator to smooth input voltage changes – will see.
The TVS diode should clamp down on ca 45V to protect the 50V capacitors in case we deal with spikes caused by 360W of fun.
What I will do next is to review the full PSU and adjust for assembling of the entire PSU. That include looking into a project box and HMI solution.
to be continued …
In part 1 I created an analogue linear regulator that can be used stand-alone as is. But, the drawback with a linear regulator is that it regulate by splitting voltage out between the load and the transistors. This means that if you short-cut the load you have 36V * 10A = 360W heating up the transistors. That is a lot of heat to dissipate and this is the main drawback with linear regulator techniques.
To improve on this I want to use 3 x 12V DC-DC and a few relay’s to connect in 12V, 24V or 36V as it is needed. Adding a MCU I can autosense the output voltage and if voltage out is 10V I switch in 24V etc. This means that my maximum voltage drop is 14V giving 140W to dissipate. It is much better.
I also need a separate 5V for the MCU, Display etc, so I grab a smaller 2A DC-DC for this and add a classic 7805. By doing this I also isolate MVU power from the Lab PSU which is good. The MCU I chose is my own STM32F030 breakout board. This leaves us the option to replace this with an Arduino or whatever we want to use later – freedom of choice.
This is an early 3D model of the Relay/MCU Board- again I use hole through Technology only. The DIP14 Circuit is ULN2003. I decided to use this because the relays need ca 6V-14 to hold + having the ULN2003 between the coils and MCU adds protection.
To improve our heat dissipation further we implement temperature sensors and fan’s. I have available 12V/600mA ports and ADC’s anyway so implementing 3 of these are easy. I will add schematics and BOM lists later.
to be continued…
I desperately need more lab PSU’s and I have a bunch of LM723 and TIP3055 transistors that are excellent for creating an old-fashioned Linear PSU module. Thinking a bit ahead I want to create the analogue regulator as a small, separate module with knobs on the front, heat-sink & transistors on the back and connectors on the side.
The 3D model above is an early draft on 70 x 75mm. I am using hole througt Components on this one to enable hobbyists to grab a PCB and solder them up themselves to save cost. Adding a Voltage/Ampere meter is easy because I just use a module like this one (or similar):
They cost less than 5.- USD and they work well. I add no other led’s or display, but I add two power switches – one for input and one separate for output.
I am also using 2 x TIP3055 that technically enable 30A together, but PCB lanes and current limit is scaled for max 10A. The following block diagram show the complete PSU.
The mains are basically a 36V/10A DC-DC regulator. These comes at a decent cost with CE/FCC approval that is needed for 48V and higher. What is remaining is to find a project box and we have a nice Lab PSU.
to be continued…
This drawing illustrate a water detector. A water detector is basically a standard ADC reading between two resistors where the 2nd resistor is a PCB as illustrated above. As the water raises the PCB will start leading current and the ADC reading will move from 3.3V to GND. This is the same principle as used for temperature- and light detection resistors- except that the resister is a PCB in this case. We we can apply the sensor with a cable some meters from the actual sensor Logic as we don’t want electronics flooded.
A water detector is something you don’t believe you will need, but if you ever have a water leak you would like to know about it fast since water usually cause less damage if it removed instantly.
One major issue is how to identify units in a network. I used STM32F030F4 on these and I absolutely love this little MCU costing 50 cent in TSSOP20 package, but it lack the serial number that is burned into other STM32 MCU’s. This serial number is crucial as it present a factory set ID allowing me to just plug in sensors expecting them to identify themselves. STM32F042F6 solves this, but cost ca 2.- USD from the sources I use, so I am very tempted to use STM32F103C8 or CB and create a larger PCB so it becomes single sided. The later actually lower cost in production – but, lets see where we land as I update the modules.
My grandparents passed away some years ago leaving a beautifully mountain farm behind. As no-one lives up there we have to leave the farm unattended for months at the time. This is a challenge in winter time as we fear the water pipes with freeze. The farm actually got internet installed so it is possible to use internet to create a remote controlled automation system.
Using Internet for anything you need to address security. Using Windows these days is not an option, so I am happy for Raspberry PI as base units. I am no web service expert, but I believe I can communicate directly between my home and the mountain farm by using a Address Lookup Service that we need to create. Basically the HMI and PLC both connect to internet and get details of whom to communicate with through a public service. Once the address is known they create a secure tunnel for communication. I will deal with security later, for now lets just assume this works and that we can use mobile devices as HMI.
The system I want to create will consist of a range of modules:
- Redundant PLC Base with mains, battery, wired and mobile internet connection as well as connection to sensors and actuators.
- Sensors for temperature, humidity, water leaks, light, movement etc.
- Camera, speakers and microphones. Actuators swithing on/off heat, opening/locking doors etc.
I use the mountain farm as design base because it present a few challenges. And I obviously want to control this using Plain.
I just uploaded a design doc for the Universal Motor Controller on the downloads page. I used LibreOffice 5.3 since it could export to PDF, but believe me this is the last time I use that. I had so many problems importing drawings that I ended up importing everything to Word and then copy & paste as bitmap from Word to LibreOffice. LibreOffice doc’s and illustrations is not a good combination. I like LibreOffice, but I like Things that work more!
This is the front and back 3D model of the Rev 1.0 of my Universal Motor Controller. I will be leaving the non-isolated RS485 for now. I want to do some changes around the MCU layout later anyway as I actually have a lot of spare pins here, but lack space to support a com adapter. This board is 80 x 40mm and only 2-layer PCB with a lot of functionality.
Design doc is located on the Download page!
The HEXFET on my Universal Motor Controller is 30V, so I decided to change my existing DC-DC to 12V out and add a classing LM1117 for the 3.3V. The LMR14206 based DC-DC is basically so small that it is not much larger than LM1117 on PCB space. It is restricted to ca 800mA, but it will only drive the gate drivers, MCU and com etc so it should be sufficient.
I did find a few DC-DC converters with a different range on Voltage/Ampere, but they also use more PCB space. Jumper J5 and J11 allow 12V to be connected directly if your using 11.1V battery etc. The issue is that the Gate drivers need 10+ V to operate and as the DC-DC will drop 1-2V we might get a challenge using 11.1V LIPO batteries so I added the jumpers in case they are needed.
I would have loved to operate from 5V and up, but to do that I would need a very powerfully step-up DC-DC converter as we would feed the motors as well. It is doable, but it add to the size. We will be looking at optimizations later anyway.
This 2nd diagram is also part of the PSU and show the adapter connector as well as the P4SMA suppression diode from Vishay. This will break down around 27ich V and suppress any unwanted pulses. These diodes are life savers, but they take some time to react which is why you must add an adapter board with either a capacitor or battery. What will happen is that capacitors will take the edge of the pulse giving the suppression diode time to suppress the pulse. If you have a large capacitor or battery that will need tom be “filled up”, meaning that the diode will only react if the battery or capacitor is overrun.
If you recall my previous breakdown and discussion I concluded that a 24V motor can spike up into 20x (480V). The HEXFET’s will basically short those spikes and might be feeding them into the PSU part. A capacitor/battery can charge that energy, but we have a suppression diodes around to prevent that these spikes do damage. The basic adapter Board is only a specialzed vero Board to allow mounting of hole-through capacitors.
I designed this universal motor controller capable on driving DC-, Stepper-, BLDC- and even AC – motors earlier. The design parameters was 12-24V at 15A. This is quite a capable controller, but I did a mistake that limit the controller to 12-20V since I connected the Gate Drivers to the Motor PSU directly. To compensate for this I need to modify the design and implement a separate 12V PSU. As I correct this I also want to consider some additional changes.
I am considering is to replace the RS485 with an isolated RS485 due to the amount of energy involved. The 3rd change is Ethernet on a separate adapter board. Basically I want to copy the modules I use on the Universal Adapter as soon as I have tested them.
I am not sure about Ethernet. Ethernet sound nice due to the functionality, but it is a clumsy, 4-wire 1:1 solution. RS485 is slower, but it is a 2-wire network. It actually makes more sense having dual RS485 to be honest. CAN & Ethernet is easier to deal with using an adapter board- RS485 is considered a lower level of communication than CAN because CAN have protocols like CANopen, J1939 etc. The reality is that if we use RS-X that changes.
What I probably should do at some point is to create a “Ethernet” on top of RS-X by using a dual RS-X connection. But, that is fun for later…
So the modified design will be
- STM32F405RG MCU, 168Mhz, 32bit M4, 1MbFlash, 192KbSRAM
- 4 x separate half bridge drivers, 30V @15A
- Current sensors on all
- BEMF sensors
- PSU Voltage Sensor
- Separate 3.3V supercap to sustain MCU in power dips.
- 3 x hall sensors
- 2 x temperature sensors.
- 1 x resolver
- 2 x end sensors
- 1-2 x RS485
- Adapter board for battery/caps
- Adapter board for CAN/Ethernet/Wifi
- Solenoid driver
- DC Motor driver
- Stepper Motor Driver
- Brushless 3-Phase motor driver