Electronics: Arduino Welder
I’ve been playing around with some Arduino microcontrollers, mainly the Arduino Mega 2560. They are fairly inexpensive controllers, that when programmed, can handle a large variety of tasks. These vary from simple leds being turned on, servos activated, audio played, or basically anything you can think of. In this simple setup, I wanted to use a blue led to simulate a welder for a few seconds. I added a push button to start the loop. Check out the full video inside.
Welder.sketch
// Welder with push button // Author: Michael Peters Bond - Merrimack Valley Railroad int LED = 12; int BUTTON = 4; void setup() { // put your setup code here, to run once: pinMode(LED, OUTPUT); pinMode(BUTTON, INPUT); } void loop() { // put your main code here, to run repeatedly: if(digitalRead(BUTTON) == HIGH) { int i,count; //count=random(10,60); for (i=0;i<100;i++) { digitalWrite(LED, HIGH); // set the LED on delay(random(60)); digitalWrite(LED, LOW); // set the LED off delay(random(200)); } } else { digitalWrite(LED, LOW); } }
Here is the Fritzing design I created to match the circuit.
Get the Arduino Mega 2560 for yourself: https://www.amazon.com/Inland-Arduino-Mega-2560/dp/B01MZGWC2E/