High side switching with xiao esp32c6

I am looking for product recommendations for high side switching using a xiao esp32c6, so 3.3v. The voltage I want to be switching is from a 2s battery pack (two18650 in series for 7.4v, then another set in parallel to increase capacity). The load is a sim module that draws about 200ma. I want the switch to be as small as possible, so possibly in an IC format. Any recommendations will be much appreciated.

Thanks

2 Likes

Some of the aspects of want you want to do are unknown.
18650 batteries will vary from 4.2V fully charged to around 3.4V fully discharged.
So two in series will vary from 8.4V to 6.8V approximately.

I highly recommend using something like this as a battery holder and charge/discharge manager. Although it does not output 7.4V. It will ensure maximum life of the batteries. Many 18650 batteries have no inbuilt protection circuits.

As far as a high side switch goes Texas Instruments have a good video.
High-side switch introduction | Video | TI.com.

Regards
Jim

PS it does not pay to cut corners on Lithium batteries as they can be very dangerous.

2 Likes

Hey @Max263307, welcome to the forums!

Jim has a fantastic suggestion for this one! That would absolutely be the way I would solve this issue.

Otherwise, if that won’t do the trick we have a few of the INAxxx series of chips on breakout boards that you may be able to make use of.

If these solutions are still too large for the form factor you are chasing I would have a look at these chips:

  • AP22811
  • AP22802
  • BTS4140N

Hope this helps! :slight_smile:

1 Like

You already have some suggestions. You can also consider IRLZ44N

1 Like

Thankyou for the suggestions, the datasheets for both AP22811 and AP22802 say the maximum input voltage is 5.5v which is too small for my application. The BTS4140N datasheet says to power the load the input pin needs to be connected to ground, I don’t think this is possible without other hardware. The IRLZ44N may work but I personally have never had any luck with MOSFETS.
However, if I am wrong about any of this, please let me know!

I was wondering if this would work to switch the high side or if it only works for low side switching, and if it is controllable by a xiao esp32c6.
PCB Mount Solid State DIL Relay

1 Like

Hi Mark,

Welcome to the forum!

My recommendation for what you’re looking to do would be this MOSFET Power Switch Module, we have tested it to work at 3.3V and it will be more than capable of switching the load that you’re wanting to control.

1 Like

Hi Dan
copy from product page

  • Low side switching of 1 device with 2x AOD4184 N-Channel MOSFETs

I thought that a high side switch was required.
Cheers Bob

1 Like

Hi Bob,

You are most certainly right, there are some other great recommendations through this topic that Max should have no problem using instead.

1 Like

Hi Max,

You could also use an external regulator to switch power to any peripherals: SparkFun Buck Regulator Breakout - 3.3V (AP3429A) | Buy in Australia | COM-21337 | Core Electronics

The radio module you are using might have an EN or SDWN pin on it as well, would it be possible to have some more details about your project?

Hi Jack

To be honest WHERE.
The most useful info to date is Jim’s link to a TI video on high side switching.

Samuel came up and recommended 3 devices that are V, A, W monitoring and measurement devices. And communicate with I2C. Looks like a switch I don’t think.
In all fairness the 3 bulleted devices on the end of that post ARE high side switches but will apparently not handle Max’s voltage requirements.

Then Dan came up with a device that actually states on the Core product page

Now the point I am trying to make here is where does this leave the absolute newcomer. All well and good for more experienced people such as myself, James , Jeff and many others but I think the newcomer looks to Core staff as some sort of god or super being who knows just about everything and can mostly offer good help. With good reason too, you guys are selling all these goodies.

I guess I am suggesting that this is not an isolated case. Happens a bit far too often to not be noticed. Where Core staff can hop in quickly and obviously not really studied or understood the question being asked. I realise that staff are probably very busy and I am not above this sort of error where I have misread the requirement but I am of the belief that no response is often better than a completely incorrect one. Particularly where the respondents are held in pretty high esteem by newcomers and experienced alike.

Unfortunately confidence can be eroded more quickly than gained when this sort of error corps up too often.

Core Staff you are doing a pretty goo job all up so please consider the above as CONSTRUCTIVE criticism with a request for just a little more care with responses. Think about the old saying about a Bull in a China Shop.
Cheers and good wishes for XMAS Bob

2 Likes

Hey @Robert93820,

Thanks for letting us know. Mistakes absolutely do happen and we are lucky to have forum regulars like yourself to pull us up on it. This forum thread will be passed around the office and we will do our best to keep the quality of our responses as high as possible.

As a great example, I somehow misread this:

as looking for something in I2C format which is why my suggestions went in that direction.

Given this, allow me to change my recommendation to the MIC2505YM IC.

Hi Samuel
Forgiven.

That is an interesting device. The upper operating voltage could be a bit tight considering a 2S 18650 fully charged could be 8.4V (for a relatively short time). If Max can stand a bit of a voltage drop at lower voltage levels the use of a series diode of the 1N400X variety would see him in the upper voltage ball park OK.

As Liam120347 says a bit more info regarding actual requirements would be useful. If Max can tolerate the 0.7V drop at lower voltage levels the use of this chip should certainly be considered.
Cheers Bob

Hi All,

As Sam mentioned previously, the staff here obviously make mistakes. We are constantly working to further our own knowledge along with our users, and I can guarantee we metaphorically kick ourselves whenever we do it.

We appreciate your criticism Bob, your contributions don’t go unnoticed and we agree that our accuracy is paramount to the efficacy of the Core Forums, thank you.

Regarding the product recommendations, I have a few that may work, and a question for @Max263307, I’ll list them all below.

Firstly, we do sell a module from DFRobot that should work in this application, if you were hoping to grab something from us. It’s a FET-based “power controller” that can be controlled with as low as 3.3V, and can control anywhere from 5V-36V at 20A (Though a heat sink would be a good idea above 10A). The JST connector on the board is simply Vs, Gnd, and signal. This is not an IC, obviously. But if you’re after one of our products, this is the best option we offer.

Of course, we do sell a 5V relay you could use. But seeing as your logic voltage is 3.3V, a logic converter would be necessary.

As a recommendation for a proper IC, Infineon make a variety of switching modules designed for industrial application. Below is a datasheet for a High-Side Power control switch capable of 5V-42V at high currents. It comes in a TO-220 package (think standard power-transistor, dimensions are available online if you need). The logic voltage won’t matter, as the NMOS polarity is “flipped” internally. The input voltage pin is pulled high through a resistor, so you simply short this pin to ground in order to turn on the load’s voltage.

There are many similar IC’s out there. We may be able to facilitate purchase of these through one of our suppliers, if you’d like.

Let us know if you have any other questions!

3 Likes

Hi Zach
I reckon both those items would do Max’s job. That is considering what is known about his job at the moment. Which isn’t much.

That IC from RS looks pretty beefy. Interesting. Probably a lot more out there if one cares to browse RS and Element 14 catalogues. Both companies sell to Joe Public on a one item basis. That is a minimum order of 1 unit. Postage can be a bit daunting though for one of something. But I can vouch for the speed of Element 14. Have not dealt with RS for a while but used to be good.

Don’t be put off by “UK Stock”. When Element 14 say 3 to 5 days that is what they mean. UK or not. I think they must have their own Rocket whizzing back and forth. I have never waited more than 4 days. Even from UK. In reality though they probably have their own courier aircraft on a daily run. Element 14 I know have a large warehouse facility in Singapore.
Cheers Bob

3 Likes

@Max263307 This is a high side switch I used on one of my robot carts. The 5V could be a lot higher within the range of the Mosfets. Of course it will require some way of placing all the components, I used a small piece of vero board.

The problem with a high side switch is the Source and Gate of the P-Channel mosfet have to be at the same potential, making GPIO control hard when you want to switch high voltages.

Regards
Jim

But my post is wasted, @Max263307 does not seem to be an active account anymore.
The Gravity product is better using an opto coupler to isolate the GPIO input.

1 Like

Hi James
That is a pretty classic way of doing this. Probably as simple as it gets.
I have noticed though that most of the dedicated chip devices seem to go for a N Channel Mosfet for the switch with a complex bit of circuitry and a charge pump to generate the extra gate voltage rather than the simpler approach. Possibly due to the much lower forward voltage drop with the associated lower power dissipation requirements of the N Channel devices. Anyway the seem to think it is worth the extra complexity. If there is not much current involved the simpler approach would be the way to go.
But on the up side these chips do get a lot more protection and things like current limiting and are probably not that expensive.
Cheers Bob

3 Likes

Hi everyone,

I have been busy with work so sorry for the late response.

I seem to have sparked quite the discussion…
I thought I would start by giving more context about my project.
I am trying to make a 4G tracking collar, this is the most ambitious project I have attempted (previously only using Arduino, breakout boards and tutorials) hence needing help finding parts/creating custom circuits. The project is powered by a 2s battery pack (ranges from 8.4v to 6v) as the 4G module requires 5 volts. According to the schematic for the 4G module from the module’s wiki it has a an onboard MIC29302 LDO that can handle up to 16V input, high enough for the 2s battery pack.
The reason I want to switch this on and off is because I only want to transmit the location every 4 hours. Between these times I want the current usage to be as low as possible to save battery, hence the switch to turn it off. I tried to switch the module on the low side but the Tx and or Rx pin seems to somehow give the module a path to ground and stayed on. This is why I need a high side switch. When on, the module uses no more than 300ma.

I am then using a voltage divider to read the battery voltage which is transmitted along with the GPS data. I also want to be able to switch this as I want to reduce the current usage as much as possible to extend the life of the batteries. I was thinking of using the same thing for this as I will use for the 4G module. Currently I have an r2 of 2K and and r2 of 1K for my voltage divider to bring the 8.4v down to 2.8v for the xiao. I read that the higher the value of the resisters, the less current is used from the battery but the more inaccurate the reading becomes.

I am powering the xiao with a HT7333-A as it outputs 3.3v and has a low quiescent current. This is always on as the xiao needs constant power.

There is a module on/off control pin on the module but a jumper need to be configured to enable this. It is a small very small 0ohm resister but I fear my soldering skills are not at the level needed to enable this. I am also unsure of the current draw of the module when it is turned off via this pin.

To wrap up I will reiterate the requirements I feel is needed for the switch:

  • Be able to be switched with 3.3v
  • Be able to handle an input voltage of 6v to 8.4v
  • Have a small quiescent current
  • Be a small package
  • Be able to output 300ma

Another “nice to have” is two outputs, one for the 4G module and one for the voltage divider, but is not needed as I could just use two of the same devices.

I was wondering if a product such as this Darlington Transistor Array IC could work? It does have 7 outputs while I only need 2 but I can live with this.

Thanks Max

Hi Max
Re the Darlington array. NO. It is a low side switch. Does have the advantage of 7 switches in the one package with built it flywheel diodes for inductive loads but NO it will not do your job.
Cheers Bob
Your 8.4V seems to be a bit of a bogey man here. There is one IC in the previous posts somewhere which would do nicely but max voltage is 8V. I did describe a way around this if you care to browse back a bit using a diode. Only you know if this is feasible so you will just have to go back and have a look.

Hi Robert,

I believe this is what you’re referring too while talking about the MIC2505YM:

Just to clarify, you are suggesting to use a diode between the battery and the MIC2505YM to use the voltage drop to reduce the voltage to a safe operating voltage for the IC?

I have just had a look at both the FQP27P06 and 2N7000, the 2N7000 seems accessible from the common electrical retailers but the FQP27P06 seem to be only from the more bulk suppliers with large shipping costs. The FQP27P06 datasheet does allow voltage up to 60v which gives me a lot of headroom.

Would there be an alternative to the FQP27P06 that is more commonly accessible?

I believe the datasheets for both says there is a current consumption of about 1uA when not being used which is very acceptable, but please correct me if I’m wrong.