Project 6 @ FHNW – Control and monitor household devices by LoRaWAN (IoT)

In the 6th semester of my studies @ FHNW I worked together with Josua Stierli on our Bachelor Thesis.

Abstract

The company AdNovum Informatik AG develops software, in this business they are a big global player. The swiss mobile-payment system Twint was developed by them. Now they want to step into the field of IoT devices, therefore they launched the project IoT Washer and IoT Letterbox. These devices should be observed. The user should be notified by a smartphone app about the current state of the device.

The goal of this project is to gain knowledge in the field of low-power battery IoT devices and therefore build a LoRaWAN IoT device. LoRaWAN is a long-range low-power technology developed by Semtech and standardized by the LoRa Alliance.

First a LoRa Gateway was built and the capability of the network was tested. As service provider the open-source The Things Network is used. Acceleration measurements were taken on different washers to understand the vibrations, which were emitted while the machine is running.
Later a LoRa-Node was designed as a printed circuit board and programmed in c code with the LoRaWAN library LMIC.
The node utilizes a NXP LPC54102 dualcore ARM Cortex M0+ / M4 microcontroller and a RFM95 LoRa transceiver.

The LoRa-Node successfully recognizes whenever the washer starts running. Also the end of a wash cycle is detected every time. If the LoRa radio reception is adequate every message reaches the gateway and the user is notified by a push message.

 

Server Power Supply Pinout

While dumpster diving the electronic scrap I find always interesting parts.

Last week I found some rack server with hot swap power supply. I removed the power supplies and reverse engineered the pinout of them.

On the following pictures you see the power supply and their pinout.

At the moment there are only the power and power-on pins known. The other unknown pins could be SPI or I2C for handling status information of the power supply or to regulate the cooling fan speed.

The power-on pins are often the shorter pins. They have to be shorter, because if the power supply is hot plugged, they should connect last after all other pins are already connected.

EDIT (2017-10-11): By courtesy of JP Peiffer (Belgium)
He found a way to modify the HP DPS-460EB A (see below) to output 13.5V instead of 12V.

Modification: Change 9K09 resistor (on the right of the three potentiometers) on the piggyback controller board to 10k.
Now you can adjust the output voltage with the top right potentiometer to max 13.62V. At higher voltages, the overvoltage limiter kicks in. (IC/location of the limiter must be found).

To get safe startup, set the output voltage only to 1.5V. Other wise it hangs sometimes when booting, due to overshoots.

HP DPS-460EB A 13.6V Modification
HP DPS-460EB A 13.6V Modification

Power Supply Emerson 7001540-J000
+12V 40A
+5.1V 30A
3.36V STBY 0.45A

Pinout_Emerson_7001540-J000

Power Supply HP DPS-460EB A
+12V 38.3A
12V STBY 2.5A

Pinout_HP_DPS-460_HP_DSPS-750

Power Supply HP DPS-750RB A
+12V 62.5A
+12V STBY 2.5A

Resistor Value in Picture “DC Plug Top View”: 100 Ohms

Pinout_HP_DPS-460_HP_DSPS-750

Power Supply Supermicro PWS-1K21P-1R
+12V 100A
+5V STBY 4A

Pinout_Supermicro_PWS-1K21P-1R

ATX Power Supply 18V and 30V Modification

My first attempt to build a power supply capable of 10A @ 30V for my 2x100W Class D-Amp was not successful, because I only reached 10A@ 24V. My next idea was, to modify an ATX-Computer-Power-Supply from 12V to 18V and connect a unmodified (original) ATX-Power-Supply with a modified 18V to reach 30V and 10A.

In this post is the modification from of the ATX-Powersupply to output 10A @ 18V described.

Attention: Don’t modify a Power-Supply if you aren’t trained with Low-Voltage! I don’t guarantee, that the schematic of the Power-Supply is correct! If the Power-Supply is faulty mains-voltage can reach the DC-Output! Capacitors can stay charged to 325V after disconnecting the power-supply from mains-voltage. You do all modifications at your own risk! I am not responsible for damages, fire and injuries!

Original Schematic of the “DPS-240EP” ATX-Power-Supply (read out from circuit board):ATX DPS-240EP

I did a lot of steps to the final version of the modification. The first idea was, to cheat the control-IC (DNA1002)of the power-supply. Unfortunately I didn’t found a datasheet of this IC. It seems, that it is a custom IC for the power-supply manufacturer “Delta”.  From schematic “drafts” of this IC I recognized the voltage-monitoring pins for 5, 12 and -12V. Next I connected this pins with voltage regulators fix to the needed voltages.

The voltage Regulation of the power-supply is done with a tl431 voltage reference. I replaced the on-board potentiometer with an own and could adjust the 12V rail up to 18V. Attention, before this voltage modification I replaced the old electrolyte capacitors on the 12V rail and 5V rail with 25V and 10V types.

Sadly now the power-on of the circuit didn’t worked proper no more. So I decided to go away from the control circuit DNA1002 and bridge the circuit at the required points. (As I understand the circuit, there is no over current monitoring with shunts. The DNA1002 just monitors the voltage, and in case of an overcurrent [or empty capacitor connected] the voltage drop for a short moment is recognized and the power-supply shut down.

Attention, the modification has a very high current limit: The IC UC3845 on the primary side has a 0.18 Ohm shunt, which limits the primary (325V) current to max. 1V over the shunt (1V/0.18 = 5.5A). The secondary current can be very high (5.5A*325V = 1.78kW !!!). It would be better, if the primary shunt is enhanced to 1 Ohm.

Modified Schematic (modifications in doted circles):ATX DPS-240EP

That I could connect this power-supply with another ATX power-supply in series I removed the connection from the secondary GND to the primary “protective earth” (PE) (german: Schutzleiter). Attention, if the power-supply is faulty mains voltage on the secondary would no longer kill the fuse!

iROX Radio Alarm Clock external Power-Supply

The two 1.5V AA batteries in my radio (DCF77) alarm clock were empty and I didn’t want to change them with new ones. I preferred a solution with a DC wall adaptor.

The alarm clock has a built in projector, which can project the current time to a wall. This projector works, if the light button on the clock is pressed, for 5 seconds. If you want the projector to light all the time, an external DC source (3V, 100mA) is needed. With a switch on the case of the clock, the projector can be enabled durable (if the external DC source is connected).

The Clock needs a 3V and 1.5V Power supply from the batteries. The 1.5V are supplied from between the two batteries.

Original Clock Schematic (the clock itself is a blackbox):

Radio Alarm Clock original schematic
Radio Alarm Clock original schematic

Modified Schematic:

Radio Alarm Clock modified schematic
Radio Alarm Clock modified schematic

A problem is that without load, the transformer has an output-voltage of 6V. With 500 Ohms load, the voltage drops to 4V. If the projector is on, the transformer voltage drops to 2.8V. The challenge is, to provide the 3V and 1.5V with the simplest possible circuit. (Voltage regulators would be a solution, but to luxury for such a modification)

To serve 1.5V from the DC-Wall-Transformer, I experimented with different voltage dividers. I recognized that if the 1.5V voltage was higher than 1.5V, the clock didn’t work anymore. But it was no problem, if the 3V voltage was higher than 3V.

A 1/2 voltage divider with 2.7k Ohm resistors had a too high impedance for the clock (the 1.5V dropped to low and the clock didn’t turn on)

A 1/2 voltage divider with 250 Ohm Resistors worked, but only, if the projector was permanently turned on.

The final solution was a voltage divider with 250 Ohms to 125 Ohms. The 1.5V voltage is below 1.5V at 1.3V with 4V input voltage and at 1V with 3V input Voltage. But the alarm clock works fine with this solution. (It works with projector turned on and off)

Netgear GS608 v2 Repair

Netgear GS608 v2
Netgear GS608 v2

The LAN connection from a computer to my home-network stopped working from one day of the other. First I thought, it could have to do with the network-lan-card in the specific computer. Sadly I did no detailed test and did not locate the problem exactly.

Weeks later I realized, that other computers in the network couldn’t connect too over LAN. Next I updated the router (FritzBox 7390 ) to the newest firmware version (6.25). This didn’t solved the problem. If a Computer was directly over LAN connected to the FritzBox, everything worked. So the only bad thing between could be the Netgear 8 Port Switch GS608 v2. Strange was, that the LEDs in the Switch light up, if a device was connected by cable.

Because the switch is capable of 1Gbit/s it has two LEDs per Port (green an orange). If a 100Mbit/s device is connected, the orange LED shines. If a faster, 1Gbit/s device is connected, the green LED shines.

I recognized, that the FritzBox (capable of 1Gbit/s) was detected by the switch as 100Mbit/s = slow = orange light. My Laptop could only connect every 10 seconds for about one second. Really strange.

If I connected a 100Mbit/s Switch between my Laptop and the faulty Netgear Switch my connection to the network worked!

It turned out, that 100Mbit/s connections through the Netgear Switch worked, but faster connections caused problems.

Also only a number of devices were working properly, if more than 4 devices were plugged in, the later added devices couldn’t establish a connection – the LEDs of their ports stayed dark.

I didn’t know, what was happen with the router, which worked fine for 7 years. I searched the web and found randomly a post about a fix for this router https://tinajalabs.wordpress.com/2011/03/20/netgear-gs605-v2-fix/. The writer recognized, that his internet-connection was slow and searched the web and found, that bad capacitors in the switch can cause the problem.

I opened up the switch (4-Torx screws on the bottom under anti-slip pads) and saw the two blew up electrolyte capacitors. A third electrolyte capacitor was fine.

I unsoldered the capacitors and replaced them by two with identical capacity (1000uF) and voltage (10V) rating. (Mine are only rated 85°C and not 105°C like the old ones, but I think, they should last at least some years).

Problem solved, everything works again at full speed, as it should. I think this is a product more with planned obsolescence. Two small parts can make the whole device waste. And not everyone knows who two change electrolyte-capacitors.

 

 

 

Power supply for 2x100W Class-D Audio Amp

In my first semester of the EIT study at the FHNW in Windisch (Switzerland) I built in the Module “Basic Laboratory (of Electrical Engineering)” a Class-D audio amp. This amp was developed by Stefan Wicki at FHNW http://wictronic.ch/CDAMP.htm. The AMP needs a supply voltage between 12V 30V. Maximum Sinus-Power is 2x100W, 2x 200W Peak. Following current is needed:  200W/30V = 6.6A.

I had no power-source, which could deliver 7A @ 30V, so I decided to build my own. The first attempt was to use a toroidal transformer with following data: prim. 1x 230V AC, sec. 2x 19V 2x 5A, sec. 2x 18V 1A. I hooked up both of the powerful 5A 19V windings in parallel. The two 19V windings had a voltage-difference of about 1V. This is too much for direct in parallel connecting. There would be a high compensation-current of some Amperes from one winding to the other.

That the Load-Current is spitted equal to both windings I added a circuit, which distributes the load-current equal on both windings:

Toroid transformer windings parallel schematic
Toroid transformer windings parallel schematic

First, the both windings are separate rectified and filtered with capacitors. Then each DC current flows through a 0.1Ohm shunt. The currents are measured over the shunts with an Operation Amplifier and compared. The winding with the higher voltage has a Power-MOSFET in its DC-Path. This MOSFET is regulated with the OPA, that always the same amount of current flows through each shunt and therefore also through each winding.

The OPA is supplied over a DC-DC convert (which is galvanically isolated), which is supplied by the 2x18V windings in series. The GND of the OPA circuit is the the lower point of the two shunts.

The current sharing circuit works really well. Both windings are always loaded with the same current. Unsatisfied was, that the output voltage of this transformer solution was “only” about 25V (19V*sqrt(2) – 1.4V [Rectifier Drop] = 25V). The Class-D-Amp would take for the full 2x100W Power, 30V input voltage.

The circuit was built on a wood plate:

The Audio Amp worked very well with this transformer supply, but with almost full audio level of the pre-amp (Input Signal – 0db to – 8dB), the audio was not clear as before, and I think the Audio-Amp clipped, because of the too low supply voltage. (but this was until now not measured).

The Next step is to build a Power-Supply capable of minimum 7A @ 30V.

Later thoughts were, that the distorted audio at -8dB could be the total harmonic distortion, which could be already audible at this power-level: 100W*-8dBV = 100W*0.398 = 40W.

THD
THD

CTEK MXS 10 adjustable output voltage

lead battery connected to a 500W power inverter
lead battery connected to a 500W power inverter

For two lead gel batteries I bought the CTEK MXS 10 battery charger. This has a maximum charging current of 10A. The device is described as usable for any kind of car lead batteries, AMG lead batteries and most  gel lead batteries.

The 10A version has also a temperature sensor. With this, the device adjusts the output-charging voltage depended of the ambiance/ battery temperature.

The normal maximum charging voltage @20°C is 14,3V. Wet lead batteries have a maximum charging voltage of 14,4V @ 20°C. Over this voltage, the battery begins to gas. That means, the battery loses water as h2. This gas is explosive. This wet batteries can be refiled with distilled water. else they have a capacity lose. For wet batteries it is a need, that they come to the gassing-phase, that the acid-layers are mixed.

Gel lead batteries have solid content. The lead is bound in gel. It is not recommended to charge such batteries with voltages over 13,8V @ 20°C . Over this voltage, they can go over in the gassing-phase. An because the lead is bound and the cells are airtight, it is not possible to refill water. This batteries are maintenance free.

For my first battery  (gel lead-acid battery “starting bull 12V 95Ah / 595 33” http://www.batteriepool.de/Autobatterien/bis-100Ah/Banner-Starting-Bull-12V-95Ah-595-33::78.html) it worked perfect. Without attaching the external temperature sensor the charger charged with maximum 14,3V. As I could observe, the battery didn’t gas (I heard no “blub” or boiling noise) .

My second battery caused fast “blub” noise over 14V charging voltage. From the datasheet of the second battery (oerlinkon batteries 12CP150, 12V 150Ah, Datasheet 12CP150), and other source in the Internet, the most gel lead-acid batteries are known for a maximum charging voltage of 13,8V.

To change the maximum charging voltage I had the idea, to “change” the actual ambiance temperature, by heating or cooling the sensor.  Then I had the better idea, just to change the value, the sensor measures electronically. If the temperature raises, the charger lowers the output voltage.

For a test of the sensor, I heated it up with my hand around it while I measured the resistance. It has lowered. This means, that it is only a NTC-resistor in the temperature-sensor. So I replaced the external-sensor by a potentiometer. With this, I can adjust the maximum output-voltage of the charger. Problem solved!