Welcome to part 2 of our STEAMy summer blog series. In part 1, we talked about the resources available for parents and kids to explore STEAM (science, technology, engineering, art, and mathematics) topics so that they can develop hands-on embedded electronics skills through project-based learning. This time let’s dive in and design and code a specific project. Don’t feel obligated to use this project exactly as described, but rather use it as a starting point for your imagination and to help explain the engineering process to your budding engineer-in-training.
Though the fall season is near, many of us will miss the summer because it is a season that means long days and outdoor fun under the sunshine. This barrage of sunlight can be both a blessing and curse. While it lets us play outside for longer periods of time, it can also cause nasty side effects, such as sunburns or (in the worst case) skin cancer, if we’re exposed to too much of the sun’s ultraviolet (UV) radiation.
In the warm to hot months of spring and summer, applying sunblock regularly and taking breaks in the shade can help reduce the risks, though remembering to do so in the midst of vacations or leisurely frolicking can be a challenge, especially for kids. In the fall and winter, similar practices are important in environments experiencing consistent sunshine during the day.
However, what if we could monitor our UV exposure and trigger a reminder when it becomes essential to take safety precautions? This is what we will explore in this project. But first, let’s discuss the science!
Visible light, the light our eyes can see, occupies a very small frequency band relative to the larger electromagnetic spectrum. It is flanked by radio waves at the extreme lower frequencies and gamma rays at the extreme higher frequencies. Sitting just above the frequencies our eyes can see is UV light. UV light has wavelengths that range from 180 to 400nm. That roughly translates to frequencies ranging from 3x1016 down to 8x1014Hz. UV light is further broken down into three bands:
UVA and, more so, UVB are the frequencies of concern from a health perspective. UVC is absorbed by the atmosphere and is not as much of a concern. The factors that contribute to the health risks related to UV exposure include these points from the American Cancer Society’s list:
The UV Index is a numerical way to convey to people the risk of UV exposure for a given location and time (Table 1). The index consists of the following increments:
Table 1: The UV index indicates risk using a numerical system.
0.0 to 2.9
3.0 to 5.9
6.0 to 7.0
8.0 to 10.0
11.0 or greater
Checking the UV index as part of your daily weather update can help you prepare to take necessary precautions such as limiting your time outdoors and applying adequate sunscreen to exposed skin.
We now know a little more about why UV radiation can be dangerous. Reducing the time of UV exposure and ensuring that sunscreen is consistently applied is key to staying safe under the sun. With this in mind, let’s flesh out some of the requirements and actions to apply during this project:
For this project, we will establish the following alert intervals (Table 2), take a reading every minute, and keep a running average of the UV index. If the average exceeds these levels in a given period of time, it should trigger an alert.
Table 2: This UV Index table shows the alert intervals for our project.
Low or moderate
High or very high
Using the requirements we have listed, we can start making some design assumptions at a very high functional level. For this design, let’s assume that the following five functional blocks will be necessary to meet our requirements:
Now that we have identified a high-level architecture for your project, let the real fun begin. First, go to Mouser.com and start searching for parts that meet the needs for this project and that can be incorporated into your circuit design. To help you get started, here are some parts Mouser suggests for this project:
Silicon Labs produces an integrated circuit, which can function as a UV light sensor. The Si1145 provides a convenient I2C serial interface that can trigger telemetry to a microcontroller for further analysis and action. Mouser stocks the Adafruit 485-1777, a breakout board (BOB) that utilizes the Si1145 to make the UV monitor breadboard friendly. Conveniently, this BOB contains level shifters that allow it to operate with both 3.3 and 5V embedded platforms.
For this project, we can leverage the Arduino MKR1000 embedded development platform to serve as the brains and to provide a Wi-Fi connection to cloud-based storage. The board also utilizes a JST connector that allows the board to receive power by a single-cell, 3.7V, lithium polymer (Li-Po) battery with a minimal rating of 700mAh.
Consolidating multiple functions into a single component is a double-edged sword. On one hand, it reduces your part count, and there is less troubleshooting, as we can assume all onboard components have undergone tests by the manufacturer. On the flip side, if (for example) you wish to use Bluetooth instead of Wi-Fi for communications, then you will also need to consider how this change will impact the data processing and power functions. Engineering trade-offs are always a reality when designing a product. This is a simple example, but you can imagine that the issues will scale as the component count and complexity in the requirements increase.
Another thing to consider is that the MKR1000 operates at 3.3V, whereas as many other development boards (especially those not purpose-built for battery or mobile applications) tend to run at 5V. If you do modify the design to include different components, ensure that they are 3.3V compatible.
The user interface will include both output from the system to the user as well as input from the user to the system. The output will serve as a UV threshold alert to notify the user that the threshold has been reached. The input will be a way to let the user acknowledge the alert and reset the system.
For the alert, a piezoelectric buzzer will definitely grab the attention of whomever is nearby. The buzzer of choice is the PS1240P02BT from TDK Corporation, since it operates at 3V. A resistor and transistor are also necessary to enhance the power of the buzzer and ensure that it drives enough current to make the buzz noticeable.
To reset the device once an alert is triggered, you can use a normally open (NO) momentary pushbutton. A pull-down resistor will serve to ground the button that is wired to the microcontroller general-purpose input/output (GPIO) pin to prevent any floating input (Figure 1).
Figure 1: The resulting circuit for the project will look like this. (Source: Author)
After putting everything together, the final circuit is complete, as shown above. In summary, the bill of materials (BOM) for this project is listed in Table 3:
Table 3: This is the BOM for our UV monitor and alert project.
Optical Sensor Development Tools Digital UV Index/IR/Visible Light Sensor
Wi-Fi Development Tools (802.11) MKR1000 with headers
Adafruit Accessories Lithium Ion Polymer Battery 3.7V 2500mAh
Audio Indicators & Alerts Round 12.2mmx6.5mm 4kHz VIN=3V
Pushbutton Switches 0-2A 48VDC Off (On) 12mm Black Domed
Bipolar Transistors - BJT NPN Transistor General Purpose
Carbon Composition Resistors 1kΩ 1/4W 250V
Carbon Composition Resistors 10kΩ 1/4W 250V
You can click here to add all these parts to your Mouser shopping cart. Remember to check back for the final article in this blog series, where we will show you how to wire the circuit and write the code.
That’s it for now, but remember to check back for part 3 when we will go through each step to build the circuit and program the Arduino MKR1000 for your ultraviolet (UV) monitor and alert project so that you and your young, aspiring engineer can protect your family when you’re out enjoying the sun.
Michael Parks, P.E. is the owner of Green Shoe Garage, a custom electronics design studio and technology consultancy located in Southern Maryland. He produces the S.T.E.A.M. Power podcast to help raise public awareness of technical and scientific matters. Michael is also a licensed Professional Engineer in the state of Maryland and holds a Master’s degree in systems engineering from Johns Hopkins University.
Privacy Centre |
Terms and Conditions
Copyright ©2022 Mouser Electronics, Inc.
Mouser® and Mouser Electronics® are trademarks of Mouser Electronics, Inc. in the U.S. and/or other countries.
All other trademarks are the property of their respective owners.
Corporate headquarters and logistics centre in Mansfield, Texas USA.