I am pretty new to Arduino and i wanted to start a project.
The project should be like a Usb-Hub for my devices.
I need around 4 Usb Ports on the Arduino and each one must be able to be turned on/off,
Is it possible to connect that much usb ports on a Arduino and is it somehow possible to switch them on/off and how would you do that?
I would appreciate any help, since im kinda stuck,
There are unpowered USB hubs and there are powered USB hubs, which I am using right now, so which are you referring to? The unpowered hubs have the USB and the power connections all common. The powered hubs have only the data connections in common. Common power is supplied by a separate power supply. That powers stuff even if the PC is turned off.
The Arduino, or better still an ESP8266 or ESP32 running a web browser could be controlled using a web page on the PC
The microcontroller would then need some way to turn each USB socket on or off using a relay or a MOSFET
What are the USB connections going to be used for and is it only the power supplied by them that you want to turn on and off ? What are the USB sockets connected to and what will be plugged into them ?
If I have this correct you want to switch 4 different USB ports the +5V only, the data is open and the grounds are connected (switching grounds can cause problems). You can do this with 4 high side switches easy to implement with logic level avalanche rated P-Channel MOSFETs. Work with this and post a preliminary schematic not a frizzy picture and we will get you through it. Also post links to technical information on each of the hardware devices. Also you should also add current limit to each of the ports, the values are stated in the USB specifications. This is to protect your devices and computer.