Author Archives: Bobby Chan

Wireless Remote Weather Station with micro:bit

via SparkFun: Commerce Blog

Did you install your micro:climate kit in a remote, hard-to-reach location and need to pull weather data easily from the comfort of your own home? Or, maybe you want to add a timestamp. With the radio blocks, a second micro:bit and the gator:RTC, you can obtain these readings wirelessly with ease.

Check out the tutorial to add additional functionality to your micro:climate kit!

New!

Wireless Remote Weather Station with micro:bit

May 11, 2020

Monitor the weather without being exposed to it through wireless communication between two micro:bits using the radio blocks! This is useful if your weather station is installed in a location that is difficult to retrieve data from the OpenLog. We will also explore a few different ways to send and receive data.

comments | comment feed

Raspberry Pi Safe Reboot and Shutdown Button

via SparkFun: Commerce Blog

Pulling the plug on your Raspberry Pi before it safely shuts down... is a bad idea! This can result in a corrupt microSD card and file system. Normally, we can use the menu bar from the GUI or type a command in the terminal window to safely shutdown the Pi.

If you are looking for a quicker solution (especially if you are using a headless setup), have no fear! You can safely turn your Raspberry Pi off using a general purpose button and a Python script! We use this ability with the Pi AVR Programmer HAT in production after programming and testing certain boards. For more information, check out the tutorial below!

New!

Raspberry Pi Safe Reboot and Shutdown Button

April 20, 2020

Safely reboot or shutdown your Raspberry Pi to avoid corrupting the microSD card using the built-in general purpose button on the Qwiic pHAT v2.0!

comments | comment feed

Enginursday: A Qwiic Comparison of Temperature Sensors

via SparkFun: Commerce Blog

It all started when I wanted to measure the ambient temperature of a room at SparkFun. But what is the best option? Well, it depends on what you are looking for in your project. Let's compare three temperature sensors from the SparkFun catalog!

Temperature Sensor - TMP36

Temperature Sensor - TMP36

SEN-10988
$1.50
16
SparkFun Digital Temperature Sensor Breakout - TMP102

SparkFun Digital Temperature Sensor Breakout - TMP102

SEN-13314
$5.95
4
SparkFun High Precision Temperature Sensor - TMP117 (Qwiic)

SparkFun High Precision Temperature Sensor - TMP117 (Qwiic)

SEN-15805
$13.95
1

My initial choice was to grab the TMP36 from my parts kit. It only required three connections and an analog pin. However, after viewing the output, I noticed a majority of the time that the temperature would jump 1°F to 2°F. At other times, the value would spike. Unsatisfied, I placed the project off to the side as this would require a bit more planning to average the values and add additional parts in order to throw out the errors.

TMP36 Output on the Arduino Serial Plotter

Click image for a closer view.

The project sat there on my desk for a bit until I noticed the TMP117 high precision digital temperature sensor in the catalog. I thought it would be a good opportunity to revive the project and see if I could obtain more stable readings using a different temperature sensor. I decided to compare the TMP36 against the TMP102 and TMP117. I wrote some code [1] to output the readings to the Arduino Serial Plotter.

Looking at the TMP102, it performed better than the TMP36 when measuring the ambient temperature of the room. The temperature readings remained stable and it was not as noisy. The temperature readings for the TMP117 performed better than the TMP102 and TMP36. The data points were more smooth and less prone to noise.

TMP117 vs TMP102 vs TMP36

Click image for a closer view.

Good, Better, Best?

So, you might ask, which of the three temperature sensors is the best? Well, that really depends on how you plan to use it. In my opinion, the Qwiic TMP117 is a winner. The sensors performed as expected when looking at the datasheet. The board did not require any soldering. There was no additional circuitry or code needed to average the temperature sensor readings. The power supply did not cause as much of a fluctuation with the digital temperature sensors like it did with the analog temperature sensor.

The TMP102 could work as well if I was not looking for such a precise temperature reading. While it is not as expensive as the TMP117, it does require some soldering for this version of the TMP102 board. The TMP36 is good but it would require a bit more effort to filter out the errors.


What is your favorite temperature sensor to work with in your projects? Until next time - I'm off to build my digital indoor thermometer!

comments | comment feed

Enginursday: Non-Addressable RGB LEDs

via SparkFun: Commerce Blog

I recently wrote a tutorial on how to connect and control non-addressable RGB LED strips. Non-addressable (a.k.a. analog) LED strips can only have one color turned on at a time over the entire strip. However, they are lower cost and are easier to use compared to their digital counterparts. Since these can be powered at 12V, daisy chained strips do not require power to be injected as often as the 5V.

Non-addressable LED Strip Powered

While you could just apply straight power to the non-addressable LED strips, you are limited to seven colors. You would also would need to adjust the connection every time you need to change the color. Using a microcontroller with PWM pins and a few power transistors enables you to be more flexible with your color options, adjust the brightness and include basic animations.

For more information, check out the tutorial linked below.

New!

Non-Addressable RGB LED Strip Hookup Guide

February 19, 2020

Add color to your projects with non-addressable LED strips! These are perfect if you want to control and power the entire strip with one color for your props, car, fish tank, room, wall, or perhaps under cabinet lighting in your home.

Happy blinking! ^_^

comments | comment feed

Enginursday: Light Painting with EL Wire and an LED

via SparkFun: Commerce Blog

My original goal was to wirelessly control each of my student's suits to the beat during their performance way back in 2017. Shortly after their performance, I decided to document the project with a photoshoot. Everything was going according to plan until I wanted the photographer to highlight the glow from EL Wire. It was a bit harder to capture with a camera, since EL wire is not as bright as the non-addressable LEDs that were used in previous builds. We decided to try to take a few pictures in the dark. After removing the spotlight on the kids, the photographer tweaked a few camera settings on his DSLR.

As you can see in the images below, EL wire is hard to see when there are other light sources in the room. Removing the additional light source will make it easier to see and capture the EL Wire's glow on camera.

EL Hoodie and Pants Worn on Dancers in Front of a Spot Light EL Hoodie and Pants Worn on Dancers in the Dark
EL Wire in the Light EL Wire in the Dark

Briefly reviewing a few photos, we had an unintended effect during their photoshoot! The images coming from the light sources started to trail whenever the kids moved around. It was not on my mind until that moment but I thought it was cool opportunity to try a little light painting [1] with EL Wire and the wireless controller's LED.

Long Exposure with Kids Not Holding Freeze

Two dancers circled in red - they're blurry because of movement

Dancing in the Dark

After an hour-long photoshoot and taking several pictures, we got some pretty cool shots. We experimented with no movement, slow/fast movements, and then a combination of both. The main settings that he tweaked manually as his Canon EOS 6D stood on a tripod were:

  • ISO
  • aperture (i.e. F-Stop)
  • shutter speed (exposure time)

Check out the pictures with some of their camera settings below. Note that these settings will depend on your camera's image sensor and brightness of the light source(s).

Photo ISO F-Stop Exposure Time
EL Wire on Dancers in the Dark 1250 f/4 2 seconds
EL Wire on Dancers with Some Movement in the Dark 1250 f/4 2 seconds
EL Wire on Dancers with a Lot of Movement in the Dark 1250 f/4 3.2 seconds
EL Wire on Dancers with One Dancer Moving Quickly in the Dark 3200 f/4 3.2 seconds
EL Wire on Dancers with One Dancer Moving Quickly in the Dark 3200 f/4 3.2 seconds
EL Wire on Dancers with One Dancer Moving Quickly in the Dark 3200 f/5 10 seconds
EL Wire on Dancers with One Dancer Moving Quickly in the Dark 3200 f/5 15 seconds
Photographs Courtesy of Jesse Rarick

A few these were a bit difficult to capture since a majority of the pictures required the kids to hold a pose for more than a second, which is hard since they are kids. This caused them to be appear ghostly and blurry for the longer exposed shots whenever they were not supposed to move. Overall, it was not too bad for our first time trying to light paint with a photographer.

Have you tried creating a light painting using EL Wire or LEDs? If so, what do you prefer? Feel free to share your light paintings and let us know your thoughts below in the comments.

comments | comment feed

Updated micro:bot Kit Experiment Guide!

via SparkFun: Commerce Blog

Based on your feedback, we have updated the micro:bot kit experiment guide!

Optimum Distance Between Line Following Sensor and Surface


You'll find updated code for experiments two and three with an option to output serial data to the MakeCode Console. This is useful when you need to debug and interpret sensor readings when using a line following sensor(s) on different surfaces. If you choose to view the serial output, we include a few highlighted graphs to explain what is going on on different surfaces.

Output Highlighted on a White Table, Brown Cardboard, and Black Electrical Tape with the Motor Turned On Serial Output Highlighted Three Different Surfaces with Two Line Following Sensors
Output Highlighted using One Line Following Sensor Serial Output Highlighted using Two Line Following Sensors

Experiment three is now broken up into two parts. We'll try to follow a straight line made from black electrical tape and stop when we fail to see it. Then we'll attempt to follow a simple polygon track.

Line Following Robot with Sharp Turns

If you have not gotten a kit yet, make sure to get one today! Otherwise, be sure to check out the updates in the micro:bot kit experiment guide!

micro:bot Kit Experiment Guide

July 21, 2017

Get started with the moto:bit, a carrier board for the micro:bit that allows you to control motors, and create your own robot using this experiment guide for the micro:bot kit.

Looking for more tutorials related to micro:bit? Check out our tutorials tagged with micro:bit to add more functionality to your micro:bit projects!

comments | comment feed