I just need some feedback on the circuit diagram I made (it's my first time):
This is for a mini-car. There are two battery packs, one connected to an Arduino UNO, and the other connected to two motors. Both battery packs have a SPST switch.
The battery pack connected to the motors has a 6V regulator, and an electromagnet connected to the Arduino (digital pin 8) has a 5V regulator.
Any feedback would be fantastic!
Okay, I changed some stuff around. Instead of connecting the motors/electromagnet directly to the digital pins (stupidly), I added MOSFET transistors to control the motors/electromagnet from the Arduino. The motors have a diode and capacitor. I hope this is a step in the right direction.
*the 6V regulator I mentioned earlier is not in here; I need to read more about it later and will add it in
Okay, hopefully this is finalized circuit.
I'm sorry to say, you need to go back to the drawing board.
An Arduino Uno (i.e., ATMega328P) can only sink or source an absolute maximum of 40mA through any one of its IO pins, and Atmel only guarantee up to 20mA.
That is not enough current to power (or sink power from) things like motors, electromagnets, etc.
You need to switch the motors etc with transistors, and add flyback diodes to absorb the induced back EMF from the collapsing magnetic fields.
Treat them like you would a relay - google "Arduino Relay" for how to do that.
Also, your regulators make no sense, and your batteries are backwards.