SILO 4.3 (DRAFT)

Year 4, Term 3: Sensors

Scope and sequence: Sensors

Focus: Analog to digital conversions

Learning intention: Students use microcontrollers to monitor and log data from electronic sensors.

NSW Syllabus
Australian Curriculum
“A student explains how digital systems represent data, connect together to form networks and transmit data” (ST3-11DI-T).
"Students learn to implement simple algorithms as visual programs involving control structures and input" (AC9TDI4P04).


Introduction to sensors

Electric sensors can sense changes in the physical world such as temperature, moisture and acceleration. When used in conjunction with devices such as microcontrollers, sensors can be used in various ways to interact with our surroundings.Let's begin this unit by looking at accelerometers.


Accelerometers

An accelerometer is a motion sensor. The following video (1:29) shows some examples of the micro:bit using the built-in accelerometer.




Making dice

The micro:bit has an in-built accelerometer. This means that it can be used to detect motion, including being shaken. The following code is all that is required to make a dice.




Coding a micro:bit for Rock, paper, scissors

In SILO 3.1 'Communication' we played.the game rock, paper, scissors using our hands. For this activity we will try making our own code for this game.


The following video (2:53) shows another way to code a micro:bit for rock, paper, scissors.


A screenshot of the code is below using the same icons as the screenshot above. The other difference is that you can use Buttons A or B to clear the screen in between games.



Potentiometers

Potentiometers (pots) are variable resistors. Because the resistance can be varied by turning the shaft, usually accompanied with a knob, they are often used for applications such as volume controls.


(Image source: https://en.wikipedia.org/wiki/Potentiometer#/media/File:Electronic-Component-Potentiometer.jpg)

By using the following code, the simulator will display the resistance on a scale of 0 to 1023 if you drag your cursor along Pin 0 on the bottom left-hand side.


Connect a pot to your micro:bit as follows (Image source for diagram https://www.teachwithict.com/potentiometer.html). Note: The photo shows a pot which is designed to be mounted onto a Printed Circuit Board (PCB) so there are three pins rather than rounded lugs but you can't see this through the black tape. The alligator clips had less metal to attach to so the wires have been soldered on to make it easier to use in a classroom. The wires also happened to be different colours to those in the diagram.



This volume control activity is extended in SILO 6.2 'Robotics' where the number in the readout is manipulated in various ways to behave like a more traditional volume control.


Making a simple synthesizer

Using the same cables to connect the pot to your micro:bit you can make a simple synthesizer. As you rotate the knob you will produce a continuously variable frequency using the following code:


The main concept in this unit is understanding the difference between analog and digital. The following video (7:12) titled Digital vs analog. What's the difference? Why does it matter? explains this well.


The following screenshot from the same video helps illustrate the difference between digital and analog using variations in colour. 

Sensing moisture

This video (6:43) shows how the micro:bit can be programmed to measure moisture in soil to create a water monitoring system.


You could choose to have the reading displayed continuously or when triggered by pressing a button. The example below displays the moisture level when Button A is pressed. The connections are to Pins 1 and 3V.



Data logging

https://microbit.org/get-started/user-guide/data-logging/#automatic-logging

What is data logging?


How does micro:bit data logging work?




A deeper look at types of sensors

This video by Martin Levins titled Sensors 1 (5:10) provides an excellent overview around various types of sensors.



This video by Martin Levins titled Sensors 2 (7:46) provides more details around some commons sensors and how they work.



This video by Martin Levins titled Sensors 3 (4:47) shows how sensors can be used with microcontrollers such as the micro:bit.


There are many other activities using micro:bits and sensors which you can explore at https://microbit.org/get-started/features/sensors/.


Moderated self-assessment

Discussions with students around the key components of conceptual topics and how they fit together can generate insights into student achievement.



We welcome your feedback and suggestions

The chief investigator for The SILO Project is Associate Professor Brendan Jacobs, Head of Department STEM Education, University of New England. The SILO Project thrives on incremental improvement so constructive feedback is greatly appreciated. Please contact Brendan via email at bjacobs7@une.edu.au to share your thoughts and recommendations.


 

Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License


Main menu