Will this H-Bridge work?

Hello,

I'm trying to invert an Electromagnet and didn't had an H-Bridge IC. I planned a circuit with
N-Chanel Mosfets(https://www.infineon.com/assets/row/public/documents/24/49/infineon-irlb8748-datasheet-en.pdf?fileId=5546d462533600a401535660665b2595) and don't know if it will work or if I done something false.
Below is the circuit.
Thanks for your response

It won't work like that. To use N channel mosfets on the high side you need a special driver to lift the gates above the 6v rail.
Look for a design with P Channel mosfets on the the high side or look for a ready made H-Bridge board.

This may help: https://www.allaboutcircuits.com/technical-articles/h-bridge-dc-motor-control-complementary-pulse-width-modulation-pwm-shoot-through-dead-time-pwm/

OK thanks!
Would it work if I use a voltage below 5V for the Electromagnet?

Again, No. For an explanation, scroll to the last design in this link which shows a circuit with 4 N-channel mosfets entitled "Faulty Bridge" :

Incidentally, some of the circuits and information there may be appropriate for your application.

thank you!

How much current does the elecromagnet need?

0,375 Ampere

If you don't need to switch back and forth very fast you could just use two SPDT relays.

I think that won't work, because it needs to be quiet.

375mA is not much current so you could use tiny relays that just barely make a small click noise if you put your ear right next to it but it's up to you.

Thanks, but isn't there something I need to change so it will work because I already have these Mosfets at home or won't it work because of how Mosfets work?

@6v6gt has allready explained it won't work and to make it work you would need to buy additional components.

Give the solution to @6v6gt, I just repeated what he said.

but also thanks jim-p

You are welcome

Much easier and cheaper to buy a DRV8833 or TB6612 H-bridge.
Leo..

So what do you plan to do?

I planned to build a fake perpetuum mobile in form of a piston. I want to have a electromagnet to push and pull on a Neodymium magnet, so the piston moves.

I meant regarding the H bridge. Will you buy an off-the shelf module or still try to build your own?

I will by a IC or a relay. When I’m finished I try to build one myself. I think so.