Hice un controlador de motor simple como se sugiere aquí
+12V ---------+---------+
| |
/ \ |
|M| motor --- 1N4001
\ / / \
| |
+---------+
|
|/
CTL -/\/\/--| 2N2222 NPN
1k |\>
|
---
-
¿Cómo conecto y controlo esto con Arduino?
¿Podría publicar instrucciones o dirigirme a algunos enlaces que pueden ser útiles?
+12V ---------+---------+ (Connect to the Vin or 9v on the Arduino)
| |
/ \ |
|M| motor --- 1N4001
\ / / \
| |
+---------+
|
|/
CTL -/\/\/--| 2N2222 NPN (Connect CTL to your Digital out pin)
1k |\>
|
---
- (Connect this to Gnd)
Conecte el pin de control de su controlador de motor a un pin de salida digital del Arduino, 13 es una buena opción. Conecte el pin de tierra de Arduino a la tierra de su controlador.
Aquí hay un boceto de Arduino para hacer un bucle, encendiéndolo y apagándolo.
int CTLPin = 13; // CTL connected to digital pin 13
void setup()
{
pinMode(CTLPin, OUTPUT); // sets the digital pin as output
}
void loop()
{
digitalWrite(CTLPin, HIGH); // sets the motor on
delay(1000); // waits for a second
digitalWrite(CTLPin, LOW); // sets the motor off
delay(1000); // waits for a second
}
Tomas O.
Tomas O.
Kortuk
Tomas O.
toby jaffey
Kortuk
Kellenjb
Kortuk
Kellenjb
toby jaffey
Kellenjb