What are automated systems and how might they work?
A sensor light is an automated system. How might that work? Consider how a computer program is used to automate the system. What data does the system require? How would it use this data in a computer program?
In this series of tasks, students will use and develop some important programming skills that relate to controlling an automated system.
For students who have only just started learning to program with general purpose programming and are unfamiliar with programming Arduinos, consider adapting the PRIMM approach to programming (Sentance, 2017) for this project.
Figure 2a: Hardware for LED circuit
Figure 2b: Constructing the circuit
Figure 3: Student comments on code show understanding of the program
Originally it was planned to present the design challenge to the students in the first lesson, but then it was decided that students needed an idea of what Arduino is, and can do, so they could keep that in mind when brainstorming ideas. Considering materials is part of the investigating and defining phase of the design process (Albion Campbell & Jobling, 2018). Using the PRIM part of PRIMM (Sentance, 2017) was successful, and definitely an approach that will be used again. Student program annotations were a relatively quick, flexible formative assessment tool that could be completed as a whole class, individually, verbally or in writing.
Figure 4: Hot bots technology challenge brief
Present students with the Hot bots challenge (Figure 4) and ask them to brainstorm as many ideas as possible. Sample ideas students might come up with include:
Figure 5. Student examples
Giving students five minutes to silently and individually brainstorm in a written or pictorial format, before seeing what their peers had done, ensured every student had to contribute and not leave the thinking to others. Differentiation in how they could record their thoughts, suited student preferences for writing, drawing or using diagrams.
Provide time for students to explore other activities in the Arduino kit, including buzzers and the temperature sensor to aid in the development of their skills in assembling and programming Arduino, and to assist in refining their thinking about their proposed solution.
Sometimes if students copied and pasted code, a ‘stray 304’ error would appear and the code would not compile. Undertaking an internet search for this issue found that it was caused by hidden characters (see Figure 7) in the copied code. Using ‘Tools>Fix encoding & reload’ highlighted the characters for deletion, or typing code into the IDE, instead of copying and pasting, solved this issue. Students added to their electronics knowledge, learning about temperature sensors and how they have three pins – power, voltage output and ground – and how to identify which is which.
Figure 6: Stray 304 errors
Being open with students about Arduino being a new learning experience for the teacher, as well as the students, led to a collaborative learning atmosphere, with students enjoying solving problems (such as debugging sample code errors) alongside the teacher. Teacher expertise can indeed grow when they learn alongside their students! (Kelly, 2006). For example, the teacher learnt about temperature sensors and the (intense!) heat they create if connected the wrong way round and could remind the students about the importance of polarity!
Discuss with students the two different ways of designing algorithms: pseudocode and flowchart.
Ask students to articulate their idea of how the Arduino would be controlled by using their choice of a flowchart or pseudocode. Compare this approach with jumping straight into programming.
Figure 7: Flowchart
Because the Arduino was completely new to students, it was important that other tasks such as flowcharts and concepts of branching and decision-making had been previously introduced to students. This would mean the project was not overwhelming for less confident students. Giving students a choice of flowcharts, pseudocode or code suited individual abilities (and temperaments!).
Figure 9b: Hot bot program
Use these prompts to guide and support student self-reflection and self-assessment.
Hot bot student reflection prompts:
The temperature sensor could be used in future projects requiring measurement of ambient temperatures in different locations around the school, such as different classrooms or the garden hothouses, and be programmed to give readings at different time intervals.
Students can use the data to make predictions, publish it to the cloud, or display it on an app or with an LED light display.
Other project ideas could involve making: