ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

Main Area and Open Discussion > Living Room

Need hardware (and software) to reset power when internet connection is lost

<< < (3/4) > >>

4wd:
Both of these look like perfectly reasonable solutions, and I think I could buy all the parts needed to make it for under $5, including shipping, on AliExpress. But I'll have to wait 1-2 months for them to arrive. Or even longer, since the order won't even be processed for another 1-2 weeks due to Lunar New Year celebrations halting virtually all business in China.

The cheapskate in me wants to do this method. But it's far enough out of my depth of knowledge that I'm not even sure I'm adding the right parts to my shopping cart. I'd hate to wait the 2 months for the parts to arrive only to realize that I got the wrong things or I can't get it to work.-Deozaan (February 14, 2021, 02:10 AM)
--- End quote ---

Mouser Electronics, all in stock:
1k resistor
1N4007 diode
5V relay
BC548 transistor
Total: $3.41 + Postage

Plus a plug and socket to match the output lead of the existing modem PSU, (I'd usually just cannibalise something I have laying around ... got a lot of old modem/routers atm because of the big NBN upgrade).

If you haven't got a soldering iron, etc then a cheap solderless breadboard is $3.80, (that one seems to be big enough to take the relay).
NOTE: This needs checking, lead length on the relay is 3.6mm - the specs for the breadboard don't mention minimum lead length for components but if my breadboards are anything to go by that lead length might be a little on the short side.

If you're wondering why the change of transistor, (BC548 vs original BC547), the relay draws 106mA, the BC547 is rated to 100mA.  The BC548 chosen is rated for 200mA, a little safety margin against the transistor going blah. Base-Emitter and Emitter-Collector voltage is a little less but the diode is there to clamp the spike from the relay so should be OK.

I didn't know what a ZigBee was so I looked it up and it appears to just be a smart plug. I actually bought a smart plug recently, but it was a Christmas gift for someone else. I got a really good deal on it (only $1!) but I thought I'd never want to use one, because I didn't want it snooping on me and phoning home without my knowledge/consent. Do you happen to know if smart plugs in general, or the ZigBee specifically, snoop and phone home about stuff? I guess there's not much data that could be gathered from a smart plug, assuming it doesn't have a (potentially hidden) microphone or camera. I think the only things it could know about are just the times/schedule when it is on or off, and perhaps the name of my SSID and nearby SSIDs. But even so, I don't like the idea of internet-connected devices which report on me to their overlords (says the guy with multiple Android devices and multiple Windows 10 PCs in his household...).
--- End quote ---

ZigBee is a closed network system, it has no connection to the internet or any, (normal), WiFi interworking at all, it's low power, slow (250kbps), and intended for home automation, set and forget remote sensors, battery powered sensors, etc.
Maximum of 100m range LOS and capable of mesh working, ie. the clients don't need to all be within range of the host, they can relay messages from client to client until it gets to the intended client.

I have a couple of ZigBee plugs here that I can control through the Echo Plus, (it has an inbuilt ZigBee host).

I wouldn't be surprised if there was an Alexa Skill to monitor an internet connection and trigger a smart plug ... I should do a search.

Shades:
The electrical grid in Paraguay is flawed, to put it mildly. The office where I work is in an area. if you go to the second floor, you can see the outer wall of a power relay station from the national grid. Still, even there it is bad.

Anyway, these last few years there was only one company that could connect the office using a cable connection and because of that crappy grid we went through a lot of modems. Almost 2 years ago a similar problem like the one from the OP happened to the current modem. Being fed up with our ISP simply replacing the modem as a "solution" (and the configuration headache that gives me), the power supply was changed. Originally the modem comes with a "wall wart" power supply. As my boss is playing around with self build 3D-printers, there was a spare power supply for a heat-bed available and I used that instead of the original power supply. Volt output on both supplies were practically matching, the heat-bed power supply is capable of delivering more amps, but is "smart" and detects what amps are needed and only delivers what is needed.

Modem, till this day, works perfectly again.

My take on it is that the original power supply is made as cheaply as possible and electronics do degrade over time. The original power supply just couldn't deliver the required volts/amps reliably enough anymore, which introduced all kinds of weird behavior, including the need to reboot/power-cycle the modem once a day.

Still, if you need to do a power-cycle once per 24 hours, you could consider a much more basic (but very reliable) method, like programmable outlets:
APC-P4GC-Wall-Surge-Protector
GE-Programmable-Grounded-Intervals

Very cheap, very reliable.

Or if you want an analog one:
NSi-Industries-TORK-RTN312-Incandescent

Or one you can control by voice (if you have an Alexa):
LINGANZH-Required-Wireless-Remotely-Anywhere

Deozaan:
On amazon: https://www.amazon.com/dp/B08GLTN49M/
and https://www.amazon.com/Connect-Monitors-Connectivity-Required-Necessary/dp/B07MCRQPCS
-mouser (February 14, 2021, 04:54 AM)
--- End quote ---

Wow. I tried looking for similar, cheaper devices than the ezOutlet3 but didn't see anything that appeared to do the same thing. Considering those are half the cost of the ezOutlet3, I'm going to try to cancel the original order I made last night and go for one of those as my short-term solution.

Mouser Electronics, all in stock:
1k resistor
1N4007 diode
5V relay
BC548 transistor
Total: $3.41 + Postage

Plus a plug and socket to match the output lead of the existing modem PSU, (I'd usually just cannibalise something I have laying around ... got a lot of old modem/routers atm because of the big NBN upgrade).

If you haven't got a soldering iron, etc then a cheap solderless breadboard is $3.80, (that one seems to be big enough to take the relay).
NOTE: This needs checking, lead length on the relay is 3.6mm - the specs for the breadboard don't mention minimum lead length for components but if my breadboards are anything to go by that lead length might be a little on the short side.
-4wd (February 14, 2021, 05:55 AM)
--- End quote ---

Oh, double wow! I was looking at the relay module thinking it was going to be a lot of DIY. This is even more DIY, essentially building a relay module from its smaller components. I do have a soldering iron. I'm almost completely inexperienced with soldering, but I have replaced a couple of microswitches in my computer mice a few times. And I do have an old modem power supply which probably has the same rating as the current one, which I think I could cannibalize for this project. So it looks like that list includes just about everything I'd need, but wouldn't I also need some kind of breadboard wires (jumper cables?) for connecting the RasPi directly to the relay?

Deozaan:
To everyone who has responded (or will yet respond) to this thread: Thank you very much for your input! I'm reading it all. If I don't respond to you directly or to something you said, it's not because I'm ignoring what you said. It's more that this is such a new area for me that I've got a bit of information overload and can't hold all these things in my mind at once. I don't know enough about these things to properly discern which information is most relevant and which is somewhat ancillary.

If you feel you've said something that warrants a direct response, please follow up with me so I can make sure to give you the response you deserve. :)

wraith808:
The reason this is a problem anytime I'm not immediately available to spring into action is because I also keep my RasPi connected to at least one cryptocurrency peer-to-peer network in which I can be penalized or deemed less trustworthy if someone tries to connect to my device and it doesn't respond. It's not making me rich, but it's earning me a decent amount of money simply for keeping a device running/connected that I'm already leaving running/connected 24/7 anyway as my personal media server and whatnot.
-Deozaan (February 14, 2021, 02:10 AM)
--- End quote ---

You buried the lede. What is that, and how does it work? Maybe on a new thread. That sounds interesting...

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version