Constructing my hackable classroom – Part 1 #ThisIsMyClassroom

Untitled

In late 2015 I had the opportunity to sit down and design a classroom environment suited to Computer Science students. After surveying my students and getting lots of ideas (including one which resembled a living-room with C shaped sofa – tempting, I’ll admit) for what they consider would be their optimal learning environment I let the ideas stew while over in London in January for the Apple Leadership event and BETT 2016.

My interest in flexible learning environments roll way back to my time at Inverurie Academy when I worked in an open plan floor of six classrooms. I posted my first #ThisIsMyClassroom blog in May 2011 as a way of recording the changes to my classroom environment. Even at this time I was asking students about how they would like their learning environments to be arranged and remember the 3D walkthrough videos created by a great S3 class. It was truly excellent work that culminated in a video conference with Anna Rossvoll, who was at that time creating her own flexible learning environment at Hill of Banchory school in Aberdeenshire. I’ll try and find these videos and upload some of them.

Since the launch of the Raspberry Pi Computer Science teachers have had the ever-increasing opportunity to embed low-cost working models in their classrooms. While at Robert Gordon’s College I set up a separate Raspberry Pi lab (imaginatively titled PiLab) but when we moved to new classrooms in 2015 integrated the Raspberry Pis into my Computing classroom and made them part of the curriculum rather than an extra-curricular club.

I also used my experience from attending the PiCademy in Cambridge to investigate how Raspberry Pi might be used to allow students to access previously static areas of the classroom environment and bring them to life.

Perhaps the final piece of the inspiration puzzle came when I visited OnHouse Milano during last session. While primarily a showcase design home I had a great discussion with their programmers on how they use themes and scenarios to integrate a number of systems. This gave me the idea of creating Python API wrappers that allow the students to move easily access a number of hackable devices in the same program. These libraries could then easily be imported into a student’s programming environment and let them, for example, take the colour sensed by a Raspberry Pi camera and mimic it in the Phillips Hue lighting system.

I still want to keep the same classroom environment ethos as I introduce more (relatively low cost) interactive technology to the classroom – the students connect more by displaying their work. So areas of the room are set aside ready for student posters which can then be augmented using Aurasma, CodeBug projects can be displayed in a gallery area around the LAUNCH posters, the robotics created by students in extra curricular clubs are always on display. It does sound like I’m looking forward to the room becoming a slightly updated version of Eduardo Paolozzi’s studio

At this point the desks are in, the screen is in a more suitable position so that all students can view, the double whiteboards are up and the power provision in the classroom has been enhanced. There are also elements of the hackable classroom in place and the students will begin to use these as part of their lessons in the coming weeks and months

Full STEAM ahead!

Full STEAM ahead!

It’s late. I’ll not apologise for that title.

IMAG0337

After rediscovering the missing Raspberry Pi SD cards (lets put their reappearance down to pixies) I was back on track to start the STEAM club in my High School today. My colleague had already successfully started his club with younger students a few weeks before and the Kano kits, Lego Mindstorms and drones were going down a storm.

IMAG0580

Our space is a reclaimed dormitory in the top floor of the school. It currently has five desks, four Kano kits and lots of my imported Raspberry Pi goodies. The students spent today setting up their Kanos and exploring the gamified Kano OS. I did wonder if the High School students would consider the system a bit young for them, but I had no reason to worry, they loved it and spent a long time extending the python Snake Game and then coding different objects in Minecraft.

Screen Shot 2015-10-15 at 22.29.22

In the coming weeks we will begin to use TinkerCad to learn about 3D modelling and design with the intention of creating prototypes on the wonderful Ultimaker 2 3D printer and (if possible) importing some of their models into Minecraft. We are also going to visit the new Makerspace at Museo Scienza to gain inspiration for customising our own workspace. I’d like to explore WeMake too…

We would love to link with other school Makerspaces or STEAM / STEM clubs around the world. Please post your details in the comments and we’ll be in touch!

Rebuilding the PiLab

Rebuilding the PiLab

We moved into the new Science and Technology Building at our school just a few weeks ago. Since then, classes have been taught, exams have come and gone and boxes have been unpacked in between.

Over the past few days some students from my Makers and Breakers lunchtime club and I began to set up the Raspberry Pi devices in their new classroom. As we were lucky enough to have HDMI monitors in the new rooms, with on-screen controls to switch between inputs, I wanted the Pis to become permanent fixtures rather than devices hidden away in a cupboard outside of club time. We decided on two per semi circle (of three or four machines) which would always allow for at least one Windows machine for Internet access in case of troubleshooting.

IMG_5601-0

I used small Velcro coins to attach the Raspberry Pi to the top of the PC base units and then added the HDMI cable to the very tidy bundle feeding into the monitors. Numbering each case with a Sharpie to match its SD card means that students can continue their Pi experiments from lesson to lesson.

Each Pi has been given its own cat 5 cable and I intend to use a collection of recycled BT Homehubs to set up mini wired networks as and when required. The holy grail is to be granted access to the guest wifi but Python and minecraft tasks will work just as well for the moment.

The new setup removes the need for students to spend most of their club time assembling and disassembling the devices – now we can (almost) get straight to the fun!

Monitor multiple Raspberry Pi logins using PHP and MySQL

As you can see I recently bought a domain name in order to host a more customisable WordPress blog as well as build a few experiments. One of which is a quick and easy system for logging each of the Raspberry Pi devices that run my custom boot script.

I’d previously created something similar when I got my daughter’s Raspberry Pi to send a tweet whenever it booted up. That was fun but it didn’t scale easily when used with multiple devices. I wanted a central list where all devices were displayed in boot order.

I decided to create a simple MySQL database that could be queried via PHP. The database would contain information sent to it by each Raspberry Pi as it connected to the Internet. I decided initially that I only required device name, username and a timestamp.

I had thought that each Raspberry Pi could run a Python program that opened a connection to the MySQLi database but this appears to be the wrong approach. It seemed much easier to create PHP code that wrote a line to the database using values pulled from the URL (using the $_GET command).

In case it helps, here is some of the PHP to add information to the database:


$sql = "INSERT INTO pilogin (piname, timestamp, username) VALUES ('" . $_GET['piname']."', now(), '" . $_GET['username']."')";

if ($conn->query($sql) === TRUE) {
echo "New record created successfully";
} else {
echo "Error: " . $sql . "
" . $conn->error;
}
$conn->close();

The final step was to edit /etc/rc.local so that it ran cURL with the appropriate web address and values. I wanted to delay the command until the network connection setup was complete and found that this forum post had a great suggestion for doing this while also allowing other programs to continue running.

I won’t post the actual line for obvious reasons but a similar solution. I’ve also included code that extracts the current Raspberry Pi hostname and user and encodes it into the URL.

Here is an extract from my /etc/rc.local file:

u="$USER" # system variable for user
h=hostname #note the backticks
(sleep 30s; curl "http://webaddress/page.php?hostname=$h&user=$u") &

Happy to hear of any improvements or alternatives!

#CASAberdeen Raspberry Pi computers

20130624-202823.jpg

It has been a while since I’ve written here, but I feel like I’ve never stopped writing emails recently! I’m currently leading Computing at School’s Aberdeen hub and we’ve recently taken delivery of 15 Raspberry Pi computers courtesy of a grant from Google Giving. I wanted to publish my email to existing members of the hub in the hope that other educators in the local area (Aberdeen, Aberdeenshire, Angus) might pass this information on to Computing teachers in their establishment. Thanks to those folk in advance!

Dear CAS Aberdeen members,

Schools around the UK have been given free Raspberry Pi computers, to help create a new generation of computer scientists. Funded by a grant from Google Giving, both CAS and the Raspberry Pi Foundation hope that these devices will help children to take up coding.

The CAS Aberdeen hub have been given 15 sets to distribute to students or extra-curricular groups in the hub area.

The sets include the following:
– Raspberry Pi in clear perspex case
– 4GB SD card with NOOBS Raspberry Pi image
– Power adapter
– Getting started with your Raspberry Pi guide
– Issue 9 of MagPi magazine

I propose to loan out each set from September to December in the first instance. Preference will be given to bids from schools which do not currently have access to a Raspberry Pi device, but all education establishments which support primary or secondary school aged children are welcome to apply.

I am now looking for members of CAS Aberdeen to form a small group which will approve bids for the 15 sets as well as take responsibility for liaising with 2 or 3 successful bidders per group member during the loan duration.

If you would be interested in being part of this bidding group please let me know by return. I will send out a follow up email giving details of the bid process once I have four or five volunteers. My aim is to have this group up and running before the summer holidays so that we can have the Raspberry Pi sets in the hands of successful bidders at the next CAS Aberdeen meeting in September (which will be dedicated to Raspberry Pi CPD, thanks Matthew!).