Alex pointed out that in the OpenTherm specification it is stated that a master unit, i.e. your thermostat in the living room or a controller (in Alex's case), could be powered by the interface (use google to find the specification).
In the OpenTherm specification the boiler is slave (although providing the current loop) and the master is the remote control unit. He asked me if it could be done, and looking at the first schematic I drafted a battle plan:
- get rid of the dissipative receiver resistor;
- get rid of the dissipative transmission resistor;
- get rid of the optocouplers, (isolation is good and desired but CTR isn't very good for cheap opto's... hence more current).
- with whatever power is available, use a LDO and power something.
- Design a current loop transmitter (4-17mA)for testing that works at 40V.
- Design a two level shunt regulator for transmitting from master to slave.
- Design a minimal loss current loop receiver with output to 3.3V logic systems.
I have planed a tribute post to Jim Williams and Bob Pease playing around analog computers, but time hasn't allowed it... so this short one goes to them and to Bob Widlar.
First I had to design the current loop transmitter to test the system, the input had to be 40V so that under lower load the output voltage was close to that (part of the OpenTherm specification). I remembered the LM10 (designed by Widlar) had an interesting feature in it's datasheet, it is the only OpAmp I know that has been specified for shunt operation (Dear TI that page says "all national products now are belong to us" in front of the datasheet is .... lame).
It also had a application schematic for a current controller, I modified that schematic to allow a push-button (4-20mA) switch (for those not able to find the LM10 check here for an alternative way to generate the current loop, replace DAC with voltage generator).
Then was the master transmitter, basically a shunt regulator with two levels, inactive 7V and active 15V. I used two diodes in series as the reference to the minimum voltage for the regulator, there's a hell of thermal drift but I don't expect the temperature to move outside the range 16C-40C with a corresponding error of 120mV and respective change of about 600mV, therefore negligible. Also I added the push-button to change from one state to the other. I thought of using the same LM10 but unfortunately the LM10 is too slow even for the 2kHz output waveform (it is 1kHz manchester encoded), so the next big thing in single supply opamps capable of 30V operation is the quad LM324, I've used the double LM358. They have their problems in precision and audio circuits but they're good enough and fast enough for the job.
Finally I designed the receiver, the current loop receiver was a nice exercise. I used a simple linear converter to adapt the current levels at the current sense resistor to voltages of less than 0,7V (4-9mA) for the low level and greater than 2,0V for the high level (20mA). One interesting point one is that even single supply amps can work with negative voltages as long as the output is within specification and the voltage at the pin is not negative.
And that's it, I just need to wire a small pref board and send it to be tested.