ON/OFF switch approach - RAK5005/4631

Hey guys, So I managed to build myself a 3D printed enclosure for my Helium Mapper/Tracker (I also push the data to Traccar.) However, I want to put in an external on/off switch, but maintain the ability to charge the battery via USB. What is the best approach here? Real estate inside the enclosure is at a premium and the only examples I found utilize the large IO board.
Any suggestions? Thanks in advance.

Welcome to RAK forum @DirtyOptics ,

Well done enclosure. Very neat :ok_hand:

Regarding the on/off switch, it seems there is no short cut on this one but to add a tiny slide switch and cut one line of the battery. You might be needing a minor redesign on your 3D printed enclosure though.

Thanks @carlrowan ok, I will give that a go. Happy to make the changes to the enclosure. For me thats the fun part! the electronics…not so much…hahah

I might also look to fit the RAK 19004 to diversify the power options. I’ll need to do some research on this.

1 Like

Do you want to be able to charge the battery when the switch is OFF? If so, you can’t put the switch on one of the battery leads as mentioned above - no battery leads, no charging.

You would need to do something like putting a switch to a GPIO pin and handle the “off” in software (or maybe a different solution), I would think.

If you don’t need to charge while the switch is OFF, then definitely just put a switch on a battery lead. That said, the device would still be ON if a USB cable was plugged in…

So long story short, you need to be more clean on what you mean by “OFF”, as the answer depends greatly on the specifications.

1 Like

Appreciate the response. Ultimately I would love to be able to charge the device whilst in the off state. I understand that putting the switch in-line with the battery will negate this. The only real way I can think of doing this is with a separate charge circuit that is not part of the wisblock core, however, that will enlarge the unit which I really don’t want to do. I want to keep it as compact as possible.

Is it even possible to switch via software? That’s the big question!

I would think you could do something like one of the lora button examples on this forum, and basically leave the device in deep sleep unless the switch state changes (similar trigger to pushing a button in some of the button examples). The device wouldn’t be “100% off”, but power usage may be low enough that it wouldn’t matter at that point.

I’ll have to look into this. Probably a bit beyond my skillset, but none the less, will do some research.

1 Like

Making it simple at this point wont probably hurt. The discharge current is much lower than your charging current so at one point, you will be able to fully charge the battery :wink:

2 Likes

WWow @DirtyOptics - that looks awesome.

Can i ask if you could post some photos of the inside?

haha yes, but I still don’t always want the unit ‘tracking’ or wasting its time trying. I see some of the new base-boards have switches, but they are in super awkward positions. I might order a few and see if I can come up with some other enclosures to suit. Or desolder and go from that…

I’ll take a few tomorrow and post them up. It’s still not 100% finished.

Sorry for the delay, but Have still been playing with antenna configurations, adding the switch etc etc…

3 Likes

Thank you! That looks great