All Articles by Atari

2134 Articles

Arduino Basics Lesson 3-1: Ultrasonic DME

For the “Arduino For Kooks” course, I recommend you get the Arduino Starter Kit available here.

Now that we’ve learned the basics of digital and analog signalling on an Arduino, let’s start exploring with different kinds of sensors. The ultrasonic sensor module is a rudimentary SONAR device that emits and detects a particular high-frequency sound pulse. We can use this pulse to determine the location and relative position of objects.

The Circuit:

Using jumpers, connect +5V on the Arduino to VCC on the sensor and GND to GND. Connect the sensor’s Trigger and Echo pins to the Arduino at D2 and D4 respectively.

The Sketch:

const int trigPin = 2;
const int echoPin = 4;
void setup() {
Serial.begin(9600);}
void loop()
{
long duration, inches, cm;
pinMode(trigPin, OUTPUT);
digitalWrite(trigPin, LOW);
delayMicroseconds(2);
digitalWrite(trigPin, HIGH);
delayMicroseconds(10);
digitalWrite(trigPin, LOW);
pinMode(echoPin, INPUT);
duration = pulseIn(echoPin, HIGH);
inches = microsecondsToInches(duration);
cm = microsecondsToCentimeters(duration);
Serial.print(inches);
Serial.print("in, ");
Serial.print(cm);
Serial.print("cm");
Serial.println();
delay(100);
}
long microsecondsToInches(long microseconds)
{return microseconds / 74 / 2;
}
long microsecondsToCentimeters(long microseconds)
{return microseconds / 29 / 2;}

What Is Electrodermal Activity?

Skin conductance, galvanic skin response, electrodermal activity: What is the phenomenon that describes how electricity is conducted across human skin? In this video, we’ll take a quick look at the history and the mechanism of electrodermal activity, how it’s used, and whether we can trust the results. If you want to know how a lie detector works, how a love tester works, or how an e-meter works, then sit down for a quick primer!

Get the Arduino code, bill of materials, and more on element14.com/presents

Check out the rest of Project Eros here

Arduino Basics Lesson 2-3: (Liquid) Crystal Ball

For the “Arduino For Kooks” course, I recommend you get the Arduino Starter Kit available here.

The Arduino, despite its simplicity, is a very powerful electronics platform and it can do so much more than blink LEDs or make noises with a buzzer. In this project, we’re going to connect a simple character LCD to the Arduino and use it to display some randomly selected custom text.

The Circuit:

Start by connecting +5V and GND to their respective busses on the breadboard. Use a jumpers to connect one side of a tactile switch to +5V and the other side to D8. Also connect a 10KR resistor to GND to act as a pull-down and prevent the pin from floating.

Connect a 10KR rotary potentiometer’s + and – pins to +5V and GND respectively while connecting the drain pin to pin 3 on the LCD. Finally, connect the LCD pins as shown in the schematic below:

The Sketch:

#include

LiquidCrystal lcd(12,11,5,4,3,2); // generates an instance in the lcd

const int switchPin = 6;
int switchState = 0;
int prevSwitchState = 0;
int reply;

void setup() {
lcd.begin(16,2);

pinMode(switchPin, INPUT);
lcd.print("I AM THE GREAT");
lcd.setCursor(0,1); // changes the Cursor to continue writing in the second row
lcd.print("ZOLDUINO");
}

void loop() {
switchState=digitalRead(switchPin);

if (switchState != prevSwitchState) {
if (switchState == LOW) {
reply = random(8);
lcd.clear(); // clears the screen
lcd.setCursor(0,1);

switch(reply){ // the program will enter the case
assigned to the switch
case 0:
lcd.print("Si");
break;
case 1:
lcd.print("It's probable");
break;
case 2:
lcd.print("It is certain");
break;
case 3:
lcd.print("Outlook good");
break;
case 4:
lcd.print("It is unclear");
break;
case 5:
lcd.print("Ask again");
break;
case 6:
lcd.print("I have no idea");
break;
case 7:
lcd.print("No");
break;
}
}
}

}

How To Build An Arduino Love Tester

I’m a bit of a sucker for retro electronic novelties, and one of the most prolific is the “love tester” device that–in various forms–hearkens back to the early 20th century and the heyday of the penny arcade. These were often an electromechanical device that used some algorithm (or even just a random number generator) to ring bells, flash lights, and indicate either a fortune or–more often–a rating of one’s romantic prowess. In the 1960s, Nintendo released their first (in what would prove to be quite a long line) of electronic toys which gave a love rating based on the electrodermal activity between two people. In this video, part of a series building a project for element14 Presents, I’ll walk through using an Arduino to replicate the Nintendo Love Tester so you can build your own meter for your Valentine.

Get the Arduino code, bill of materials, and more on element14.com/presents

Check out the rest of Project Eros here

Arduino Basics Lesson 2-2: An Energy Conversion Unit

For the “Arduino For Kooks” course, I recommend you get the Arduino Starter Kit available here.

Building on our last project, we’re going to find a new way to control our piezo buzzer. Rather than using buttons, we’re going to use the variable resistance of a photoresistor to create different tones–a sort of light-activated Theremin. A photoresistor is an element that changes resistance based on the amount of light it detects. The more light, the less resistance. This device will convert those resistance values into various tones for our Theremin.

The Circuit:

Connect a jumper wire from +5V and GND to their respective busses on the breadboard. Connect a jumper from the +5V bus rail to one side of the photoresistor. This part is not polarized, so it doesn’t matter which side. Connect the opposite side of the photoresistor to GND via a 10K resistor and to A0 via another jumper.

Connect D8 to the positive leg of the piezo via a jumper and connect the ground leg of the piezo to GND.The Sketch:


int sensorValue;
// variable to calibrate low value
int sensorLow = 1023;
// variable to calibrate high value
int sensorHigh = 0;
// LED pin
const int ledPin = 13;


void setup() {
// Make the LED pin an output and turn it on
pinMode(ledPin, OUTPUT);
digitalWrite(ledPin, HIGH);
// calibrate for the first five seconds after program runs
while (millis() < 5000) { // save the maximum sensor value sensorValue = analogRead(A0); if (sensorValue > sensorHigh) {
sensorHigh = sensorValue;
}
// save the minimum sensor value
if (sensorValue < sensorLow) {
sensorLow = sensorValue;
}
}
//turn the LED off, signaling the end of the calibration
digitalWrite(ledPin, LOW);
}


void loop() {
//read the input from A0 and store it in a variable
sensorValue=analogRead(A0);
// map the sensor values to a wide range of pitches
int pitch=map(sensorValue, sensorLow, sensorHigh, 50, 4000);
// play the tone for 20 ms on pin 8
tone(8, pitch, 20);
// wait for 10ms
delay(10);
}

1 Million Views

The Elegoo Smart Robot Car Kit 3.0

Elegoo, a manufacturer of Arduino-clone electronics and kits based in Shenzhen, China, approached me to do review their new Arduino-powered Smart Robot Car Kit. It’s a neat little kit–something fun to put together on a weekend and mess around with.

As for the meat-and-potatoes, it’s got a few bugs to work out. The car runs great with the included IR remote control, and can easily be programmed to use various sensors or just traverse pre-programmed missions (a la the classic Big Trak toy from Milton Bradley). The ultrasonic obstacle detection/avoidance mode also works like a champ. However, I couldn’t get the Bluetooth functionality working. It may be that the included Bluetooth module is not compatible with the latest versions of Android (as my cursory research and troubleshooting has led me to believe) due to updates in security protocols with Oreo and Pie. Your mileage may vary, though. Also of note was the line-tracking module which had a faulty LED and would only allow the car to spin in circles.

 

My contact at Elegoo was polite and provided me with some generic troubleshooting information, but they were unwilling to replace the faulty parts. If they’re not going to do it for the review, I would assume that they would be unwilling to do it for the consumer as well, so please take note. That being said, this is the first time that I have had as much trouble with an Elegoo-branded product, as I have used their Arduino clones and passive components in the past with no issue. I hope that this experience was a fluke, but only time will tell. I do want to emphasize that these sorts of problems can and do happen with any distributor, so it is not a mark against their quality per se.

At the end of the day, I’ll likely use these parts for some other projects (the geared motors and control boards may come in quite handy later), and have no real qualms about purchasing through Amazon as you’re protected by their returns policy (provided you purchase from the listing “fulfilled by Amazon”). So, give it a try. It’s a lot of fun to build, and makes a great transition from static Lego kits to full-fledged electronics hackery!

The Elegoo Smart Robot Car Kit 3.0 is available from Amazon

Music by Anders Enger Jensen

The Best Air Purifier: Reviewing The EnviroKlenz Mobile Air Cleaner

As much as I love living in this little slice of madness and paradise that we like to call the LA Metro Area, the air quality often leaves quite a bit to be desired. Even in Orange County, where I hang my idiomatic hat, the air quality can get pretty rough–especially during fire season. Compound that with working in an industrial environment–replete with metal, wood, and plastics works, hunched over an electronics bench huffing solder and flux fumes, and a healthy dose of good ol’ dust and solvent fumes for good measure–and one might say that I’ve got a serious air quality issue. For the sake of my own health, I need the best air purifier available.

That’s where the EnviroKlenz Mobile Air Cleaner comes into the picture.

EnviroKlenz approached me, having seen some of my other critical review videos, to put their flagship air purifier to the ultimate test. Vacuum Wars already did some seriously impressive air movement tests of the system’s German-built impeller, so I opted for a more “real world” test: I was going to pit the EnviroKlenz against the worst indoor air quality factors that 23b Shop could muster: welding, machining, grinding, 3D printing, plasma cutting, plasticizing, soldering, and every other *-ing we have the capability of performing.

After a few weeks running, I have to say that the EnviroKlenz is possibly the best air purifier that I’ve run across, and I’ve been using various models from different manufacturers regularly for nearly 20 years! This one is not only incredibly effective, but it is also incredibly quiet. It’s not silent, but it’s damn close clocking in at an impressive 58 dBA on it’s “Whisp-Air” setting. It’s so quiet that I am able to record audio with my microphone mere inches from the machine and have very little effect!

Not only does the machine run extremely quietly, it also utilizes a military-grade cocktail of minerals that were originally developed to neutralize chemical weapons to remove volatile organic compounds (those nasty little carbon chains like benzene and toluene that California is compelled to tell you may cause cancer) and the largest HEPA filter outside of a hospital that I’ve ever experienced! Is it overkill? Maybe, but I much prefer the performance of the EnviroKlenz air purifier to that of “consumer” models from Honeywell or Fellowes.

If you’re looking for the best air purifier for a small industrial space, consider the EnviroKlenz as you will not be able to beat the price for the value you receive! If you’re looking for the best air purifier for home or office, this is almost assuredly the best choice as it’s quiet and requires minimal maintenance. VOC filter cartridges typically last almost 6 months while the main HEPA filter cartridges can last up to 3 years!

Don’t just take my word for it, order the EnviroKlenz here and start breathing easier tomorrow! Use my promo code SURF10 to get 10% off your system as well! The data don’t lie: this is a phenomenal system and I’ve got some even more extreme tests lined up, so be sure to subscribe to the newsletter to get informed when those are available!

Project Rankin: A Retro-Commercial Holiday Ornament

A child of the hyper-consumerist 80s and 90s, Matt grew up on a steady diet of sugared cereal and UHF television. As such, his sense of nostalgia is driven as much by advertising trends of the era as it is by music or other sociological elements. This leads to an interesting relationship with the winter holiday season, where seasonally-themed television commercials hold as high a place in tradition as any carol, tree, or gift exchange. To celebrate this odd bit of seasonal nostalgia, Matt builds a retro-television-themed ornament from a Raspberry Pi that plays those magical commercials from his youth and is powered by a strand of holiday fairy lights!

Engage with the element14 presents team on the element14 Community – suggest builds, find project files and behind the scenes video: http://bit.ly/2MFMG0v

You’re Not Fully Clean Unless You’re Zestfully Clean! (Zest soap circa 1988)

One of those little jingles that got caught in my head as a child and creeps its way back into my consciousness every so often.