ATtiny85 and MOSFET as SSR to control +5V device?

Hi!
I'm considering making a board for controlling the +5V of a USB-device (turn off/on USB device with script).

First of all, would the ATtiny85 be ok, or are there other 5V AVR's that could work? (Everything will be powered from a USB-cable).

How about the MOSFET - I've never worked with them before, but anything that can turn on/off a 5V device and approx 0.5-2A current would be great.

THT parts preferred, but SMT is OK.

The mosfet doesn't really use current to turn on and off like a standard BJT transistor does. It just has to have voltage....

First of all, would the ATtiny85 be ok, or are there other 5V AVR's that could work? (Everything will be powered from a USB-cable).

There are dozens of other AVRs that could do the same job. But what the job of the ATtiny? The MOSFET itself can switch 5V without a problem and 2A of current is fine for many MOSFETs. Just make sure the threshold voltage is low enough to be switched by a 5V input.

LandonW:
The mosfet doesn't really use current to turn on and off like a standard BJT transistor does. It just has to have voltage....

The current I referred to was how much it could handle for the device it turns on.

pylon:
There are dozens of other AVRs that could do the same job. But what the job of the ATtiny? The MOSFET itself can switch 5V without a problem and 2A of current is fine for many MOSFETs. Just make sure the threshold voltage is low enough to be switched by a 5V input.

I didn’t realize the ATtiny could run directly off 5V, so I’ll use that.
It’s to control the MOSFET from COM port on a computer.

Remotely “unplug” USB device with a script.

A MOSFET is controlled like a transistor.

Unsigned_Arduino:
A MOSFET is controlled like a transistor

MOSFET, Metal-Oxide Semiconductor Field Effect Transistor
BTJ, Bi Polar Junction Transistor

They are not the same.... and definitely not controlled the same.

BJT is current input control, output current.
MOSFET is voltage input control, output current.

https://www.elprocus.com/difference-between-bjt-and-mosfet/

Tom.. :slight_smile:

OK, so I guess I'm a bit confused with how the components are used.

I have another project as well, where I need to fully turn off a PWM fan (because minimum is 400RPM).

I thought a MOSFET was a SSR, but I guess SSR is a different component?

What would be the best way to turn 5V devices (1-2A) on/off like the first post in this thread?
Also the same question, but with 12V devies (0.5-1A)?

I thought MOSFET was a simple "drop-in" replacement for a normal relay (which I don't want to use because of the click).

I thought MOSFET was a simple "drop-in" replacement for a normal relay (which I don't want to use because of the click).

An SSR is a drop-in replacement for relays in most cases but a MOSFET is more like a standard transistor however not current-driven but voltage-driven. You have to carefully choose the right type and you often need more components to drive it correctly, usually at least a drop-down resistor is needed.

pylon:
you often need more components to drive it correctly, usually at least a drop-down resistor is needed.

A pull up or down resistor is typically needed, but a current limiting resistor is not needed, typically, so more often, less components to drive a MOSFET.

[u]MOSFET driver[/u].

[u]Transistor driver[/u].

I thought a MOSFET was a SSR, but I guess SSR is a different component?

A DC solid state relay probably has a MOSFET inside. An AC SSR usually has a TRIAC inside.

A solid state relay is optically isolated. There is no electrical connection between the "input" and the "output". The coil and contacts on regular electro-mechanical relays are also electrically-isolated. (Of course, they don't have to be isolated in your final circuit.)

Usually a solid state relay doesn't need any additional components, but there are some that require an external current-limiting resistor for the LED.