diy smart multiway trailing socket.

Adding to my Home Automation thing that seems to be going pretty well so far (good lockdown project <g>) and with my interest spiked by mate getting a 3 way TP-Link smart trailing socket (KP303) that works well in Home Assistant, I was thinking of making my own 4 / 8 way versions, the 8 way for powering all the TV / HiFi stuff, much of which is not used most of the time. [1]

I was thinking of using skirting / dado trunking for the 'boxes' with

1 gang accessory plates to take single 13A sockets and with a couple of end caps (glued on with PVC cement) and possibly some small bits of cover between the accessory plates (depending on make / model possibly?), I should be good to go.

An 8 way could be two 4 ways fixed side by side.

The electronics are easy with an ESP32 WiFi micro controller driving 1 or 2 opto-isolated 4 way relay boards, some mains flex, cable restraining grommet in a end cap and 13A plug (with low value fuse) and I assume it would be ok to wire it internally with singles? If so, what CSA would I need (/ safely get away with as officially as any of this would require), working on the basis that no outlet would be drawing any real current and the relays themselves probably aren't really good for more than 5A (although they are (Chinese) 'rated' at

10A at 240v (SRD-05VDC-SL-C)).

So I'm also looking for recommendations on the trunking. I will probably only need 1 off 3m(?) length of the actual trunking and cover but will need a few 1 gang outlet plates and ends ... and looking around, any can be quite expensive so I would be interested to learn what could be the best VFM brand for all of the bits that I might be able to pickup from one of the normal suppliers?

eg. TLC do the Univolt 100mm x 50 line:

formatting link
Where the 3m trunking is only 17.40 / 3m length but the 1 gang accessory boxes are £2.40 (3+).

Similar pricing with Toolstation Kestrel / Merlin lines but I have seen others with a lighter 1 gang accessory plate that was under £1 but the trunking was more expensive.

Cheers, T i m

[1] Measuring the power consumption of a commercial 13A smart socket, I couldn't measure anything when it was deactivated but .6w when it was active (relay pulled in). Considering the sort of thing I will be controlling will either generally be mostly off or mostly on, by building my own solution I can wire each socket to the NO or NC contacts on the relay and therefore do what minimises the overall load the best. Some devices might only be powered up now and again whilst it might be handy to be able to remotely reset other things that would otherwise be on 24/7 [2]. Or maybe de-power them on a timer or other household activity (like there may be no point leaving the TV on (or on standby) if we are generally in bed between 01:00 and 07:00). [1] Like my Ricoh printer needs power-cycling after a firmware update and it's not that easy to get to the power switch or plug etc.
Reply to
T i m
Loading thread data ...

Why go to all that trouble when you can fit these;

formatting link
If you need several things switched on at the same time they can be grouped. Each socket in each double can also be controlled separately.

Richard

Reply to
Tricky Dicky

You could use panel mounting 13A sockets. Surprisingly they're rather good value at £1.68 + Vat at Canford

formatting link
compared to £6 + Vat at RS
formatting link
Owain

Reply to
Owain Lastname
<snip>

Well, because 1) this is a d-i-y group and that's what I wanted to do <g>, 2) the cost would likely be higher, 3) the chances are the parasitic power consumption would likely be higher than any solution where you could set the socket to be 'live' when the relay was deactivated and 4) it would still need the trunking (as I'm not about to start fitting them permanently into / onto the wall for this sort of role).

5) Do we know these are compatible with Home Assistant OOI?

Cheers, T i m

Reply to
T i m

Sounds an expensive - and dare I say bulky/ugly? - way to go about this.

Have you considered buying a ready-made extension socket and putting something like a Shelly smart relay inside? Something like this:

formatting link
(Only 4-way in this instance but just posting for illustration of approach)

Mathew

Reply to
Mathew Newton

Funny you should mention those Owain, I used very similar sockets ~40 years ago when I made an 8 way trailing socket (in a metal project box) for my disco ... and I'm still using it. ;-)

In fact, I believe I still have the Q-Max cutter ... ;-)

From memory, I believe it could be the RS style sockets I used (I remember the shape) but given the Q-Max cutter makes a pretty neat hole so the small 'shoulders' on the Canford offering would probably work fine, even when mounted in plastic.

It would certainly make any solution more compact but wouldn't allow me to override each position 'off' with a switch (in the event of an issue) , so I would have to unplug etc (not a biggie, given the role / cost saving per position).

I could probably then get away with some smaller (/cheaper) plastic trunking and mount the sockets in the body (rather than the lid) and still be able to access the back via the 'lid / cover' if required [1]. Or use 100 mm trunking the same way and 'joggle' the sockets down the length, potentially making an 8 way shorter?

Plus no need for each of the mounting modules or inter-module strips etc. ;-)

What about the idea of running the mains wiring in singles and would I have to run 2.5 sq mm (I have a roll of each as it happens but though it might be easier at the relays if in say 1.5mm)?

Plastic would be required for the box, or maybe one bit of the box as the ESP32 uses WiFi etc.

Can you get 10 port lever nut connectors (for the feeds to the relays as I'm not sure if they would take two conductors (nicely) if they were daisy chained)?

Cheers, T i m

Reply to
T i m

If you put an adjacent SPCO centre off toggle switch you can set each socket to on/off/relay

As it'll be downstream of a 13A fuse, internal to equipment and not bound together in a cable you can probably use 1mm :-)

Owain

Reply to
Owain Lastname

On Tue, 23 Mar 2021 05:40:31 -0700 (PDT), Mathew Newton snipped-for-privacy@googlemail.com wrote: <snip>

Possibly not that expensive when compared with less flexible commercial offerings, especially when you go up in the socket numbers? I think the 3 way TP-Link was £29 (maybe found for £25) so if I built say 5 off 6 way smart strips from one length of trunking and the 'value' mounts / sockets I could in much cheaper / strip?

And the idea is to make each unit have at least 4 'smart' sockets, along with possibly two always-on sockets as I'll need one to take 5V a wall wart to power the electronics (might be easier than trying to fit a 240V->5V PSU inside the trunking).

Not really an issue here as in most cases they will be behind / under other 'gear'.

Yes <g>, I have a fairly 'boxy' 6 way (faulty) 'Master socket' (6 slaves off one master) that I did consider adapting but then I'd have to start cutting the live bus bar (no switches on the slave ports) and I'm not sure if I could get the 8 way (or 4+2) relay boards in there.

Understood ... and that's the sort of goal Mathew but with every socket 'smart', something that would likely end up more expensive / complex with individual Shelly / SonOff modules. With my solution, one (very cheap) ESP32 and an equally cheap opto coupled relay board would manage all the outlets individually?

That might be a good way to make better use of the 'faulty' Master (power sensing) + 6 way trailing socket I have here though so thanks for the thought. ;-) [1]

The good thing about using the ESP32 is if I want to change anything I can re-program the ESP32 OTA and already know I can integrate them into Home Assistant etc. You can also set things like interlocks, ensuring that only one device can be switched at once (if that was required etc).

Cheers, T i m

[1] I recently added a SonOff smart switch, similar to the Shelly to our kitchen lights, driven by either (mainly) a PIR ... giving me good occupancy sensing or can be overridden (on / off) by the existing two way pull cord switches).
Reply to
T i m

Yeah, I had though of that (between ESP32 and relay board) as well but would probably be overkill in this case.

I would probably go even smaller in the plug top, FWIW.

Cool, it was that I was trying to consider the massive discrepancy between the relatively small screw terminals on the relay board and (typical) caverns as found on most mains switch sockets. ;-)

Cheers, T i m

Reply to
T i m

You could use one COTS smart socket to feed any number of extension sockets if you want, given the very low total overall load.

(although the argument for a fully realised and adaptable DIY solution understood!)

Reply to
John Rumm
<snip>

Very interesting.

That's an incredibly low price, I wonder how they're doing it. I'm even wondering if the price is a mistake.

Reply to
Fredxx

A lot of British General stuff is roughly half the price of other brands. I know some electricians don't like it (it smells of cheapskate DIY bodges) but I don't know if it's actually materially worse.

(I think BG stuff is made in China - I'm not sure if Hager/Electrium/etc are also)

Theo

Reply to
Theo

The price is correct. I find they are quite stable performance wise although initial set up can be a faff at times but there are work around, once paired with your WiFi they keep that connection even if you power them down. I have six around the house one behind a cupboard and it always responds. The only thing which is poor is the indication light which in daylight is hard to see and although there is a routine to make it brighter it does not make much difference. As for being made in China, what isn?t these days? I have given up worrying about those things if Chairman/President Xi wants to know when I turn my lights on he is welcome.

Richard

Reply to
Tricky Dicky
<snip>

Of course, and if an energy monitored one, have that bonus as well.

Quite, and sort of the goal here, to see if I could or how feasible it might be assemble a multi-way fully smart socket strip, using COTS solutions (ESP32, 5V, 4 way relay board, 13A sockets, suitable enclosure etc), especially I already have most the hardware and the ESP integration in HA tested and working so reasonably confident I could do what's required with the coding (well, copy > paste > tweak etc). ;-)

I had considered just getting a TP-Link KP303, mostly for the whole HA S&G's (and because I've seen it working via Teamviewer on my mates HA system), but it would be 'what happens if / when it goes wrong out of warranty', and it's only 3 way.

A 5 x 1 gang trunking box would require little in the way of 'making' (eg, just assembly) and if the 1st socket was permanently live and also contained a USB PSU, I have a ready made PSU to run the ESP32 and relays etc (or just have a plain socket and external Wall Wart one etc)along with 4 fully managed sockets.

I know I'm a bit late to the whole HA game compared with a few here but it's been interesting / fun (even so far) to be able to do something I've referenced over the years and that's be able to 'Manage what you can measure'.

Cheers, T i m

Reply to
T i m

There are some 4 way ones here ('power strips' section):

formatting link
and those can be reflashed with open source firmware which doesn't depend on cloud services. The Tasmota firmware is well supported in HA (via MQTT).

I wonder if you could fit some square guttering or similar uPVC profile to mount the sockets in (although probably still need backboxes for fire proofing).

Theo

Reply to
Theo

Not completely uncommon with some of this kit.

Funnily I had my fist Zigbee device (a PIR) appear to disconnect itself and need re-integrating but It could have also been 'other stuff'.

That's where they really win, where you wouldn't be able to get to a conventional socket. That said, I generally don't mind using a tank cutter and making a hole in the back of a flatpack wardrobe or cupboard to enable me to both unplug or turn on/off such things, 'in case'.

I have a range of smart kit and the 'On' indicator lamps range from nearly 'blindingly bright' (especially at night) to 'can hardly see them, even in the dark'. It's like the designers never actually use them ITRW? ;-(

Quite.

Well lots of people prefer that they didn't of course and where the likes of Home Assistant and being able to integrate smart stuff into it directly (locally) is fairly important to them.

It also means you don't end up with a spattering of different apps controlling different things.

Looking at this thread, I think it suggests the BG sockets are manageable within HA ...(Broadlink integration)?

formatting link
I might get a socket to play with (someone mentioned on the thread above that Asda sell / sold them cheaper than SF)?

Cheers, T i m

Reply to
T i m

I've not actually tried any of that as yet ...

... I have seen plenty of mentions of Tasmota

I have to say I still don't have a clue if I have that installed, configured or running .... and if it is, if anything uses it or how it would (or how I would make it use it) if it wasn't?

Every Youtube video on it I've watched seems to assume you know what the point of it is and / or how that relates to it's use ITRW? ;-(

OK, I think I get it's a form of communication delivery protocol (with different levels) and it looks like there would be instances where I could do with it, just that I have no idea where to start?

I have installed Mosquito MQTT broker and run their functionality test (and it seems to be installed and working) but it didn't seem to make anything I already had installed any more / less reliable or work.

Someone on the HA forum suggested I installed a MQTT broker but I thought I read HA has one built in *anyway*? They also said it needed configuring (manually) but it seemed to pass the suggested test message broadcast after auto configuring itself so I gave up (didn't really trust them).

All that was why I considered using std trunking Theo, that it was

*designed* to carry this sort of thing and so more likely to be accepted as an 'ok' solution.

Cheers, T i m

Reply to
T i m

How do you know it's not handing over complete remote access to your network?

(you did partition it onto its own wifi SSID/VLAN dedicated to HA and no access to the rest of the network) :-)

Reply to
John Rumm

Also by rolling your own you get full control over the security of the thing, and know its not reaching out through your firewall to a server that can then allow external connections back in (as seems to be common for many devices like this where they want to enable access via apps running on phones etc via the internet)

Yup, I am so well up on HA I now have a thermally sensitive switch that controls my central heating! :-)

Reply to
John Rumm
<snip>

Given I don't really want / need remote access to all my HA stuff I was thinking of putting up a spare AP and running it all off that (well, the HA host and the WiFi connected devices anyway).

When you reserve ip's to MACs, can you normally specify what address you want exactly as I don't seem able to do such on my old Fritzbox!FonWan?

To be clear, I can reserve an address to the MAC it's currently on, just not tell it which one to use (which would be nice for grouping devices together etc).

Cheers, T i m

Reply to
T i m

HomeOwnersHub website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.