Lateo.net - Flux RSS en pagaille (pour en ajouter : @ moi)

🔒
❌ À propos de FreshRSS
Il y a de nouveaux articles disponibles, cliquez pour rafraîchir la page.
À partir d’avant-hierRaspberry Pi

Raspberry fish & RP2040 chip


Look at our lovely friends over at This is not Rocket Science (TiNRS) – they’ve wasted no time at all in jumping in with our new chips. In this guest post, Stijn of TiNRS shares their fishily musical application of our new toy.

The new RP2040 chip by Raspberry Pi is amazing. When we got our hands on this beautiful little thing, we did what we always do with new chips and slapped on a Goldfish, our favourite acid bassline synthesiser (we make fish and chips, hahahaha).

TiNRS took to Instagram to explain more about the 18 year old fish synthesiser project

While benchmarking the performance by copy/pasting instances of our entire Goldfish in search of the chip’s limits, we suddenly found ourselves with a polyphonic synth. We have since rewritten these multiple instances into a 16-voice Poly-Goldfish with 4 oscillators per voice. To celebrate we designed a PCB and brightly coloured frontpanel to give this new Goldfish some dedicated controls.

Bring-up was trivial due to the amazing documentation and the extremely flexible PIO-blocks. RP2040 is a dream to work with. Childlike giddiness ensued while lying on the carpet and programming in VSCode on a Raspberry Pi 400 talking directly to the RP2040. This is the way to release a chip into the world: with fantastic documentation, an open toolchain and plenty of examples of how to use everything.

PCB and brightly coloured front panel

Once these chips hit general availability we will probably share some designs on our Github. This chip is now part of our go-to set of tools to make cool stuff and will very bloody likely be inside our next three modules.

It fits perfectly in our Open Source attitude. Because of the easy, high quality, multi-platform, free and even beginner-friendly toolchain they have built around this chip, we can expand the accessibility to the insides of our designs. With these chips it is way easier for us to have you do things like adding your own algorithms, building extra modes or creating personal effects. We can lean on the quality of the Raspberry Pi platform and this amazing chip.

TiNRS approves.

Keep an eye on the TiNR blog for more adventures in technology. You can also find them on Twitter @rocket_not and on Instagram.

The post Raspberry fish & RP2040 chip appeared first on Raspberry Pi.

New book: Get Started with MicroPython on Raspberry Pi Pico

Par : Phil King

So, you’ve got a brand new Raspberry Pi Pico and want to know how to get started with this tiny but powerful microcontroller? We’ve got just the book for you.

Get Started with Raspberry Pi Pico book

Beginner-friendly

In Get Started with MicroPython on Raspberry Pi Pico, you’ll learn how to use the beginner-friendly language MicroPython to write programs and connect hardware to make your Raspberry Pi Pico interact with the world around it. Using these skills, you can create your own electro-mechanical projects, whether for fun or to make your life easier.

Inside the pages of the Raspberry Pi Pico book

After taking you on a guided tour of Pico, the books shows you how to get it up and running with a step-by-step illustrated guide to soldering pin headers to the board and installing the MicroPython firmware via a computer.

Programming basics

Inside the pages of the Raspberry Pi Pico book 02

Next, we take you through the basics of programming in MicroPython, a Python-based programming language developed specifically for microcontrollers such as Pico. From there, we explore the wonderful world of physical computing and connect a variety of electronic components to Pico using a breadboard. Controlling LEDs and reading input from push buttons, you’ll start by creating a pedestrian crossing simulation, before moving on to projects such as a reaction game, burglar alarm, temperature gauge, and data logger.

Inside the pages of the Raspberry Pi Pico book

Raspberry Pi Pico also supports the I2C and SPI protocols for communicating with devices, which we explore by connecting it up to an LCD display. You can even use MicroPython to take advantage of one of Pico’s most powerful features, Programmable I/O (PIO), which we explore by controlling NeoPixel LED strips.

Get your copy today!

You can buy Get Started with MicroPython on Raspberry Pi Pico now really soon, the moment the second print edition is available, from the Raspberry Pi Press online store. If you don’t need the lovely new book, with its new-book smell, in your hands in real life, you can download a PDF version for free (or a small voluntary contribution).

STOP PRESS: we’ve spotted an error in the first print run of the book, affecting the code examples in Chapters 4 to 7. We’re sorry! Fortunately it’s easy for readers to correct in their own code; see here for everything you need to know.

We’ve corrected this in the PDF version, and we’re producing a corrected second print edition, which will be on sale soon.

What if I already bought a copy?

If you bought the first print edition from the Raspberry Pi Press Store or one of our fantastic Raspberry Pi Approved Resellers, a copy of the second edition will be on its way to you free of charge as soon as it’s available.

The post New book: Get Started with MicroPython on Raspberry Pi Pico appeared first on Raspberry Pi.

Raspberry Pi Pico – what did you think?

The best part of launching a new product is seeing the reaction of the Raspberry Pi community. When we released Raspberry Pi Pico into the world last Thursday, it didn’t take long for our curious, creative crew of hackers and tinkerers to share some brilliant videos, blogs and photos.

If you’ve spotted other cool stuff people have done with Raspberry Pi Pico, do comment with a link at the end of this post so we can check it out.

Graham Sanderson’s BBC Micro emulation

YouTube went wild for this Raspberry Pi Pico-powered BBC Micro and BBC Master emulation. Graham Sanderson‘s little bit of fun with our latest creation emulates the fine detail of the hardware required to get the best games and graphics demos to run.

He’s put together an entire playlist showing off the power of Raspberry Pi Pico, and it’s a retro gamer’s dream.

Alex Glow

Alex Glow went live for almost an hour unboxing our teeny tiny microcontroller, deep-diving into our getting started materials as well.

She has a good look around our launch blog post on camera too, unpacking some of the technical aspects of how Raspberry Pi Pico is powered, and also explaining why it’s so exciting that we’ve built this ourselves.

Jeff Geerling

Jeff Geerling has used his Pico for good, creating a baby-safe temperature monitor for his little one’s bedroom. In his video, he shows you around some of Raspberry Pi Pico’s “party tricks”, and includes the all-important build montage sequence.

If you prefer words to videos, Jeff has also put together a big ole blog post about our new microcontroller board.

Brian Corteil

Can not believe how popular this tweet has been nearly 100,000 impressions, 777 likes! Oh 😳 as pointed out by Sarah, Tom is 11 not 10. https://t.co/vpFYa1snoo

— Brian Corteil 🤖 (@CannonFodder) January 25, 2021

Brian Corteil took to Twitter to share his eleven-year-old’s pro soldering skills, proving that Raspberry Pi is for everyone, no matter how young, old, or inexperienced, or expert.

Extreme close-up!

Look at the finish on those pins!

16MB Pico modification

Daniel Green did what you were all thinking – desoldered the onboard 2MB QSPI flash chip and replaced it with a 16MB version. Say hello to the first Pico in the world with this special modification. 

Eben himself!

On top of all the brilliant comments, projects, and guidance our community has already shared, Raspberry Pi CEO Eben Upton will be joining the Digital Making at Home crew on Wednesday to show young coders around Raspberry Pi Pico.

Set a reminder for yourself (or your kids) to watch live on YouTube, or join in on Facebook, Twitter or Twitch at 7pm UK time.

The post Raspberry Pi Pico – what did you think? appeared first on Raspberry Pi.

NeoPixel dithering with Pico

In the extra special Raspberry Pi Pico launch issue of HackSpace magazine, editor Ben Everard shows you how to get extra levels of brightness out of your LEDs with our new board.

WS2812B LEDs, commonly known as NeoPixels, are cheap and widely available LEDs. They have red, green, and blue LEDs in a single package with a microcontroller that lets you control a whole string of them using just one pin on your microcontroller.

The three connections may be in a different order on your LED strip, so check the labels to make sure they’re connected correctly
The three connections may be in a different order on your LED strip, so check the labels to make sure they’re connected correctly

However, they do have a couple of disadvantages:

1) The protocol needed to control them is timing-dependent and often has to be bit-banged.

2) Each colour has 8 bits, so has 255 levels of brightness. However, these aren’t gamma-corrected, so the low levels of brightness have large steps between them. For small projects, we often find ourselves only using the lower levels of brightness, so often only have 10 or 20 usable levels of brightness.

There will usually be wires already connected to your strip, but if you cut it, you’ll need to solder new wires on
There will usually be wires already connected to your strip, but if you cut it, you’ll need to solder new wires on

We’re going to look at how two features of Pico help solve these problems. Firstly, Programmable I/O (PIO) lets us implement the control protocol on a state machine rather than the main processing cores. This means that we don’t have to dedicate any processor time to sending the data out. Secondly, having two cores means we can use one of the processing cores to dither the NeoPixels. This means shift them rapidly between different brightness levels to make pseudo-levels of brightness.

For example, if we wanted a brightness level halfway between levels 3 and 4, we’d flick the brightness back and forth between 3 and 4. If we can do this fast enough, our eyes blur this into a single brightness level and we don’t see the flicker. By varying the amount of time at levels 3 and 4, we can make many virtual levels of brightness. While one core is doing this, we still have a processing core completely free to manipulate the data we want to display.

First, we’ll need a PIO program to communicate with the WS2812B LEDs. The Pico development team have provided an example PIO program to work with – you can see the full details here, but we’ll cover the essentials here. The PIO code is:

.program ws2812
.side_set 1
.define public T1 2
.define public T2 5
.define public T3 3
bitloop:
    out x, 1.      side 0 [T3 - 1]
    jmp !x do_zero side 1 [T1 - 1]
 do_one:
 jmp bitloop       side 1 [T2 - 1]
 do_zero:
 nop               side 0 [T2 - 1]

We looked at the PIO syntax in the main cover feature, but it’s basically an assembly language for the PIO state machine. The WS2812B protocol uses pulses at a rate of 800kHz, but the length of the pulse determines if a 1 or a 0 is being sent. This code uses jumps to move through the loop to set the timings depending on whether the bit (stored in the register x) is 0 or 1. The T1, T2, and T3 variables hold the timings, so are used to calculate the delays (with 1 taken off as the instruction itself takes one clock cycle). There’s also a section in the pio file that links the PIO code and the C code:

% c-sdk {
#include "hardware/clocks.h"

static inline void ws2812_program_init(PIO pio,
uint sm, uint offset, uint pin, float freq, bool
rgbw) {

    pio_gpio_select(pio, pin);
    pio_sm_set_consecutive_pindirs(pio, sm, pin, 1,
true);
    pio_sm_config c = ws2812_program_get_default_
config(offset);
     sm_config_set_sideset_pins(&c, pin);
     sm_config_set_out_shift(&c, false, true, rgbw ?
32 : 24);
    sm_config_set_fifo_join(&c, PIO_FIFO_JOIN_TX);
 
    int cycles_per_bit = ws2812_T1 + ws2812_T2 +
ws2812_T3;
    float div = clock_get_hz(clk_sys) / (freq *
cycles_per_bit);

    sm_config_set_clkdiv(&c, div);
    pio_sm_init(pio, sm, offset, &c);
 
    pio_sm_set_enable(pio, sm, true);
}
%}

Most of this is setting the various PIO options – the full range is detailed in the Raspberry Pi Pico C/C++ SDK document.

 sm_config_set_out_shift(&c, false, true, rgbw ? 32
: 24);

This line sets up the output shift register which holds each 32 bits of data before it’s moved bit by bit into the PIO state machine. The parameters are the config (that we’re setting up and will use to initialise the state machine); a Boolean value for shifting right or left (false being left); and a Boolean value for autopull which we have set to true. This means that whenever the output shift register falls below a certain threshold (set in the next parameter), the PIO will automatically pull in the next 32 bits of data.

Using a text editor with programmer’s features such as syntax highlighting will make the job a lot easier
Using a text editor with programmer’s features such as syntax highlighting will make the job a lot easier

The final parameter is set using the expression rgbw ? 32 : 24. This means that if the variable rgbw is true, the value 32 is passed, otherwise 24 is passed. The rbgw variable is passed into this function when we create the PIO program from our C program and is used to specify whether we’re using an LED strip with four LEDs in each (using one red, one green, one blue, and one white) or three (red, green, and blue).

The PIO hardware works on 32-bit words, so each chunk of data we write with the values we want to send to the LEDs has to be 32 bits long. However, if we’re using RGB LED strips, we actually want to work in 24-bit lengths. By setting autopull to 24, we still pull in 32 bits each time, but once 24 bits have been read, another 32 bits are pulled in which overwrite the remaining 8 bits.

sm_config_set_fifo_join(&c, PIO_FIFO_JOIN_TX);

Each state machine has two four-word FIFOs attached to it. These can be used for one going in and one coming out. However, as we only have data going into our state machine, we can join them together to form a single eight-word FIFO using the above line. This gives us a small buffer of time to write data to in order to avoid the state machine running out of data and execution stalling. The following three lines are used to set the speed the state machine runs at:

int cycles_per_bit = ws2812_T1 + ws2812_T2 +
ws2812_T3;
    float div = clock_get_hz(clk_sys) / (freq *
cycles_per_bit);
   sm_config_clkdiv(&c, div);

The WS2812B protocol demands that data is sent out at a rate of 800kHz. However, each bit of data requires a number of state machine cycles. In this case, they’re defined in the variables T1, T2, and T3. If you look back at the original PIO program, you’ll see that these are used in the delays (always with 1 taken off the value because the initial instruction takes one cycle before the delay kicks in). Every loop of the PIO program will take T1 + T2 + T3 cycles. We use these values to calculate the speed we want the state machine to run at, and from there we can work out the divider we need to slow the system clock down to the right speed for the state machine. The final two lines just initialise and enable the state machine.

The main processor

That’s the code that’s running on the state machine, so let’s now look at the code that’s running on our main processor cores. The full code is on github. Let’s first look at the code running on the second core (we’ll look at how to start this code running shortly), as this controls the light levels of the LEDs.

int bit_depth=12; 
const int PIN_TX = 0;

uint pixels[STRING_LEN]; 
uint errors[STRING_LEN];
 
static inline void put_pixel(uint32_t pixel_grb) {
    pio_sm_put_blocking(pio0, 0, pixel_grb << 8u);
}
static inline uint32_t urgb_u32(uint8_t r, uint8_t
g, uint8_t b) {
    return
            ((uint32_t) (r) << 8) |
            ((uint32_t) (g) << 16) |
            (uint32_t) (b);
}
void ws2812b_core() {
   int valuer, valueg, valueb;
   int shift = bit_depth-8;
 
    while (1){

     for(int i=0; i<STRING_LEN; i++) {
       valueb=(pixelsb[i] + errorsb[i]) >> shift;
       valuer=(pixelsr[i] + errorsr[i]) >> shift;
       valueg=(pixelsg[i] + errorsg[i]) >> shift;
       put_pixel(urgb_u32(valuer, valueg, valueb));
       errorsb[i] = (pixelsb[i] + errorsb[i]) -
(valueb << shift);
       errorsr[i] = (pixelsr[i] + errorsr[i]) -
(valuer << shift);
       errorsg[i] = (pixelsg[i] + errorsg[i]) -
(valueg << shift);
     }
     sleep_us(400);
   }
}

We start by defining a virtual bit depth. This is how many bits per pixel you can use. Our code will then attempt to create the necessary additional brightness levels. It will run as fast as it can drive the LED strip, but if you try to do too many brightness levels, you’ll start to notice flickering.

We found twelve to be about the best with strings up to around 100 LEDs, but you can experiment with others. Our code works with two arrays – pixels which holds the values that we want to display, and errors which holds the error in what we’ve displayed so far (there are three of each for the different colour channels).

If you just want to see this in action, you can download the UF2 file from hsmag.cc/orfgBD and flash it straight to your Pico
If you just want to see this in action, you can download the UF2 file from hsmag.cc/orfgBD and flash it straight to your Pico

To explain that latter point, let’s take a look at the algorithm for determining how to light the LED. We borrowed this from the source code of Fadecandy by Micah Scott, but it’s a well-used algorithm for calculating error rates. We have an outer while loop that just keeps pushing out data to the LEDs as fast as possible. We don’t care about precise timings and just want as much speed as possible. We then go through each pixel.

The corresponding item in the errors array holds the cumulative amount our LED has been underlit so far compared to what we want it to be. Initially, this will be zero, but with each loop (if there’s a difference between what we want to light the LED and what we can light the LED) this error value will increase. These two numbers (the closest light level and the error) added together give the brightness at the pseudo-level, so we need to bit-shift this by the difference between our virtual level and the 8-bit brightness levels that are available.

This gives us the value for this pixel which we write out. We then need to calculate the new error level. Let’s take a look at what this means in practice. Suppose we want a brightness level halfway between 1 and 2 in the 8-bit levels. To simplify things, we’ll use nine virtual bits. 1 and 2 in 8-bit is 2 and 4 in 9 bits (adding an extra 0 to the end multiplies everything by a power of 2), so halfway between these two is a 9-bit value of 3 (or 11 in binary, which we’ll use from now on).

In the first iteration of our loop, pixels is 11, errors is 0, and shift is 1.

value = 11 >> 1 = 1
errors = 11 – 10 = 1

So this time, the brightness level of 1 is written out. The second iteration, we have:

value = 100 >> 1 = 10
errors = 100 – 100 = 0

So this time, the brightness level of 10 (in binary, or 2 in base 10) is written out. This time, the errors go back to 0, so we’re in the same position as at the start of the first loop. In this case, the LED will flick between the two brightness levels each loop so you’ll have a brightness half way between the two.

Using this simple algorithm, we can experiment with different virtual bit-depths. The algorithm will always handle the calculations for us, but we just have to see what creates the most pleasing visual effect for the eye. The larger the virtual bit depth, the more potential iterations you have to go through before the error accumulates enough to create a correction, so the more likely you are to see flicker. The biggest blocker to increasing the virtual bit depth is the sleep_us(400). This is needed to reset the LED strip.

NeoPixels come in many different shapes and sizes

Essentially, we throw out bits at 800kHz, and each block of 24 bits is sent, in turn, to the next LED. However, once there’s a long enough pause, everything resets and it goes back to the first LED. How big that pause is can vary. The truth is that a huge proportion of WS2812B LEDs are clones rather than official parts – and even for official parts, the length of the pause needed to reset has changed over the years.

400 microseconds is conservative and should work, but you may be able to get away with less (possibly even as low as 50 microseconds for some LEDs). The urgb_u32 method simply amalgamates the red, blue, and green values into a single 32-bit string (well, a 24-bit string that’s held inside a 32-bit string), and put_pixel sends this to the state machine. The bit shift there is to make sure the data is in the right place so the state machine reads the correct 24 bits from the output shift register.

Getting it running

We’ve now dealt with all the mechanics of the code. The only bit left is to stitch it all together.

int main() {

   PIO pio = pio0;
   int sm = 0;
   uint offset = pio_add_program(pio, &ws2812_
program);
    ws2812_program_init(pio, sm, offset, PIN_TX,
1000000, false);
   multicore_launch_core1(ws2812b_core);

   while (1) {
       for (int i = 0; i < 30; ++i) {
        pixels[i] = i;

        for (int j=0;j<30;++j){
          pixels[0] = j;
            if(j%8 == 0) { pixels[1] = j; }
               sleep_ms(50);
            }
        for (int j=30;j>0;--j){
         pixels[0] = j;
            if(j%8 == 0) { pixels[1] = j; }
           sleep_ms(50);
         }
      }
   } 
}

The method ws2812_program_init calls the method created in the PIO program to set everything up. To launch the algorithm creating the virtual bit-depth, we just have to use multicore_launch_core1 to set a function running on the other core. Once that’s done, whatever we put in the pixels array will be reflected as accurately as possible in the WS2812B LEDs. In this case, we simply fade it in and out, but you could do any animation you like.

Get a free Raspberry Pi Pico

Would you like a free Raspberry Pi Pico? Subscribe to HackSpace magazine via your preferred option here, and you’ll receive your new microcontroller in the mail before the next issue arrives.

The post NeoPixel dithering with Pico appeared first on Raspberry Pi.

Meet Raspberry Silicon: Raspberry Pi Pico now on sale at $4

Today, we’re launching our first microcontroller-class product: Raspberry Pi Pico. Priced at just $4, it is built on RP2040, a brand-new chip developed right here at Raspberry Pi. Whether you’re looking for a standalone board for deep-embedded development or a companion to your Raspberry Pi computer, or you’re taking your first steps with a microcontroller, this is the board for you.

You can buy your Raspberry Pi Pico today online from one of our Approved Resellers. Or head to your local newsagent, where every copy of this month’s HackSpace magazine comes with a free Pico, as well as plenty of guides and tutorials to help you get started with it. If coronavirus restrictions mean that you can’t get to your newsagent right now, you can grab a subscription and get Pico delivered to your door.

Oops!… We Did It Again

Microcomputers and microcontrollers

Many of our favourite projects, from cucumber sorters to high altitude balloons, connect Raspberry Pi to the physical world: software running on the Raspberry Pi reads sensors, performs computations, talks to the network, and drives actuators. This ability to bridge the worlds of software and hardware has contributed to the enduring popularity of Raspberry Pi computers, with over 37 million units sold to date.

But there are limits: even in its lowest power mode a Raspberry Pi Zero will consume on the order of 100 milliwatts; Raspberry Pi on its own does not support analogue input; and while it is possible to run “bare metal” software on a Raspberry Pi, software running under a general-purpose operating system like Linux is not well suited to low-latency control of individual I/O pins.

Many hobbyist and industrial applications pair a Raspberry Pi with a microcontroller. The Raspberry Pi takes care of heavyweight computation, network access, and storage, while the microcontroller handles analogue input and low-latency I/O and, sometimes, provides a very low-power standby mode.

Until now, we’ve not been able to figure out a way to make a compelling microcontroller-class product of our own. To make the product we really wanted to make, first we had to learn to make our own chips.

Raspberry Si

It seems like every fruit company is making its own silicon these days, and we’re no exception. RP2040 builds on the lessons we’ve learned from using other microcontrollers in our products, from the Sense HAT to Raspberry Pi 400. It’s the result of many years of hard work by our in-house chip team.

RP2040 on a Raspberry Pi Pico

We had three principal design goals for RP2040: high performance, particularly for integer workloads; flexible I/O, to allow us to talk to almost any external device; and of course, low cost, to eliminate barriers to entry. We ended up with an incredibly powerful little chip, cramming all this into a 7 × 7 mm QFN-56 package containing just two square millimetres of 40 nm silicon. RP2040 has:

  • Dual-core Arm Cortex-M0+ @ 133MHz
  • 264KB (remember kilobytes?) of on-chip RAM
  • Support for up to 16MB of off-chip Flash memory via dedicated QSPI bus
  • DMA controller
  • Interpolator and integer divider peripherals
  • 30 GPIO pins, 4 of which can be used as analogue inputs
  • 2 × UARTs, 2 × SPI controllers, and 2 × I2C controllers
  • 16 × PWM channels
  • 1 × USB 1.1 controller and PHY, with host and device support
  • 8 × Raspberry Pi Programmable I/O (PIO) state machines
  • USB mass-storage boot mode with UF2 support, for drag-and-drop programming

And this isn’t just a powerful chip: it’s designed to help you bring every last drop of that power to bear. With six independent banks of RAM, and a fully connected switch at the heart of its bus fabric, you can easily arrange for the cores and DMA engines to run in parallel without contention.

For power users, we provide a complete C SDK, a GCC-based toolchain, and Visual Studio Code integration.

As Cortex-M0+ lacks a floating-point unit, we have commissioned optimised floating-point functions from Mark Owen, author of the popular Qfplib libraries; these are substantially faster than their GCC library equivalents, and are licensed for use on any RP2040-based product.

With two fast cores and and a large amount of on-chip RAM, RP2040 is a great platform for machine learning applications. You can find Pete Warden’s port of Google’s TensorFlow Lite framework here. Look out for more machine learning content over the coming months.

For beginners, and other users who prefer high-level languages, we’ve worked with Damien George, creator of MicroPython, to build a polished port for RP2040; it exposes all of the chip’s hardware features, including our innovative PIO subsystem. And our friend Aivar Annamaa has added RP2040 MicroPython support to the popular Thonny IDE.

Raspberry Pi Pico

Raspberry Pi Pico is designed as our low-cost breakout board for RP2040. It pairs RP2040 with 2MB of Flash memory, and a power supply chip supporting input voltages from 1.8-5.5V. This allows you to power your Pico from a wide variety of sources, including two or three AA cells in series, or a single lithium-ion cell.

Pico provides a single push button, which can be used to enter USB mass-storage mode at boot time and also as a general input, and a single LED. It exposes 26 of the 30 GPIO pins on RP2040, including three of the four analogue inputs, to 0.1”-pitch pads; you can solder headers to these pads or take advantage of their castellated edges to solder Pico directly to a carrier board. Volume customers will be able to buy pre-reeled Pico units: in fact we already supply Pico to our Approved Resellers in this format.

The Pico PCB layout was co-designed with the RP2040 silicon and package, and we’re really pleased with how it turned out: a two-layer PCB with a solid ground plane and a GPIO breakout that “just works”.

A reel of Raspberry Pi Pico boards
Reely good

Whether Raspberry Pi Pico is your first microcontroller or your fifty-first, we can’t wait to see what you do with it.

Raspberry Pi Pico documentation

Our ambition with RP2040 wasn’t just to produce the best chip, but to support that chip with the best documentation. Alasdair Allan, who joined us a year ago, has overseen a colossal effort on the part of the whole engineering team to document every aspect of the design, with simple, easy-to-understand examples to help you get the most out of your Raspberry Pi Pico.

You can find complete documentation for Raspberry Pi Pico, and for RP2040, its SDK and toolchain, here.

Get Started with Raspberry Pi Pico book

To help you get the most of your Pico, why not grab a copy of Get Started with MicroPython on Raspberry Pi Pico by Gareth Halfacree and our very own Ben Everard. It’s ideal for beginners who are new (or new-ish) to making with microcontrollers.

Our colleagues at the Raspberry Pi Foundation have also produced an educational project to help you get started with Raspberry Pi Pico. You can find it here.

Partners

Over the last couple of months, we’ve been working with our friends at Adafruit, Arduino, Pimoroni, and Sparkfun to create accessories for Raspberry Pi Pico, and a variety of other boards built on the RP2040 silicon platform. Here are just a few of the products that are available to buy or pre-order today.

Adafruit Feather RP 2040

RP2040 joins the hundreds of boards in the Feather ecosystem with the fully featured Feather RP 2040 board. The 2″ × 0.9″ dev board has USB C, Lipoly battery charging, 4MB of QSPI flash memory, a STEMMA QT I2C connector, and an optional SWD debug port. With plenty of GPIO for use with any FeatherWing, and hundreds of Qwiic/QT/Grove sensors that can plug and play, it’s the fast way to get started.

Feathery goodness

Adafruit ItsyBitsy RP 2040

Need a petite dev board for RP2040? The Itsy Bitsy RP 2040 is positively tiny, but it still has lots of GPIO, 4MB of QSPI flash, boot and reset buttons, a built-in RGB NeoPixel, and even a 5V output logic pin, so it’s perfect for NeoPixel projects!

Small is beautiful

Arduino Nano RP2040 Connect

Arduino joins the RP2040 family with one of its most popular formats: the Arduino Nano. The Arduino Nano RP2040 Connect combines the power of RP2040 with high-quality MEMS sensors (a 9-axis IMU and microphone), a highly efficient power section, a powerful WiFi/Bluetooth module, and the ECC608 crypto chip, enabling anybody to create secure IoT applications with this new microcontroller. The Arduino Nano RP2040 Connect will be available for pre-order in the next few weeks.

Get connected!

Pimoroni PicoSystem

PicoSystem is a tiny and delightful handheld game-making experience based on RP2040. It comes with a simple and fast software library, plus examples to make your mini-gaming dreams happen. Or just plug it into USB and drop the best creations from the Raspberry Pi-verse straight onto the flash drive.

Pixel-pushing pocket-sized playtime

Pimoroni Pico Explorer Base

Pico Explorer offers an embedded electronics environment for educators, engineers, and software people who want to learn hardware with less of the “hard” bit. It offers easy expansion and breakout along with a whole bunch of useful bits.

Go explore!

SparkFun Thing Plus – RP2040

The Thing Plus – RP2040 is a low-cost, high-performance board with flexible digital interfaces featuring Raspberry Pi’s RP2040 microcontroller. Within the Feather-compatible Thing Plus form factor with 18 GPIO pins, the board offers an SD card slot, 16MB (128Mbit) flash memory, a JST single-cell battery connector (with a charging circuit and fuel gauge sensor), an addressable WS2812 RGB LED, JTAG PTH pins, mounting holes, and a Qwiic connector to add devices from SparkFun’s quick-connect I2C ecosystem.

Thing One, or Thing Two?

SparkFun MicroMod RP2040 Processor

The MicroMod RP2040 Processor Board is part of SparkFun’s MicroMod modular interface system. The MicroMod M.2 connector makes it easy to connect your RP2040 Processor Board with the MicroMod carrier board that gives you the inputs and outputs you need for your project.

The Mighty Micro

SparkFun Pro Micro – RP2040

The Pro Micro RP2040 harnesses the capability of RP2040 on a compact development board with the USB functionality that is the hallmark of all SparkFun’s Pro Micro boards. It has a WS2812B addressable LED, boot button, reset button, Qwiic connector, USB-C, and castellated pads.

Go Pro

Credits

It’s fair to say we’ve taken the long road to creating Raspberry Pi Pico. Chip development is a complicated business, drawing on the talents of many different people. Here’s an incomplete list of those who have contributed to the RP2040 and Raspberry Pi Pico projects:

Dave Akerman, Sam Alder, Alasdair Allan, Aivar Annamaa, Jonathan Bell, Mike Buffham, Dom Cobley, Steve Cook, Phil Daniell, Russell Davis, Phil Elwell, Ben Everard, Andras Ferencz, Nick Francis, Liam Fraser, Damien George, Richard Gordon, F Trevor Gowen, Gareth Halfacree, David Henly, Kevin Hill, Nick Hollinghurst, Gordon Hollingworth, James Hughes, Tammy Julyan, Jason Julyan, Phil King, Stijn Kuipers, Lestin Liu, Simon Long, Roy Longbottom, Ian Macaulay, Terry Mackown, Simon Martin, Jon Matthews, Nellie McKesson, Rod Oldfield, Mark Owen, Mike Parker, David Plowman, Dominic Plunkett, Graham Sanderson, Andrew Scheller, Serge Schneider, Nathan Seidle, Vinaya Puthur Sekar, Mark Sherlock, Martin Sperl, Mike Stimson, Ha Thach, Roger Thornton, Jonathan Welch, Simon West, Jack Willis, Luke Wren, David Wright.

We’d also like to thank our friends at Sony Pencoed and Sony Inazawa, Microtest, and IMEC for their help in bringing these projects to fruition.

Buy your Raspberry Pi Pico from one of our Approved Resellers today, and let us know what you think!

FAQs

Are you planning to make RP2040 available to customers?

We hope to make RP2040 broadly available in the second quarter of 2021.

The post Meet Raspberry Silicon: Raspberry Pi Pico now on sale at $4 appeared first on Raspberry Pi.

Computing education and underrepresentation: the data from England

In this blog post, I’ll discuss the first research seminar in our six-part series about diversity and inclusion. Let’s start by defining our terms. Diversity is any dimension that can be used to differentiate groups and people from one another. This might be, for example, age, gender, socio-economic status, disability, ethnicity, religion, nationality, or sexuality. The aim of inclusion is to embrace all people irrespective of difference.

It’s vital that we are inclusive in computing education, because we need to ensure that everyone can access and learn the empowering and enabling technical skills they need to support all aspects of their lives.

One male and two female teenagers at a computer

Between January and June of this year, we’re partnering with the Royal Academy of Engineering to host speakers from the UK and USA for a series of six research seminars focused on diversity and inclusion in computing education.

We kicked off the series with a seminar from Dr Peter Kemp and Dr Billy Wong focused on computing education in England’s schools post-14. Peter is a Lecturer in Computing Education at King’s College London, where he leads on initial teacher education in computing. His research areas are digital creativity and digital equity. Billy is an Associate Professor at the Institute of Education, University of Reading. His areas of research are educational identities and inequalities, especially in the context of higher education and STEM education.

  • Peter Kemp
    Dr Peter Kemp
  • Dr Billy Wong

Computing in England’s schools

Peter began the seminar with a comprehensive look at the history of curriculum change in Computing in England. This was very useful given our very international audience for these seminars, and I will summarise it below. (If you’d like more detail, you can look over the slides from the seminar. Note that these changes refer to England only, as education in the UK is devolved, and England, Northern Ireland, Scotland, and Wales each has a different education system.)

In 2014, England switched from mandatory ICT (Information and Communication Technology) to mandatory Computing (encompassing information technology, computer science, and digital literacy). This shift was complemented by a change in the qualifications for students aged 14–16 and 16–18, where the primary qualifications are GCSEs and A levels respectively:

  • At GCSE, there has been a transition from GCSE ICT to GCSE Computer Science over the last five years, with GCSE ICT being discontinued in 2017
  • At A level before 2014, ICT and Computing were on offer as two separate A levels; now there is only one, A level Computer Science

One of the issues is that in the English education system, there is a narrowing of the curriculum at age 14: students have to choose between Computer Science and other subjects such as Geography, History, Religious Studies, Drama, Music, etc. This means that those students that choose not to take a GCSE Computer Science (CS) may find that their digital education is thereby curtailed from then onwards. Peter’s and Billy’s view is that having a more specialist subject offer for age 14+ (Computer Science as opposed to ICT) means that fewer students take it, and they showed evidence of this from qualifications data. The number of students taking CS at GCSE has risen considerably since its introduction, but it’s not yet at the level of GCSE ICT uptake.

GCSE computer science and equity

Only 64% of schools in England offer GCSE Computer Science, meaning that just 81% of students have the opportunity to take the subject (some schools also add selection criteria). A higher percentage (90%) of selective grammar schools offer GCSE CS than do comprehensive schools (80%) or independent schools (39%). Peter suggested that this was making Computer Science a “little more elitist” as a subject.

Peter analysed data from England’s National Pupil Database (NPD) to thoroughly investigate the uptake of Computer Science post-14 with respect to the diversity of entrants.

He found that the gender gap for GCSE CS uptake is greater than it was for GCSE ICT. Now girls make up 22% of the cohort for GCSE CS (2020 data), whereas for the ICT qualification (2017 data), 43% of students were female.

Peter’s analysis showed that there is also a lower representation of black students and of students from socio-economically disadvantaged backgrounds in the cohort for GCSE CS. In contrast, students with Chinese ancestry are proportionally more highly represented in the cohort. 

Another part of Peter’s analysis related gender data to the Income Deprivation Affecting Children Index (IDACI), which is used as an indicator of the level of poverty in England’s local authority districts. In the graphs below, a higher IDACI decile means more deprivation in an area. Relating gender data of GCSE CS uptake against the IDACI shows that:

  • Girls from more deprived areas are more likely to take up GCSE CS than girls from less deprived areas are
  • The opposite is true for boys
Two bar charts relating gender data of GCSE uptake against the Income Deprivation Affecting Children Index. The graph plotting GCSE ICT data shows that students from areas with higher deprivation are slightly more likely to choose the GCSE, irrespective of gender. The graph plotting GCSE Computer Science data shows that girls from more deprived areas are more likely to take up GCSE CS than girls from less deprived areas, and the opposite is true for boys.

Peter covered much more data in the seminar, so do watch the video recording (below) if you want to learn more.

Peter’s analysis shows a lack of equity (i.e. equality of outcome in the form of proportional representation) in uptake of GCSE CS after age 14. It is also important to recognise, however, that England does mandate — not simply provide or offer — Computing for all pupils at both primary and secondary levels; making a subject mandatory is the only way to ensure that we do give access to all pupils.

What can we do about the lack of equity?

Billy presented some of the potential reasons for why some groups of young people are not fully represented in GCSE Computer Science:

  • There are many stereotypes surrounding the image of ‘the computer scientist’, and young people may not be able to identify with the perception they hold of ‘the computer scientist’
  • There is inequality in access to resources, as indicated by the research on science and STEM capital being carried out within the ASPIRES project

More research is needed to understand the subject choices young people make and their reasons for choosing as they do.

We also need to look at how the way we teach Computing to students aged 11 to 14 (and younger) affects whether they choose CS as a post-14 subject. Our next seminar revolves around equity-focused teaching practices, such as culturally relevant pedagogy or culturally responsive teaching, and how educators can use them in their CS learning environments. 

Meanwhile, our own research project at the Raspberry Pi Foundation, Gender Balance in Computing, investigates particular approaches in school and non-formal learning and how they can impact on gender balance in Computer Science. For an overview of recent research around barriers to gender balance in school computing, look back on the research seminar by Katharine Childs from our team.

Peter and Billy themselves have recently been successful in obtaining funding for a research project to explore female computing performance and subject choice in English schools, a project they will be starting soon!

If you missed the seminar, watch recording here. You can also find Peter and Billy’s presentation slides on our seminars page.

Next up in our seminar series

In our next research seminar on Tuesday 2 February at 17:00–18:30 BST / 12:00–13:30 EDT / 9:00–10:30 PDT / 18:00–19:30 CEST, we’ll welcome Prof Tia Madkins (University of Texas at Austin), Dr Nicol R. Howard (University of Redlands), and Shomari Jones (Bellevue School District), who are going to talk to us about culturally responsive pedagogy and equity-focused teaching in K-12 Computer Science. To join this free online seminar, simply sign up with your name and email address.

Once you’ve signed up, we’ll email you the seminar meeting link and instructions for joining. If you attended Peter’s and Billy’s seminar, the link remains the same.

The post Computing education and underrepresentation: the data from England appeared first on Raspberry Pi.

Raspberry Pi LEGO sorter

Raspberry Pi is at the heart of this AI–powered, automated sorting machine that is capable of recognising and sorting any LEGO brick.

And its maker Daniel West believes it to be the first of its kind in the world!

Best ever

This mega-machine was two years in the making and is a LEGO creation itself, built from over 10,000 LEGO bricks.

A beast of 10,000 bricks

It can sort any LEGO brick you place in its input bucket into one of 18 output buckets, at the rate of one brick every two seconds.

While Daniel was inspired by previous LEGO sorters, his creation is a huge step up from them: it can recognise absolutely every LEGO brick ever created, even bricks it has never seen before. Hence the ‘universal’ in the name ‘universal LEGO sorting machine’.

Hardware

There we are, tucked away, just doing our job

Software

The artificial intelligence algorithm behind the LEGO sorting is a convolutional neural network, the go-to for image classification.

What makes Daniel’s project a ‘world first’ is that he trained his classifier using 3D model images of LEGO bricks, which is how the machine can classify absolutely any LEGO brick it’s faced with, even if it has never seen it in real life before.

We LOVE a thorough project video, and we love TWO of them even more

Daniel has made a whole extra video (above) explaining how the AI in this project works. He shouts out all the open source software he used to run the Raspberry Pi Camera Module and access 3D training images etc. at this point in the video.

LEGO brick separation

The vibration plate in action, feeding single parts into the scanner

Daniel needed the input bucket to carefully pick out a single LEGO brick from the mass he chucks in at once.

This is achieved with a primary and secondary belt slowly pushing parts onto a vibration plate. The vibration plate uses a super fast LEGO motor to shake the bricks around so they aren’t sitting on top of each other when they reach the scanner.

Scanning and sorting

A side view of the LEFO sorting machine showing a large white chute built from LEGO bricks
The underside of the beast

A Raspberry Pi Camera Module captures video of each brick, which Raspberry Pi 3 Model B+ then processes and wirelessly sends to a more powerful computer able to run the neural network that classifies the parts.

The classification decision is then sent back to the sorting machine so it can spit the brick, using a series of servo-controlled gates, into the right output bucket.

Extra-credit homework

A front view of the LEGO sorter with the sorting boxes visible underneath
In all its bricky beauty, with the 18 output buckets visible at the bottom

Daniel is such a boss maker that he wrote not one, but two further reading articles for those of you who want to deep-dive into this mega LEGO creation:

The post Raspberry Pi LEGO sorter appeared first on Raspberry Pi.

Deter burglars with a Raspberry Pi chatbot

How to improve upon the standard burglar deterring method of leaving lights switched on? Dennis Mellican turned to Raspberry Pi for a much more effective solution. It actually proved too effective when a neighbour stopped by, but more on that in a bit.

Here you can see Dennis’s system in action scaring off a trespasser:

Good job, Raspberry Pi chatbots!

The burglar deterrent started out as Dennis’s regular home automation system. Not content with the current software offerings, and having worked in DevOps, Dennis decided to create his own solution. Enter Raspberry Pi (well, several of them).

Chatterboxes

Dennis has multiple Raspberry Pi–powered devices dotted around his home, doing things such as turning on lights, powering up a garden sprinkler, and playing fake dog barks on wireless speakers. All these burglar deterrents work together and are run by a chat bot.

A simulation of the chatbots responding to Dennis’ commands

Each Raspberry Pi controls a single automated item in Dennis’s home. All the Raspberry Pis communicate with each other via Slack. Dennis issues commands if he, for example, wants lights to turn on while he is away, but the Raspberry Pis can also talk to each other when a trigger event occurs, such as when a motion sensor is tripped.

Smart sound

speaker, chromecast device, cctv camera and the Raspberry Pi connected for the anti burglary chatbot
Speaker, Google Chromecast, CCTV camera and Raspberry Pi

Google Chromecast enables ‘dumb’ speakers to be smart. Dennis has such speakers set up inside, close to windows at the front and back of the house, and they play an .mp3 file of a fake dog bark when commanded.

The security cameras Dennis uses in his home setup are a wireless CCTV variety, and the lights are a mix of TP-Link and Lifx smart bulbs.

Here’s all the Python code running Dennis’ entire security system.

Too effective?

Dennis’s smart system has backfired on him a few times. Once a neighbour visited while he was out and thought Dennis was rudely not answering the door, because she saw the lights go on inside, making it appear like he was home. Awkward.

The fake dog barking has also startled the postman and a few joggers — Dennis says it adds to the realism.

You’re cute, but you wreck stuff, so get out

The troupe of Raspberry Pis has also scared away an Australian possum (video above). These critters are notorious for making nests in roof cavities, so Dennis dodged another problematic home invasion there.

Future upgrades

Dennis is a maker after our own hearts when explaining where he’d like to go next with his anti-burglary build:

“I feel like Kevin McCallister from Home Alone, with these home security ‘traps’. I’m still waiting to catch the Wet Bandits for the sequel to this story. So far only stray cats have been caught by the sprinkler. Perhaps the next adventure of the chat bot is to order pizza and have Gangster ‘Johnny’ complete the transaction when the pizza delivery triggers the sensors.”

Go for it, Dennis!

The post Deter burglars with a Raspberry Pi chatbot appeared first on Raspberry Pi.

RetroPie booze barrel

What do we want? Retro gaming, adult beverages, and our favourite Spotify playlist. When do we want them? All at the same time.

Luckily, u/breadtangle took to reddit to answer our rum-soaked prayers with this beautifully crafted beer barrel-cum-arcade machine-cum-drinks cabinet.

A beer barrel with drinks inside two opening doors cut into the front of the barrel and a retro arcade console serving as the lid of the barrel with joystick and buttons on a ledge in front
We approve of this drink selection

The addition of a sneaky hiding spot for your favourite tipple, plus a musical surprise, set this build apart from the popular barrel arcade projects we’ve seen before, like this one featured a few years back on the blog.

Retro gaming

A Raspberry Pi 3 Model B+ runs RetroPie, offering all sorts of classic games to entertain you while you sample from the grownup goodies hidden away in the drinks cabinet.

The maker’s top choice is Tetris Attack for the SNES.

A beer barrel with drinks inside two opening doors cut into the front of the barrel and a retro arcade console serving as the lid of the barrel with joystick and buttons on a ledge in front
Such a beautiful finish

Background music

What more could you want now you’ve got retro games and an elegantly hidden drinks cabinet at your fingertips? u/breadtangle‘s creation has another trick hidden inside its smooth wooden curves.

The Raspberry Pi computer used in this build also runs Raspotify, a Spotify Connect client for Raspberry Pi that allows you to stream your favourite tunes and playlists from your phone while you game.

You can set Raspotify to play via Bluetooth speakers, but if you’re using regular speakers and are after a quick install, whack this command in your Terminal:

curl -sL https://dtcooper.github.io/raspotify/install.sh | sh
Booze barrel joystick and buttons panel during the making process
Behind the scenes

u/breadtangle neatly tucked a pair of Logitech z506 speakers on the sides of the barrel, where they could be protected by the overhang of the glass screen cover.

Hardware

The build’s joysticks and buttons came from Amazon, and they’re set into an off-cut piece of kitchen countertop. The glass screen protector is another Amazon find and sits on a rubber car-door edge protector.

The screen itself is lovingly tilted towards the controls, to keep players’ necks comfortable, and u/breadtangle finished off the build’s look with a barstool to sit on while gaming.

We love it, but we have one very important question left…

Can we come round and play?

The post RetroPie booze barrel appeared first on Raspberry Pi.

Get VMware on Raspberry Pi

Hacking apart a sweet, innocent Raspberry Pi – who would do such a thing? Network Chuck, that’s who. But he has a very cool reason for it so, we’ll let him off the hook.

Subscribe to Network Chuck on YouTube

He’s figured out how to install VMware ESXi on Raspberry Pi, and he’s sharing the step-by-step process with you because he loves you. And us. We think. We hope.

Get cutting

In a nutshell, Chuck “hacks” apart a Raspberry Pi to show you how it can operate as three separate computers, each running different software at the same time. He’s a wizard.

Our poor sweet baby 😮

VMware is cool because it’s Virtual Machine software big companies use on huge servers, but you can deploy it on one of our tiny devices and learn how to use it in the comfort of your own home if you follow Chuck’s instructions.

Raspberry Pi cut into three pieces with labels showing how powerful each bit is and what it's capable of
Useful labels explaining which bit of Raspberry Pi is capable of what

What do you need?

Make sure you’re up to date

So easy, it only takes 40 seconds to explain

Firstly, you need to make sure you’re running the latest version of Raspberry Pi OS. Chuck uses Raspberry Pi Imager to do this, and the video above shows you how to do the same.

Format your SD card

Network Chuck removing SD card from Raspberry Pi 4
It’s teeny, but powerful

Then you’ll need to format your SD card ready for VMware ESXi. This can be done with Raspberry Pi Imager too. You’ll need to download these two things:

Chuck is the kind of good egg who walks you through how to do this on screen at this point in the project video.

VMware installation

Then you’ll need to create the VMWare Installer to install the actual software. It’s at this point your USB flash drive takes centre stage. Here’s everything you’ll need:

And this is the point in the video at which Chuck walks you through the process.

Once that’s all done, stick your USB flash drive into your Raspberry Pi and get going. You need to be quick off the mark for this bit – there’s some urgent Escape key pressing required, but don’t worry, Chuck walks you through everything.

Create a VM and expand your storage

Once you’ve followed all those steps, you will be up, running, and ready to go. The installation process only takes up the first 15 minutes of Chuck’s project video, and he spends the rest of his time walking you through creating your first VM and adding more storage.

Top job, Chuck.

Keep up with Chuck

Network Chuck holding a Raspberry Pi 4 next to his broadcasting microphone
Fun fact: Raspberry Pi 4 is the same length as Network Chuck’s beard

Network Chuck live-streams every Monday on his YouTube channel, and you can follow him on Twitter too.

There’s also the brilliant networkchuck.com.

The post Get VMware on Raspberry Pi appeared first on Raspberry Pi.

Supporting teachers and students with remote learning through free video lessons

Working with Oak National Academy, we’ve turned the materials from our Teach Computing Curriculum into more than 300 free, curriculum-mapped video lessons for remote learning.

A girl in a hijab learning at home at a laptop

A comprehensive set of free classroom materials

One of our biggest projects for teachers that we’ve worked on over the past two years is the Teach Computing Curriculum: a comprehensive set of free computing classroom materials for key stages 1 to 4 (learners aged 5 to 16). The materials comprise lesson plans, homework, progression mapping, and assessment materials. We’ve created these as part of the National Centre for Computing Education, but they are freely available for educators all over the world to download and use.

More than 300 free, curriculum-mapped video lessons

In the second half of 2020, in response to school closures, our team of experienced teachers produced over 100 hours of video to transform Teach Computing Curriculum materials into video lessons for learning at home. They are freely available for parents, educators, and learners to continue learning computing at home, wherever you are in the world.

Here’s the start of lesson 2 in the Year 8 ‘Computer systems’ unit

You’ll find our videos for more than 300 hour-long lessons on the Oak National Academy website. The progression of the lessons is mapped out clearly, and the videos cover England’s computing national curriculum. There are video lessons for:

  • Years 5 and 6 at key stage 2 (ages 7 to 11)
  • Years 7, 8, and 9 at key stage 3 (ages 11 to 14)
  • Examined (GCSE) as well as non-examined (Digital Literacy) at key stage 4 (ages 14 to 16)

To access the full set of classroom materials for teaching, visit the National Centre for Computing Education website.

The post Supporting teachers and students with remote learning through free video lessons appeared first on Raspberry Pi.

These Furby-‘controlled’ Raspberry Pi-powered eyes follow you

Sam Battle aka LOOK MUM NO COMPUTER couldn’t resist splashing out on a clear Macintosh case for a new project in his ‘Cosmo’ series of builds, which inject new life into retro hardware.

furby facial recognition robot in a clear case in front of a dark background
AAGGGGHHHHHHH!

This time around, a Raspberry Pi, running facial recognition software, and one of our Camera Modules enable Furby-style eyes to track movement, detect faces, and follow you around the room.

Give LOOK MUM NO COMPUTER a follow on YouTube

He loves a good Furby does Sam. Has a whole YouTube playlist dedicated to projects featuring them. Seriously.

Raspberry Pi  with camera module attached to small screen loading software needed to run face recognition
Sam got all the Raspberry Pi kit needed from Pimoroni

Our favourite bit of the video is when Sam meets Raspberry Pi for the first time, boots it up, and says:

“Wait, I didn’t know it was a computer. It’s an actual computer computer. What?!”

face recognition software running on small screen with raspberry pi camera behind it, looking at the maker
Face recognition software up and running on Raspberry Pi

The eyes are ping pong balls cut in half so you can fit a Raspberry Pi Camera Module inside them. (Don’t forget to make a hole in the ‘pupil’ so the lens can peek through).

Maker inserting raspberry pi camera module inside a sliced ping pong ball. You can see the ribbons of the camera module sticking out of the ping pong ball half
Raspberry Pi Camera Module tucked inside ping pong ball as it’s mounted to a 3D-printed part

The Raspberry Pi and display screen are neatly mounted on the side of the Macintosh so they’re easily accessible should you need to make any changes.

Raspberry Pi and display screen mounted on the side of a clear macintosh frame
Easy access

All the hacked, repurposed junky bits sit inside or are mounted on swish 3D-printed parts.

Add some joke shop chatterbox teeth, and you’ve got what looks like the innards of a Furby staring at you. See below for a harrowing snapshot of Zach’s ‘Furlexa’ project, featured on our blog last year. We still see it when we sleep.

It gets worse the more you look around

It wasn’t enough for Furby-mad Sam to have created a Furby look-a-like face-tracking robot, he needed to go further. Inside the clear Macintosh case, you can see a de-furred Furby skeleton atop a 3D-printed plinth, with redundant ribbon cables flowing from its eyes into the back of the face-tracking robot face, thus making it appear as though the Furby is the brains behind this creepy creation that is following your every move.

a side view of the entire build with a furby skeleton visible inside
Hey in there. We see you! You dark lord of robo-controlling

Eventually, Sam’s Raspberry Pi–powered creation will be on display at the Museum of Everything Else, so you can go visit it and play with all the “obsolete and experimental technology” housed there. The museum is funded by the Look Mum No Computer Patreon page.

The post These Furby-‘controlled’ Raspberry Pi-powered eyes follow you appeared first on Raspberry Pi.

Raspberry Pi 400 for working and learning at home

Did you get Raspberry Pi 400 as a home learning or working device? We hope you’ve been getting on well with our affordable all-in-one computing solution.

If you’re a new user, here are some tips for you to get the most out of your brand-new Raspberry Pi 400.

Does *anyone’s* home office desk look this tidy?..

First things first!

Make sure your Raspberry Pi runs the newest version of the Raspberry Pi OS. Here is how (and here is a video preview of what the process looks like):

Screen grab of raspberry pi os being installed inline code

Open a terminal window by clicking on the Terminal icon in the top menu bar. Then type this command in the terminal window:

sudo apt update

Press Enter on the keyboard. Once the update is downloaded, type into the window:

sudo apt full-upgrade

Press Enter again. It is safe to just accept the default answer to any questions you are asked during the procedure by typing y and pressing Enter.

Now reboot your Raspberry Pi.

Videoconferencing, collaboration, files

‘Every Zoom Meeting’ by Second City via YouTube

With the newest version of Raspberry Pi OS installed, you can use the following applications in the Chromium browser:

Just log in with your username and password and start working or learning!

Raspberry Pi OS also has LibreOffice installed for working with text files, spreadsheets, and the like.

Printing on your Raspberry Pi

Go into the Preferences section in the main menu, and open Print Settings. This shows the system-config-printer dialog window, where you can do the usual things you’re familiar with from other operating systems: add new printers, remove old ones, set a printer as the default, and access the print queue for each printer.

Like most things in Linux-based operating systems such as Raspberry Pi OS, whether you can make your printer model work depends on user contributions; not every printer is supported yet. We’ve found that most networked printers work fine, while USB printers are a bit hit-and-miss. The best thing to do is to try it and see, and ask for help on our forums if your particular printer doesn’t seem to work.

More tips for using Raspberry Pi as a home computer

Our very own Alasdair Allen wrote a comprehensive guide that covers more topics of setting up a Raspberry Pi for home working, from getting your audio and video ready to setting up a Citrix workspace. Thanks Alasdair!

Free resources for learning at home

A girl and mother doing a homeschooling lesson at a laptop

We’ve got a host of completely free resources for young people, parents, and teachers to continue computing school lessons at home and learn about digital making. Discover them all here!

What do you need?

Let us know in the comments if there are any niggles you’re experiencing, or if you have a top tip to help others who are just getting to grips with using Raspberry Pi as a home learning or working device.

The post Raspberry Pi 400 for working and learning at home appeared first on Raspberry Pi.

Smart Fairy Tale

This is creepy, and we love it. OK, it’s not REALLY creepy, it’s just that some people have an aversion to dolls that appear to move of their own accord, due to a disturbing childhood experience — but enough about me.

Smart Fairy Tale is a whimsical, unique community project created by Berlin-based installation artist Niklas Roy and interaction designer Felix Fisgus.

Using a smartphone app, viewers determine which way a ball travels through transparent pipes, and depending on which light barriers the ball interrupts on its journey, various toys are animated to tell different stories.

The server of the installation is a Raspberry Pi 4. Via its GPIO pins, it controls the track switches and releases the ball.

Raspberry Pi 4 mounted onto plastic with the installation's servo and all the microcontrollers
Raspberry Pi 4 tucked in the top right-hand corner, mounted together with the router. Photo courtesy of Niklas’ project page

The apparatus is full of toys donated by residents of Wolfsburg, Germany. The artists wanted local people to not only be able to operate the mechanical piece, but also to have a hand in creating it. Each animatronic toy is made as a separate module, controlled by its own Arduino Nano.

Smart Fairy Tale can be remotely controlled by viewers who want to check in on the toys they gifted to the installation, and by any other curious people elsewhere in the world.

A phone using the app to control the installation. The installation is out of focus in the background
The app in action. Photo from Felix’s project page.

Better yet, the stories the toys tell were devised by local school students. The artists showed the gifted toys to a few elementary school classes, and the students drew several stories featuring toys they liked. The makers then programmed the toys to match what the drawings said they could do. A servo here, a couple of LEDs there, and the students’ stories were brought to life.

Some drawings local children made suggesting storylines for each of the gifted toys
Some of the storylines drawn by local children. Photo courtesy of Felix’s project page.

So what kind of stories did Wolfsburg’s finest come up with? One of the creators explains:

“There were a lot of scenes to interpret, like the blow-up love story, the chemtrail conspiracy, and the fossil fuel disaster, which culminates in a major traffic jam. The latter one even involved a laboratory for breeding synthetic dinosaurs by the use of renewable energies.”

Felix Fisgus

We LOVE it. Don’t tell me this isn’t creepy though…

WHY DO YOU HAUNT MY DREAMS???

You’ll find tonnes of extra technical specs and images in the project posts on both Felix and Niklas‘ websites.

The post Smart Fairy Tale appeared first on Raspberry Pi.

Code your own Pipe Mania puzzler | Wireframe #46

Create a network of pipes before the water starts to flow in our re-creation of a classic puzzler. Jordi Santonja shows you how.

A screen grab of the game in motion
Pipe Mania’s design is so effective, it’s appeared in various guises elsewhere – even as a minigame in BioShock.

Pipe Mania, also called Pipe Dream in the US, is a puzzle game developed by The Assembly Line in 1989 for Amiga, Atari ST, and PC, and later ported to other platforms, including arcades. The player must place randomly generated sections of pipe onto a grid. When a counter reaches zero, water starts to flow and must reach the longest possible distance through the connected pipes.

Let’s look at how to recreate Pipe Dream in Python and Pygame Zero. The variable start is decremented at each frame. It begins with a value of 60*30, so it reaches zero after 30 seconds if our monitor runs at 60 frames per second. In that time, the player can place tiles on the grid to build a path. Every time the user clicks on the grid, the last tile from nextTiles is placed on the play area and a new random tile appears at the top of the next tiles. randint(2,8) computes a random value between 2 and 8.

Our Pipe Mania homage. Build a pipeline before the water escapes, and see if you can beat your own score.

grid and nextTiles are lists of tile values, from 0 to 8, and are copied to the screen in the draw function with the screen.blit operation. grid is a two-dimensional list, with sizes gridWidth=10 and gridHeight=7. Every pipe piece is placed in grid with a mouse click. This is managed with the Pygame functions on_mouse_move and on_mouse_down, where the variable pos contains the mouse position in the window. panelPosition defines the position of the top-left corner of the grid in the window. To get the grid cell, panelPosition is subtracted from pos, and the result is divided by tileSize with the integer division //. tileMouse stores the resulting cell element, but it is set to (-1,-1) when the mouse lies outside the grid.

The images folder contains the PNGs with the tile images, two for every tile: the graphical image and the path image. The tiles list contains the name of every tile, and adding to it _block or _path obtains the name of the file. The values stored in nextTiles and grid are the indexes of the elements in tiles.

wfmag46code
Here’s Jordi’s code for a Pipemania-style puzzler. To get it working on your system, you’ll need to install Pygame Zero. And to download the full code and assets, head here.

The image waterPath isn’t shown to the user, but it stores the paths that the water is going to follow. The first point of the water path is located in the starting tile, and it’s stored in currentPoint. update calls the function CheckNextPointDeleteCurrent, when the water starts flowing. That function finds the next point in the water path, erases it, and adds a new point to the waterFlow list. waterFlow is shown to the user in the draw function.

pointsToCheck contains a list of relative positions, offsets, that define a step of two pixels from currentPoint in every direction to find the next point. Why two pixels? To be able to define the ‘cross’ tile, where two lines cross each other. In a ‘cross’ tile the water flow must follow a straight line, and this is how the only points found are the next points in the same direction. When no next point is found, the game ends and the score is shown: the number of points in the water path, playState is set to 0, and no more updates are done.

Get your copy of Wireframe issue 46

You can read more features like this one in Wireframe issue 46, available directly from Raspberry Pi Press — we deliver worldwide.

wfcover

And if you’d like a handy digital version of the magazine, you can also download issue 46 for free in PDF format.

The post Code your own Pipe Mania puzzler | Wireframe #46 appeared first on Raspberry Pi.

Learning at home with the Raspberry Pi Foundation

As the UK — like many countries around the world — kicks off the new year with another national lockdown, meaning that millions of young people are unable to attend school, I want to share an update on how the Raspberry Pi Foundation is helping young people to learn at home.

Please help us spread the word to teachers, school leaders, governors, parents, and carers. Everything we are offering here is 100% free and the more people know about it, the more young people will benefit.

A girl and mother doing a homeschooling lesson at a laptop

Supporting teachers and pupils 

Schools and teachers all over the world have been doing a heroic job over the past ten months, managing the transition to emergency remote teaching during the first round of lockdowns, supporting the most vulnerable pupils, dealing with uncertainty, changing the way that schools worked to welcome pupils back safely, helping pupils catch up with lost learning, and much, much more.

Both in my role as Chief Executive of the Raspberry Pi Foundation and as chair of governors at a state school here in Cambridge, I’ve seen first-hand the immense pressure that schools and teachers are under. I’ve also seen them display the most amazing resilience, commitment, and innovation. I want to say a huge thank you to all teachers and school staff for everything you’ve done and continue to do to help young people through this crisis. 

Here’s some of the resources and tools that we’ve created to help you continue to deliver a world-class computing education: 

  • The Teach Computing Curriculum is a comprehensive set of lesson plans for KS1–4 (learners aged 5–16) as well as homework, progression mapping, and assessment materials.
  • Working with the fabulous Oak National Academy, we’ve produced 100 hours of video for 300 video lessons based on the Teach Computing Curriculum.
  • Isaac Computer Science is our online learning platform for advanced computer science (A level, learners aged 16–18) and includes comprehensive, interactive materials and videos. It also allows you to set your learners self-marking questions. 

All of these resources are mapped to the English computing curriculum and produced as part of the National Centre for Computing Education. They are available for everyone, anywhere in the world, for free. 

Making something fun with code

Parents and carers are the other heroes of remote learning during lockdown. I know from personal experience that juggling work and supporting home learning can be really tough, and we’re all trying to find meaningful, fun alternatives to letting our kids binge YouTube or Netflix (other video platforms and streaming services are available).

That’s why we’ve been working really hard to provide parents and carers with easy, accessible ways for you to help your young digital makers to get creative with technology:

A Coolest Projects participant

Getting computers into the hands of young people who need them 

One of the harsh lessons we learned last year was that far too many young people don’t have a computer for learning at home. There has always been a digital divide; the pandemic has just put it centre-stage. The good news is that the cost of solving this problem is now trivial compared to the cost of allowing it to persist.

That’s why the Raspberry Pi Foundation has teamed up with UK Youth and a network of grassroots youth and community organisations to get computers into the hands of disadvantaged young people across the UK.

A young person receives a Raspberry Pi kit to learn at home

For under £200 we can provide a vulnerable child with everything they need to learn at home, including a Raspberry Pi desktop computer, a monitor, a webcam, free educational software, and ongoing support from a local youth worker and the Foundation team. So far, we have managed to get 2000 Raspberry Pi computers into the hands of the most vulnerable young people in the UK. A drop in the ocean compared to the size of the problem, but a huge impact for every single young person and family.

This has only been possible thanks to the generous support of individuals, foundations, and businesses that have donated to support our work. If you’d like to get involved too, you can find out more here.

The post Learning at home with the Raspberry Pi Foundation appeared first on Raspberry Pi.

Meet team behind the mini Raspberry Pi–powered ISS

Quite possibly the coolest thing we saw Raspberry Pi powering last year was ISS Mimic, a mini version of the International Space Station (ISS). We wanted to learn more about the brains that dreamt up ISS Mimic, which uses data from the ISS to mirror exactly what the real thing is doing in orbit.

The ISS Mimic team’s a diverse, fun-looking bunch of people and they all made their way to NASA via different paths. Maybe you could see yourself there in the future too?

Dallas Kidd

Dallas in a green t shirt stood next to Estefannie in a black t shirt on a blue background. Estefannie is wearing safety googles
Dallas (in the green t shirt) having a lark with teammate Estefannie. Safety first!

Dallas Kidd currently works at the startup Skylark Wireless, helping to advance the technology to provide affordable high speed internet to rural areas.

Previously, she worked on traffic controllers and sensors, in finance on a live trading platform, on RAID controllers for enterprise storage, and at a startup tackling the problem of alarm fatigue in hospitals.

Before getting her Master’s in computer science with a thesis on automatically classifying stars, she taught English as a second language, Algebra I, geometry, special education, reading, and more.

Her hobbies are scuba diving, learning about astronomy, creative writing, art, and gaming.

Tristan Moody

Tristan Moody holding his kid Team ISS NASA
That’s Tristan on the right. NASA does not currently hire small children.

Tristan Moody currently works as a spacecraft survivability engineer at Boeing, helping to keep the ISS and other satellites safe from the threat posed by meteoroids and orbital debris.

He has a PhD in mechanical engineering and currently spends much of his free time as playground equipment for his two young kids.

Estefannie

Estefannie dressed up as Rey from Star Wars for the 2021 princesses with powertools calendar
Estefannie as Rey from Star Wars for the 2021 Princesses with Powertools calendar

Estefannie is a software engineer, designer, punk rocker and likes to overly engineer things and document her findings on her YouTube and Instagram channels as Estefannie Explains It All.

Estefannie spends her time inventing things before thinking, soldering for fun, writing, filming and producing content for her YouTube channel, and public speaking at universities, conferences, and hackathons.

She lives in Houston, Texas and likes tacos.

Douglas Kimble

A member of team ISS Mimic giving a thumbs up while working on the ISS Mimic
Where are the dogs, Douglas?!

Douglas Kimble currently works as an electrical/mechanical design engineer at Boeing. He has designed countless wire harness and installation drawings for the ISS.

He assumes the mentor role and interacts well with diverse personalities. He is also the world’s biggest Lakers fan living in Texas.

His favorite pastimes includes hanging out with his two dogs, Boomer and Teddy. 

Craig Stanton

A member of team ISS Mimic raising an eyebrow while working on the ISS Mimic hardware
Craig’s knows what’s up. Or knows a secret. We can’t tell. Maybe both?

Craig’s father worked for the Space Shuttle program, designing the ascent flight trajectories profiles for the early missions. He remembers being on site at Johnson Space Center one evening, in a freezing cold computer terminal room, punching cards for a program his dad wrote in the early 1980s.

Craig grew up with LEGO and majored in Architecture and Space Design at the University of Houston’s Sasakawa International Center for Space Architecture (SICSA).

His day job involves measuring ISS major assemblies on the ground to ensure they’ll fit together on-orbit. Traveling to many countries to measure hardware that will never see each other until on-orbit is the really coolest part of the job.

Sam Treagold

A member of team ISS Mimc sitting at a laptop
Sam: not to be trusted with hardware you don’t want shot in the desert

Sam Treadgold is an aerospace engineer who also works on the Meteoroid and Orbital Debris team, helping to protect the ISS and Space Launch System from hypervelocity impacts. Occasionally they take spaceflight hardware out to the desert and shoot it with a giant gun to see what happens.

In a non-pandemic world he enjoys rock climbing, music festivals, and making sound-reactive LED sunglasses.

Chen Deng

A member of team ISS Mimic showing off a solar panel
Chen showing off the very shiniest part of the ISS Mimic (solar panels)

Chen Deng is a Systems Engineer working at Boeing with the International Space Station (ISS) program. Her job is to ensure readiness of Payloads, or science experiments, to launch in various spacecraft and operations to conduct research aboard the ISS.

The ISS provides a very unique science laboratory environment, something we can’t get much of on earth: microgravity!  The term microgravity means a state of little or very weak gravity.  The virtual absence of gravity allows scientists to conduct experiments that are impossible to perform on earth, where gravity affects everything that we do.

In her free time, Chen enjoys hiking, board games, and creative projects alike.

Bryan Murphy

bryan murphy from team iss mimic at nasa
Bryan, adorned with an LED necklace, posing next to ISS Mimic’s rotating solar panel ‘wings’

Bryan Murphy is a dynamics and motion control engineer at Boeing, where he gets to create digital physics models of robotic space mechanisms to predict their performance.

His favorite projects include the ISS treadmill vibration isolation system and the shiny new docking system. He grew up on a small farm where his hands-on time with mechanical devices fueled his interest in engineering.

When not at work, he loves to brainstorm and create with his artist/engineer wife and their nerdy kids, or go on long family roadtrips—- especially to hike and kayak or eat ice cream. He’s also vice president of a local makerspace, where he leads STEM outreach and includes excess LEDs in all his builds.

Susan

A member of team ISS Mimic
Here’s Susan rocking some of those LED glasses and getting a good grip on ISS Mimic

Susan is a mechanical engineer and a 30+-year veteran of manned spaceflight operations.  She has worked the Space Shuttle Program for Payloads (middeck experiments and payloads deployed with the shuttle arm) starting with STS-30 and was on the team that deployed the Hubble Space Telescope.

She then transitioned into life sciences experiments, which led to the NASA Mir Program where she was on continuous rotation for three years to Russian Mission Control, supporting the NASA astronaut and science experiments onboard the space station as a predecessor to the ISS.

She currently works on the ISS Program (for over 20 years now), where she used to write procedures for on-orbit assembly of the Space Xtation and now writes installation procedures for on-orbit modifications like the docking adapter. She is also an artist and makes crosses out of found objects, and even used to play professional women’s football.

Keep in touch

Team ISS posing in NASA t shirts in front of the ISS mimic

You can keep up with Team ISS Mimic on FacebookInstagram, and Twitter. For more info or to join the team, check out their GitHub page and Discord.

Kids, run your code on the ISS!

Logo of the European Astro Pi Challenge

Did you know that there are Raspberry Pi computers aboard the real ISS that young people can run their own Python programs on? How cool is that?!

Find out how to participate at astro-pi.org.

The post Meet team behind the mini Raspberry Pi–powered ISS appeared first on Raspberry Pi.

Raspberry Pi ‘Swear Bear’ keeps your potty mouth in check

Why use a regular swear jar to retrain your potty-mouthed brain when you can build a Swear Bear to help you instead?

Swear Bear listens to you. All the time. And Swear Bear can tell when a swear word is used. Swear Bear tells you off and saves all the swear words you said to the cloud to shame you. Swear Bear subscribes to the school of tough love.

Artificial intelligence

The Google AIY kit allows you to build your own natural language recogniser. This page shows you how to assemble the Voice HAT from the kit, and it also includes the code you’ll need to make your project capable of speech-to-text AI.

Black AIY HAT stuck on top of a Raspberry Pi
Image of the Voice HAT mounted onto a Raspberry Pi 3 courtesy of aiyprojects.withgoogle.com

To teach Swear Bear the art of profanity detection, Swear Bear creators 8 Bits and a Byte turned to the profanity check Python library. You can find the info to install and use the library on this page, as well as info on how it works and why it’s so accurate.

You’ll hear at this point in the video that Swear Bear says “Oh dear” when a swear word is used within earshot.

Hardware

Birds eye view of each of the hardware components used in the project on a green table

This project uses the the first version of Google’s AIY Voice Kit, which comes with a larger black AIY Voice HAT and is compatible with Raspberry Pi 3 Model B. The kit also includes a little Voice HAT microphone board.

Version 2 of the kit comprises the smaller Raspberry Pi Zero WH and a slimmer ‘Voice Bonnet’.

The microphone allows Swear Bear to ‘hear’ your speech, and through its speakers it can then tell you off for swearing.

All of hardware is squeezed into the stuffing-free bear once the text-to-speech and profanity detection software is working.

Babbage Bear hack?

Babbage the Bear

8 Bits and a Byte fan Ben Scarboro took to the comments on YouTube to suggest they rework one of our Babbage Bears into a Swear Bear. Babbage is teeny tiny, so maybe you would need to fashion a giant version to accomplish this. Just don’t make us watch while you pull out its stuffing.

The post Raspberry Pi ‘Swear Bear’ keeps your potty mouth in check appeared first on Raspberry Pi.

Merry Christmas to all Raspberry Pi recipients — help is here!

Note: We’re not *really* here, we just dropped in to point you in the right direction with your new Raspberry Pi toys, then we’re disappearing again to enjoy the rest of the festive season. See you on 4 January 2021!

a raspberry pi 400 box peeking out of christmas wrapping paper
Photographer Brian’s wrapping skills are A+

So… what did you get? We launched a ton of new products this year, so we’ll walk you through what to do with each of them, as well as how to get started if you received a classic Raspberry Pi.

Community

First things first: welcome! You’re one of us now, so why not take a moment to meet your fellow Raspberry Pi folk and join our social communities?

You can hang out with us on Twitter, Facebook, LinkedIn, and Instagram. And we’ve got two YouTube channels: a channel for the tech fans and makers, and a channel for young people, parents, and educators. Subscribe to the one you like best — or even BOTH of them!

Tag us on social media in a photo with your favourite Christmas present and let us know what you plan to do with your new Raspberry Pi!

Raspberry Pi 400

Top view of a woman's hands using the Raspberry Pi 400 keyboard and official Raspberry Pi mouse
The nail polish that shook the internet

If you were lucky enough to get a Raspberry Pi 400 Personal Computer Kit, all you have to do is find a monitor (a TV will also do), plug in, and go. It really is that simple. In fact, when we launched it, Eben Upton described it as a “Christmas morning product”. Always thinking ahead, that guy.

If you got a Raspberry Pi 400 unit on its own, you’ll need to find a mouse and power supply as well as a monitor. You also won’t have received the official Raspberry Pi Beginner’s Guide that comes with the kit, so you can pick one up from the Raspberry Pi Press online store, or download a PDF for free, courtesy of The MagPi magazine.

Raspberry Pi High Quality Camera

Raspberry Pi High Quality Camera, with additional lens attached

You are going to LOVE playing around with this if you got one in your stocking. The Raspberry Pi High Quality Camera is 12.3 megapixels of fun, and the latest addition to the Raspberry Pi camera family.

This video shows you how to set up your new toy. And you can pick up the Official Raspberry Pi Camera Guide for a more comprehensive walkthrough. You can purchase the book in print today from the Raspberry Pi Press store for £10, or download the PDF for free from The MagPi magazine website.

Share your photos using #ShotOnRaspberryPi. We retweet the really good ones!

Operating systems & online support

Adorable family snap

If you got one of our classic Raspberry Pi boards, make sure to get the latest version of Raspberry Pi OS, our official supported operating system.

The easiest way to flash the OS onto your SD card is using the Raspberry Pi Imager. Take 40 seconds to watch the video below to learn how to do that.

Help for newbies

If you’re a complete newbie, our help pages are the best place to start in case you’re a bit daunted by where to plug everything in on your very first Raspberry Pi. If you want step-by-step help, you can also take our free online course “Getting Started with Your Raspberry Pi”.

Once you’ve got the hang of things, our forum will become your home from home. Gazillions of Raspberry Pi superfans hang out there and can answer pretty much any question you throw at them – try searching first, because many questions have already been asked and answered, and perhaps yours has too.

Robots, games, digital art & more

screen grab of raspberry pi projects homepage

When you’re feeling comfortable with the basics, why not head over to our projects page and pick something cool to make?

You could program your own poetry generator, create an alien language, or build a line-following robot. Choose from over 200 step-by-step projects!

The Raspberry Pi blog is also a great place to find inspiration. We share the best projects from our global community, and things for all abilities pop up every week day. If you want us to do the heavy lifting for you, just sign up to Raspberry Pi Weekly, and we’ll send you the top blogs and Raspberry Pi-related news each week.

Babbage Bear

What a QT

And if you got your very own Babbage Bear: love them, cherish them, and keep them safe. They’re of a nervous disposition so talk quietly to them for the first few days, to let them get used to you.

LOVE YOU, BYE

The post Merry Christmas to all Raspberry Pi recipients — help is here! appeared first on Raspberry Pi.

Raspberry Pi Imager update

Just in time for the holidays, we’ve updated Raspberry Pi Imager to add some new functionality.

  • New submenu support: previous versions of Raspberry Pi Imager were limited to a single level of submenu. This limitation has been fixed so we can group images into different categories, such as general purpose operating systems, media players, and gaming and emulation.
  • New icons from our design team: easy on the eyes!
  • Version tracking: the menu file that Imager downloads from the Raspberry Pi website now includes an entry defining its latest version number, so in future, we can tell you when an updated Imager application is available.
  • Download telemetry: we’ve added some simple download telemetry to help us log how popular the various operating systems are.

You can go to our software page to download and install the new version 1.5 release of Raspberry Pi Imager and use it now.

We haven’t done telemetry in Imager before, and since people tend — rightly — to be concerned about applications gathering data, we want to explain exactly what we are doing and why: we’re logging which operating systems and categories people download, so we can make sure the most popular options are easy enough to find in Raspberry Pi Imager’s menu system.

We don’t record any personal data, such as your IP address; the information we collect allows us to see the number of downloads of each operating system over time, and nothing else. You’ll find more detailed information, including how to opt out of telemetry, in the Raspberry Pi Imager GitHub README.md.

You can see which OSes are most often downloaded too, on our stats page.

As you can see, the default recommended Raspberry Pi OS image is indeed the most downloaded option. The recently released Ubuntu Desktop for Raspberry Pi 4 and Raspberry Pi 400 is the most popular third-party operating system.

The post Raspberry Pi Imager update appeared first on Raspberry Pi.

Add face recognition with Raspberry Pi | Hackspace 38

It’s hard to comprehend how far machine learning has come in the past few years. You can now use a sub-£50 computer to reliably recognise someone’s face with surprising accuracy.

Although this kind of computing power is normally out of reach of microcontrollers, adding a Raspberry Pi computer to your project with the new High Quality Camera opens up a range of possibilities. From simple alerting applications (‘Mum’s arrived home!’), to dynamically adjusting settings based on the person using the project, there’s a lot of fun to be had.

Here’s a beginner’s guide to getting face recognition up and running.

Face recognition using machine learning is hard work, so the latest, greatest Raspberry Pi 4 is a must

1. Prepare your Raspberry Pi
For face recognition to work well, we’re going to need some horsepower, so we recommend a minimum of Raspberry Pi 3B+, ideally a Raspberry Pi 4. The extra memory will make all the difference. To keep as much resource as possible available for our project, we’ve gone for a Raspberry Pi OS Lite installation with no desktop.

Make sure you’re on the network, have set a new password, enabled SSH if you need to, and updated everything with sudo apt -y update && sudo apt -y full-upgrade. Finally, go into settings by running sudo raspi-config and enable the camera in ‘Interfacing Options’.

2. Attach the camera
This project will work well with the original Raspberry Pi Camera, but the new official HQ Camera will give you much better results. Be sure to connect the camera to your Raspberry Pi 4 with the power off. Connect the ribbon cable as instructed in hsmag.cc/HQCameraGetStarted. Once installed, boot up your Raspberry Pi 4 and test the camera is working. From the command line, run the following:
raspivid -o test.h264 -t 10000
This will record ten seconds of video to your microSD card. If you have an HDMI cable plugged in, you’ll see what the camera can see in real-time. Take some time to make sure the focus is correct before proceeding.

3. Install dependencies
The facial recognition library we are using is one that has been maintained for many years by Adam Geitgey. It contains many examples, including Python 3 bindings to make it really simple to build your own facial recognition applications. What is not so easy is the number of dependencies that need to be installed first. There are way too many to list here, and you probably won’t want to type them out, so head over to hsmag.cc/FacialRec so that you can cut and paste the commands. This step will take a while to complete on a Raspberry Pi 4, and significantly longer on a Model 3 or earlier.

3. Install the libraries
Now that we have everything in place, we can install Adam’s applications and Python bindings with a simple, single command:
sudo pip3 install face_recognition
Once installed, there are some examples we can download to try everything out.
cd
git clone --single-branch https://github.com/ageitgey/face_recognition.git
In this repository is a range of examples showing the different ways the software can be used, including live video recognition. Feel free to explore and remix.

5. Example images
The examples come with a training image of Barack Obama. To run the example:
cd ./face_recognition/examples
python3 facerec_on_raspberry_pi.py

On your smartphone, find an image of Obama using your favourite search engine and point it at the camera. Providing focus and light are good you will see:
“I see someone named Barack Obama!”
If you see a message saying it can’t recognise the face, then try a different image or try to improve the lighting if you can. Also, check the focus for the camera and make sure the distance between the image and camera is correct.

Who are you? What even is a name? Can a computer decide your identity?

6. Training time
The final step is to start recognising your own faces. Create a directory and, in it, place some good-quality passport-style photos of yourself or those you want to recognise. You can then edit the facerec_on_raspberry_pi.py script to use those files instead. You’ve now got a robust prototype of face recognition. This is just the beginning. These libraries can also identify ‘generic’ faces, meaning it can detect whether a person is there or not, and identify features such as the eyes, nose, and mouth. There’s a world of possibilities available, starting with these simple scripts. Have fun!

Issue 38 of Hackspace Magazine is out NOW

Front cover of hack space magazine featuring a big striped popcorn bucket filled with maker tools and popcorn

Each month, HackSpace magazine brings you the best projects, tips, tricks and tutorials from the makersphere. You can get it from the Raspberry Pi Press online store, The Raspberry Pi store in Cambridge, or your local newsagents.

Each issue is free to download from the HackSpace magazine website.

The post Add face recognition with Raspberry Pi | Hackspace 38 appeared first on Raspberry Pi.

The Stargate | The MagPi 101

Fans of the Stargate SG-1 series, prepare to be inspired: a fellow aficionado has fashioned his own model of the show’s iconic portal. Nicola King takes an interstellar trip in the latest issue of The MagPi Magazine.

A mini version of the Stargate from TV sat on a table. Blue glowing light emits from the fake tunnel

When Kristian Tysse began making some projects on his new 3D printer, he soon became aware that the possibility of printing his own ‘working’ Stargate SG-1 model was within his grasp at last. “I suddenly realised I might now have enough knowledge about 3D printing, Raspberry Pi, motors, and programming to actually make a Stargate model of my own,” he tells us. “I wanted people who are familiar with the show to immediately know what it was, and tried to make it work as best I could, while staying as true as possible to the feeling and essence of the TV show.”

Raspberry Pi buried in the wires powering the mini stargate

Kristian also wanted to use a Raspberry Pi within this fully interactive, light-up, moving-parts project as “it is a powerful device with lots of flexibility. I do like that it functions as a full computer with an operating system with all the possibility that brings.”

Model minutiae

The back of the stargate controller with no lights on

You only have to look at the model to see just how much 3D printing was needed to get all of the parts ready to piece together, and Kristian created it in segments. But one of the key parts of his model is the DHD or Dial Home Device which viewers of the series will be familiar with. “The DHD functions as a USB keyboard and, when the keys are used, it sends signals to the (Python) program on Raspberry Pi that engages the different motors and lights in a proper Stargate way,” he enthuses. “If a correct set of keys/symbols are pressed on the DHD, the wormhole is established – illustrated on my Stargate with an infinity mirror effect.” 

“I wanted people who are familiar with the show to immediately know what it was”

Kristian Tysse

However, the DHD was a challenge, and Kristian is still tweaking it to improve how it works. He admits that writing the software for the project was also tricky, “but when I think back, the most challenging part was actually making it ‘functional’, and fitting all the wires and motors on it without destroying the look and shape of the Stargate itself.”

Dazzling detail

A close up of the stargate control panel with glowing orange touch buttons

Kristian admits to using a little artistic licence along the way, but he is keen to ensure the model replicates the original as far as possible. “I have taken a few liberties here and there. People on the social media channels are quick to point out differences between my Stargate and the one in the series. I have listened to most of those and done some changes. I will implement some more of those changes as the project continues,” he says. He also had to redesign the project several times, and had a number of challenges to overcome, especially in creating the seven lit, moving chevrons: “I tried many different approaches before I landed on the right one.”

The results of Kristian’s time-intensive labours are truly impressive, and show what you can achieve when you are willing to put in the hours and the attention to detail. Take a look at Kristian’s extremely detailed project page to see more on this super-stellar make.

Issue #101 of The MagPi Magazine out NOW

The front cover of the magazine featuring Raspberry Pi 400

Never want to miss an issue? Subscribe to The MagPi and we’ll deliver every issue straight to your door. Also, if you’re a new subscriber and get the 12-month subscription, you’ll get a completely free Raspberry Pi Zero bundle with a Raspberry Pi Zero W and accessories.


The post The Stargate | The MagPi 101 appeared first on Raspberry Pi.

Save the date for Coolest Projects 2021

The year is drawing to a close, and we are so excited for 2021!

More than 700 young people from 39 countries shared their tech creations in the free Coolest Projects online showcase this year! We loved seeing so many young people shine with their creative projects, and we can’t wait to see what the world’s next generation of digital makers will present at Coolest Projects in 2021.

A Coolest Projects participant showing off their tech creation

Mark your calendar for registration opening

Coolest Projects is the world-leading technology fair for young people! It’s our biggest event, and we are running it online again next year so that young people can participate safely and from wherever they are in the world.

Through Coolest Projects, young people are empowered to show the world something they’re making with tech — something THEY are excited about! Anyone up to age 18 can share their creation at Coolest Projects.

  • A Coolest Projects participant
  • A boy presenting his digital making project

On 1 February, we will open registrations for the 2021 online showcase. Mark the date in your calendar! All registered projects will get their very own spot in the Coolest Projects online showcase gallery, where the whole world can discover them.

Taking part is completely free and enormously fun

If a young person in your life — your family, your classroom, your coding club — is making something with tech that they love, we want them to register it for Coolest Projects. It doesn’t matter how small or big their project is, because the Coolest Projects showcase is about celebrating the love we all share for getting creative with tech.

A teenage girl presenting a digital making project on a tablet

Everyone who registers a project becomes part of a worldwide community of peers who express themselves and their interests with creative tech. We will also have special judges pick their favourite projects! Taking part in Coolest Projects is a wonderful way to connect with others, be inspired, and learn from peers.

So if you know a tech-loving young person, get them excited for taking part in Coolest Projects!

“We are so very happy to have reached people who love to code and are enjoying projects from all over the world…everyone’s contributions have blown our minds…we are so so happy ️:woman-cartwheeling:️Thank you to Coolest Projects for hosting the best event EVER :star::star::star:

– mother of a participant in the 2020 online showcase

Want inspiration for projects? You can still explore all the wonderful projects from the 2020 showcase gallery.

A Coolest Projects participant

Young people can participate with whatever they’re making

Everyone is invited to take part in Coolest Projects — the showcase is for young people with any level of experience. The project they register can be whatever they like, from their very first Scratch animation, to their latest robotics project, website, or phone app. And we invite projects at any stages of the creation process, whether they’re prototypes, finished products, or works-in-progress!

  • To make the youngest participants and complete beginners feel like they belong, we work hard to make sure that taking part is a super welcoming and inspiring experience! In the showcase, they will discover what is possible with technology and how they can use it to shape their world.
  • And for the young creators who are super tech-savvy and make advanced projects, showcasing their creation at Coolest Projects is a great way to get it seen by some amazing people in the STEM sector: this year’s special judges were British astronaut Tim Peake, Adafruit CEO Limor Fried, and other fabulous tech leaders!

Sign up for the latest Coolest Projects news

To be the first to know when registration opens, you only have to sign up for our newsletter:

We will send you regular news about Coolest Projects to keep you up to date and help you inspire the young tech creator in your life!

The post Save the date for Coolest Projects 2021 appeared first on Raspberry Pi.

Raspberry Pi and Google Code Next bring computer science to 1000 Chicago students

Par : Alex Bate

To round off Computer Science Education Week 2020, the Google Code Next team, working with the Raspberry Pi Foundation and some incredible volunteers in the Chicago area, helped over 400 Black and Latinx high school students get coding using Raspberry Pi 400. Here’s Omnia Saed with more.

In partnership with Google Code Next, the Raspberry Pi Foundation curated a computer science activity for over 400 Chicago Public Schools students. Over 1000 kits with the newly released Raspberry Pi 400 were sent to six public schools to mark the end of Computer Science Education Week (7-14 December).

Can you tell we miss hands-on work? Students were excited to get home & setup their @Raspberry_Pi Thanks again @Google #CodeNext for this opportunity! Let’s see where this #ComputerScienceWeek takes them @CPSNetwork16 @ChiPubSchools @CSEdWeek @cs4allcps pic.twitter.com/81jBGxhzF9

— Kelly College Prep SkillsUSA (@Kelly_SkillsUSA) December 8, 2020

Google Code Next

Google Code Next is a free computer science education program for Black and Latinx high school students. Between 2011 and 2018, Black and Hispanic college students each only made up 3 percent of computer science graduates; Code Next works to change that. The program provides students with the skills and inspiration needed for long and rewarding careers in computer science.

“We aim to provide Black and Latinx students with skills and technical social capital — that web of relationships you can tap into,” said Google Diversity STEM Strategist Shameeka Emanuel.

The main event

The virtual event brought over 80 Google volunteers, students and teachers together to create their very own “Raspimon”—a virtual monster powered by Raspberry Pi. For many students, it was their first time coding.

Matt Richardson, Executive Director of the Raspberry Pi Foundation North America, opened the event by telling students to share their work with family and friends.

“I hope you find new ways to solve problems or express yourselves creatively. More importantly, be sure to share what you create with someone you know – you might just spark curiosity in someone else,” he said.

Day 2 of pickups of @RapsberryPi_f Raspimon Activity kits! About 170 kits have been picked up from our students! As you can see, they’re ready for @Google #CodeNext session on Saturday @ThomasKelly_HS @cs4allcps @CPSNetwork16 @ChiPubSchools #CSEdWeek2020 pic.twitter.com/x8WC1uipbb

— Kelly College Prep SkillsUSA (@Kelly_SkillsUSA) December 9, 2020

In an interview with the Chicago Sun Times, Troy Williams, Chicago Public Schools interim director of computer science, explains, “Our students being able to have access to these Raspberry Pis and other resources supplements the learning they’re doing in the classrooms, and brings another level of engagement where they can create on their own. It really helps toward closing the digital divide and the learning gap as well.”

Want to join in with the fun? You’ll find a copy of the activity and curriculum on the Code Next website.

Top view of a woman's hands using the Raspberry Pi 400 keyboard and official Raspberry Pi mouse

And if you’re looking to introduce someone to coding over the holidays, there’s still time to order a Raspberry Pi 400 computer kit from our network of Raspberry Pi Approved Resellers.

The post Raspberry Pi and Google Code Next bring computer science to 1000 Chicago students appeared first on Raspberry Pi.

Supporting Raspberry Pi’s industrial customers

Raspberry Pi computers have always been used in a huge variety of settings, since the combination of low cost, high performance, and ease of use make it an ideal device for almost any application. We’ve seen a large proportion of sales go into the industrial market – businesses using Raspberry Pi, rather than educational settings or individual consumers. Today we’re announcing new support for this group of customers: a dedicated area of our website for industry, and our Raspberry Pi Approved Design Partners programme, connecting businesses that want to integrate Raspberry Pi into their products with hand-picked design partners who can help.

Screenshot from our Industrial web page featuring top performance stats

The industrial market for Raspberry Pi has grown over the years, and now represents around 44% of our annual total sales. We’ve seen this borne out with new releases of Raspberry Pi products: typically sales of a consumer product drop off once a new product is released, but we still see incredible sales of older models of Raspberry Pi. Our inference is that these are destined for embedded applications, where changing to the latest model is not practical. 

A new online resource for industry

To support Raspberry Pi’s industrial customers, we have developed a new, dedicated area of our website. Our For industry pages are the best place to go for industrial applications of Raspberry Pi. They provide access to the information and support you need when using our products in an industrial setting, with links to datasheets, compliance documents, and more.

As part of our commitment to industrial customers, we guarantee product lifetimes until at least 2026 on all products. We rarely ever end a product line – in fact, you can still buy Raspberry Pi 1 Model B+ from 2014. And we’ve made it easy for you to take a product through the necessary regulatory compliance steps, with the Raspberry Pi Integrator Programme.

Raspberry Pi Approved Design Partners

Along with our online resources for industry, we’re announcing a new programme to help customers who want to integrate Raspberry Pi into their products, and to recognise companies with specialist knowledge and proven expertise in designing with Raspberry Pi. The Raspberry Pi Approved Design Partners programme is a way of connecting trusted design consultancies with customers who need support designing Raspberry Pi computing solutions into their products. 

We’re launching with a select set of designers whom we already know and work with, and we hope to grow this group over the coming years. If your company provides hardware, software, or mechanical design services with Raspberry Pi, and you’d like us to promote your offering on our website, you can find out more about applying to become a Raspberry Pi Approved Design Partner.

If you have a product or a piece of work that uses Raspberry Pi, and you need technical assistance, Raspberry Pi Approved Design Partners have the capacity to provide you with effective help. All our Design Partners have been through a rigorous application process, and we will monitor them regularly for quality and ability. You can be confident that Raspberry Pi Approved Design Partners have the backing of Raspberry Pi, and have access to a deep level of technical knowledge and support within Raspberry Pi. 

We’re excited to help customers build fantastic products using Raspberry Pi, and we’re looking forward to working with a diverse range of designers across the world.

The post Supporting Raspberry Pi’s industrial customers appeared first on Raspberry Pi.

Adafruit guest post: Machine learning add-ons for Raspberry Pi

Par : Ladyada

Hi folks, Ladyada here from Adafruit. The Raspberry Pi folks said we could do a guest post on our Adafruit BrainCraft HAT & Voice Bonnet, so here we go!

Adafruit BrainCraft HAT on top of a  Raspberry Pi
Adafruit BrainCraft HAT for Raspberry Pi

I’ve been engineering up a few Machine Learning devices that work with Raspberry Pi: BrainCraft HAT and the Voice Bonnet!

The idea behind the BrainCraft HAT is to enable you to “craft brains” for machine learning on the EDGE, with microcontrollers and microcomputers. On ASK AN ENGINEER, we chatted with Pete Warden, the technical lead of the mobile, embedded TensorFlow Group on Google’s Brain team about what would be ideal for a board like this.

BrainCraft HAT

And here’s what we designed! The BrainCraft HAT has a 240×240 TFT IPS display for inference output, slots for camera connector cable for imaging projects, a 5-way joystick, a button for UI input, left and right microphones, stereo headphone out, stereo 1W speaker out, three RGB DotStar LEDs, two 3-pin STEMMA connectors on PWM pins so they can drive NeoPixels or servos, and Grove/STEMMA/Qwiic I2C port.

This will let people build a wide range of audio/video AI projects while also allowing easy plug-in of sensors and robotics!

A controllable mini fan attaches to the bottom and can be used to keep your Raspberry Pi cool while it’s doing intense AI inference calculations. Most importantly, there’s an on/off switch that will completely disable the audio codec, so that when it’s off, there’s no way it’s listening to you.

Check it out here, and get all the learning guides.

Voice Bonnet

Adafruit Voice Bonnet atop a  Raspberry Pi
Adafruit Voice Bonnet for Raspberry Pi

Next up, the Adafruit Voice Bonnet for Raspberry Pi: two speakers plus two mics. Your Raspberry Pi computer is like an electronic brain — and with the Adafruit Voice Bonnet you can give it a mouth and ears as well! Featuring two microphones and two 1Watt speaker outputs using a high-quality I2S codec, this Raspberry Pi add-on will work with any Raspberry Pi with a 2×20 GPIO header, from Raspberry Pi Zero up to Raspberry Pi 4 and beyond (basically all models but the very first ones made).

The on-board WM8960 codec uses I2S digital audio for great quality recording and playback, so it sounds a lot better than the headphone jack on Raspberry Pi (or the no-headphone jack on Raspberry Pi Zero). We put ferrite beads and filter capacitors on every input and output to get the best possible performance, and all at a great price.

We specifically designed this bonnet for use when making machine learning projects such as DIY voice assistants. For example, see this guide on creating a DIY Google Assistant.

But you could do various voice-activated or voice recognition projects. With two microphones, basic voice position can be detected as well. Check it out here, and see the guides as well!

The post Adafruit guest post: Machine learning add-ons for Raspberry Pi appeared first on Raspberry Pi.

Four new products: IQaudio is now Raspberry Pi

We’re delighted to round off 2020 by welcoming four of the most popular IQaudio products to the Raspberry Pi fold. DAC+, DAC Pro, DigiAMP+, and Codec Zero will all be available to buy via our network of Raspberry Pi Approved Resellers.

We’ve had a busy 2020 here at Raspberry Pi. From the High Quality Camera to 8GB Raspberry Pi 4 to Compute Module 4 and Raspberry Pi 400, this year’s products have been under development for several years, and bringing them to market required us to build new capabilities in the engineering team. Building capabilities, rather than money or engineer time, is the real rate-limiting step for introducing new Raspberry Pi products.

One market we’ve never explored is hi-fi audio; this is a world unto itself, with a very demanding customer base, and we’ve never felt we had the capabilities needed to offer something distinctive. Over time, third parties have stepped in with a variety of audio I/O devices, amplifiers, and other accessories.

IQaudio

Founded by Gordon and Sharon Garrity together with Andrew Rankin in 2015, IQaudio was one of the first companies to recognise the potential of Raspberry Pi as a platform for hi-fi audio. IQaudio products are widely used by hobbyists and businesses (in-store audio streaming being a particularly popular use case). So when the opportunity arose to acquire IQaudio’s brand and product line late last year, we jumped at it.

Today we’re relaunching four of the most popular IQaudio products, at new affordable price points, via our network of Raspberry Pi Approved Resellers.

IQaudio DAC+

Priced at just $20, DAC+ is our lowest-cost audio output HAT, supporting 24‑bit 192kHz high-resolution digital audio. It uses a Texas Instruments PCM5122 DAC to deliver stereo analogue audio to a pair of phono connectors, and also provides a dedicated headphone amplifier.

IQaudio DAC+ HAT

IQaudio DAC Pro

Priced at $25, DAC Pro is our highest-fidelity audio output HAT. It supports the same audio input formats and output connectors as DAC+, but uses a Texas Instruments PCM5242 DAC, providing an even higher signal-to-noise ratio.

IQaudio DAC Pro HAT

In combination with an optional daughter board (due for relaunch in the first quarter of 2021), DAC Pro can support balanced output from a pair of XLR connectors.

IQaudio DigiAMP+

Where DAC+ and DAC Pro are designed to be used with an external amplifier, DigiAMP+ integrates a Texas Instruments TAS5756M digital-input amplifier directly onto the HAT, allowing you to drive a pair of passive speakers at up to 35W per channel. Combined with a Raspberry Pi board, it’s a complete hi-fi that’s the size of a deck of cards.

IQaudio DigiAMP+ HAT

DigiAMP+ is priced at $30, and requires an external 12-21V 3A DC power supply, sold separately. XP Power’s VEC65US19, available here and here, is a suitable supply.

IQaudio Codec Zero

Codec Zero is a $20 audio I/O HAT, designed to fit within the Raspberry Pi Zero footprint. It is built around a Dialog Semiconductor DA7212 codec and supports a range of input and output devices, from the built-in MEMS microphone to external mono electret microphones and 1.2W, 8 ohm mono speakers.

IQaudio Codec Zero HAT

Unlike the other three products, which are in stock with our Approved Resellers now, Codec Zero will ship early in the New Year.

So there you have it. Four (nearly) new Raspberry Pi accessories, just in time for Christmas – hop over and buy yours now. This is the first time we’ve brought third-party products into our line-up like this; we’d like to thank the team at IQaudio for their help in making the transition.

The post Four new products: IQaudio is now Raspberry Pi appeared first on Raspberry Pi.

Block-based programming: does it help students learn?

At the Raspberry Pi Foundation, we are continually inspired by young learners in our community: they embrace digital making and computing to build creative projects, supported by our resources, clubs, and volunteers. While creating their projects, they are learning the core programming skills that underlie digital making.

Over the years, many tools and environments have been developed to make programming more accessible to young people. Scratch is one example of a block-based programming environment for young learners, and it’s been shown to make programming more accessible to them; on our projects site we offer many step-by-step Scratch project resources.

Mark Scratch
A Scratch code-along, led by one of our educators on our weekly Digital Making at Home live stream

But does block-based programming actually help learning? Does it increase motivation and support students? Where is the hard evidence? In our latest research seminar, we were delighted to hear from Dr David Weintrop, an Assistant Professor at the University of Maryland who has done research in this area for several years and published widely on the differences between block-based and text-based programming environments.

David Weintrop

A variety of block-based programming environments

The first useful insight David shared was that we should avoid thinking about block-based programming as synonymous with the well-known Scratch environment. There are several other environments, with different affordances, that David referred to in his talk, such as Snap, Pencil Code, Blockly, and more.

Logos of block-based programming environments

Some of these, for example Pencil Code, offer a dual-modality (or hybrid) environment, where learners can write the same program in a text-based and a block-based programming environment side by side. Dual-modality environments provide this side-by-side approach based on the assumption that being able to match a text-based program to its block-based equivalent supports the development of understanding of program syntax in a text-based language.

Screenshot of the Pencil Code dual-modality programming environment

As a tool for transitioning to text-based programming

Another aspect of the research around block-based programming focuses on its usefulness as a transition to a text-based language. David described a 15-week study he conducted in high schools in the USA to investigate differences in student learning caused by use of block-based, text-based, and hybrid (a mixture of both using a dual-modality platform) programming tools.

Details of the study design: classroom-based, 3 conditions, 2 phases, quasi-experimental mixed method study

The 90 students in the study (14 to 16 years old) were divided into three groups, each with a different intervention but taught by the same teacher. In the first phase of the study (5 weeks), the groups were set the same tasks with the same learning objectives, but they used either block-based programming, text-based programming, or the hybrid environment.

After 5 weeks, students were given a test to assess learning outcomes, and they were asked questions about their attitudes to programming (specifically their perception of computing and their confidence). In the second phase (10 weeks), all the students were taught Java (a common language taught in the USA for end-of-school assessment), and then the test and attitudinal questions were repeated.

The results showed that at the 5-week point, the students who had used block-based programming scored higher in their learning outcome assessment, but at the final assessment after 15 weeks, all groups’ scores were roughly equivalent.  

A graph of assessment scores of the three groups in the study. The final scores are not significantly different.

In terms of students’ perception of computing and confidence, the responses of the Blocks group were very positive at the 5-week point, while at the 15-week point, the responses were less positive. The responses from the Text group showed a gradual increase in positivity between the 5- and 15-week points. The Hybrid group’s responses weren’t as negative as those of the Text group at the 5-week point, and their positivity didn’t decrease like the Blocks group’s did.

Taking both methods of assessment into account, the Hybrid group showed the best results in the study. The gains associated with the block-based introduction to programming did not translate to those students being further ahead when learning Java, but starting with block-based programming also did not hamper students’ transition to text-based programming.

David completed his talk by recommending dual-modality environments (such as Pencil Code) for teaching programming, as used by the Hybrid group in his study. 

More research is needed

The seminar audience raised many questions about David’s study, for example whether the actual teaching (pedagogy) may have differed for the three groups, and whether the results are not just due to the specific tools or environments that were used. This is definitely an area for further research. 

It seems that students may benefit from different tools at different times, which is why a dual-modality environment can be very useful. Of course, competence in programming takes a long time to develop, so there is room on the research agenda for longitudinal studies that monitor students’ progress over many months and even years. Such studies could take into account both the teaching approach and the programming environment in order to determine what factors impact a deep understanding of programming concepts, and students’ desire to carry on with their programming journey. 

Next up in our series

If you missed the seminar, you can find David’s presentation slides and a recording of his talk on our seminars page.

Our next free online seminar takes place on Tuesday 5 January at 17:00–18:00 BST / 12:00–13:00 EDT / 9:00–10:00 PDT / 18:00–19:00 CEST. We’ll welcome Peter Kemp and Billy Wong, who are going to share insights from their research on computing education for underrepresented groups. To join this free online seminar, simply sign up with your name and email address.

Once you’ve signed up, we’ll email you the seminar meeting link and instructions for joining. If you attended David’s seminar, the link remains the same.

The January seminar will be the first one in our series focusing on diversity and inclusion in computing education, which we’re co-hosting with the Royal Academy for Engineering. We hope to see you there!

The post Block-based programming: does it help students learn? appeared first on Raspberry Pi.

New book: Help! My computer is broken

Surprise! We thought we’d squeeze in another shiny new thing for you before the year is out. And it’ll make a cracking Christmas present.

Our brand new book Help! My Computer is Broken (How do I fix it?) takes the most common computer problems and tells you how to fix them.

Who is it for?

Front cover of the book featuring two cartoon people struggling over a broken computer

It’s “the intolerant person’s guide to keeping your computer computing.” If that sounds like you, we recommend you hop straight over to the Raspberry Pi Press online store and pick up a copy for just £10.

What’s it about?

It also makes a good, only mildly passive-aggressive, gift. If the above text messages ring a bell, and you’re fed up with being the in-house tech support for your family, then Help! My computer is broken (How do I fix it?) can assist. It shows readers how to fix common computer problems, without having to wade through technical jargon or pester said tech support person.

Who wrote it?

the book open showing a page about computers sleep mode

We had the brilliant Barry Collins, who has been a technology journalist for more than 20 years, write it for you. He’s written for most of the UK’s leading tech publications, and he is a former editor of PC Pro as well as former assistant editor of the Sunday Times‘ technology section.

the book open on a page about spotting data fraud

He’s now co-editor of The Big Tech Question, a site designed to answer people’s tech queries – in a similar vein to this book. Barry also makes regular appearances as a tech pundit on TV and radio.

Where can I buy it?

the book open on a page about cleaning computer screens

You can buy Help! My computer is broken (How do I fix it?) now from the Raspberry Pi Press online store, or at the Raspberry Pi store in Cambridge, UK.

Our lovely friends at Wireframe magazine have also made a free PDF version available.

Extra Christmas cheer for you

A selection of Raspberry Pi books on a table surrounded by Christmas decorations

While you’re shopping at the Raspberry Pi Press online store, make sure you check out our Black Friday deal, which we’ve decided to keep rolling until Christmas Eve.

If you buy just one book from the Black Friday range (priced £7 – £10), you get two more completely FREE!

The post New book: Help! My computer is broken appeared first on Raspberry Pi.

Gifts that last all year round

What if you could give the joy of opening a Raspberry Pi–themed gift every single month for a whole year? But what if the thought of wrapping 12 individual things fills you with Scrooge-level dread?

Snap up a magazine subscription for one of your nearest and/or dearest and we’ll take care of the packaging and delivery while you sit back and reap all the credit!

You could end up with a few extra gifts depending on what you sign up for so, read on and take your pick.

The MagPi magazine

Magpi magazines fanned out with free gift to the side of them

The official Raspberry Pi magazine comes with a free Raspberry Pi Zero W kit worth £20 when you sign up for a 12-month subscription. You can use our tiniest computer in tonnes of projects, meaning Raspberry Pi fans can never have enough. That’s a top gift-giving bonus for you right there.

Every issue of The MagPi is packed with computing and electronics tutorials, how-to guides, and the latest news and reviews. They also hit their 100th issue this month so, if someone on your list has been thinking about getting a subscription, now is a great time.

Check out subscription deals on the official Raspberry Pi Press store.

HackSpace magazine

Hackspace magazines fanned out with adafruit gift on top

HackSpace magazine is the one to choose for fixers and tinkerers of all abilities. If you’re looking for a gift for someone who is always taking things apart and hacking everyday objects, HackSpace magazine will provide a year of inspiration for them.

12-month subscriptions come with a free Adafruit Circuit Playground Express, which has been specially developed to teach programming novices from scratch and is worth £25.

Check out subscription deals on the official Raspberry Pi Press store.

Custom PC

Some Custom PC magazines fanned out with the free giveaway mouse on top of them

Custom PC is the magazine for people who are passionate about PC technology and hardware. And they’ve just launched a pretty cool new giveaway with every 12-month subscription: a free Chillblast Aero RGB Gaming mouse worth £40. Look, it lights up, it’s cool.

Check out subscription offers on the official Raspberry Pi Press store.

Wireframe magazine

Latest issue of wireframe magazine with some of the free books on offer next to it

Wireframe magazine lifts the lid on video games. In every issue, you’ll find out how games are made, who makes them, and how you can code them to play for yourself using detailed guides.

The latest deal gets you three issues for just £10, plus your choice of one of our official books as a gift. By the way, that ‘three for £10 plus a free book’ is available across ALL our magazines. Did I not tell you that before? My bad. It’s good though, right?

Check out more subscriptions deals on the official Raspberry Pi Press store.

Three books for the price of one

A selection of Raspberry Pi books on a table surrounded by Christmas decorations

And as an extra Christmas gift to you all, we’ve decided to keep our Black Friday deal rolling until Christmas Eve, so if you buy just one teeny tiny book from the Raspberry Pi Press store, you get two more completely FREE!

Better still, all of the books in the deal only cost £7 or £10 to start with, so makes for a good chunky batch of presents at a brilliantly affordable price.

The post Gifts that last all year round appeared first on Raspberry Pi.

100 Raspberry Pi moments

The official Raspberry Pi magazine turned 100 this month! To celebrate, the greatest Raspberry Pi moments, achievements, and events that The MagPi magazine has ever featured came back for a special 100th issue.

100 Raspberry Pi Moments is a cracking bumper feature (starting on page 32 of issue 100, if you’d like to read the whole thing) highlighting some influential projects and educational achievements, as well as how our tiny computers have influenced pop culture. And since ’tis the season, we thought we’d share the How Raspberry Pi made a difference section to bring some extra cheer to your festive season.

Projects for good

The Raspberry Pi Foundation was originally launched to get more UK students into computing. Not only did it succeed at that, but the hardware and the Foundation have also managed to help people in other ways and all over the world. Here are just a few examples!

Computers for good

The Raspberry Pi Foundation provides free learning resources for everyone; however, not everyone has access to a computer to learn at home. Thanks to funding from the Bloomfield Trust and in collaboration with UK Youth and local charities, the Foundation has been able to supply hundreds of Raspberry Pi Desktop Kits to young people most in need. The computers have allowed these children, who wouldn’t have been able to otherwise, to learn from home and stay connected to their schools during lockdown. The Foundation’s work to distribute Raspberry Pi computers to young people in need is ongoing.

Elsewhere, a need for more medical equipment around the world resulted in many proposals and projects being considered for cheap, easy-to produce machines. Some included Raspberry Pi Zero, with 40,000 of these sold for ventilator designs.

The Foundation’s Digital Making at Home live streams bring coding fun to young people at home every week

Offline learning

While there’s no global project or standard to say what an offline internet should contain, some educational projects have tried to condense down enough online content for specific people and load it all onto a Raspberry Pi. RACHEL-Pi is one such solution. The RACHEL-PI kit acts as a server, hosting a variety of different educational materials for all kinds of subjects, as well as an offline version of Wikipedia with 6000 articles. There’s even medical info for helping others, math lessons from Khan Acadamy, and much more.

The RACHEL sites are available in English, French, and Spanish

17,000 ft is another great project, which brings computing to schools high up in the Himalayas through a similar method in an attempt to help children stay in their local communities.

Young learners in red jackets and baseball caps using tablets to learn in a Himalayan school
Ladakh is a desert-like region up a mountain that can easily shut down during the winter

Education in other countries

The free coding resources available on our projects site are great, and the Raspberry Pi Foundation works to make them accessible to people whose first language isn’t English: we have a dedicated translation team and, thanks to volunteers around the world, provide our free resources translated into up to 32 other languages. From French and Welsh to Korean and Arabic, there’s a ton of projects that learners from all over the world can access in their first language.

And through the Code Club and CoderDojo programmes, the Foundation supports volunteers around the world to run free coding clubs for young people.

A Raspberry Pi lab in Kuma Adamé, Togo that Dominique Laloux helped create and update
A Raspberry Pi lab in Kuma Adamé, Togo, that Dominique Laloux helped create and update

That’s not all: several charitable groups have set up Raspberry Pi classrooms to bring computing education to poorer parts of the world. People in African countries and parts of rural India have benefited from these programmes, and work is being done to widen access to ever more people and places.

Pocket FM

The Pocket FM is far smaller than traditional transmitters, and therefore easy to move into the country and set up

The HAM radio community loves Raspberry Pi for amateur radio projects; however, sometimes people need radio for more urgent purposes. In 2016, German group Media in Cooperation and Transition created the Pocket FM 96 , micro radio transmitters with 4–6km range. These radios allowed Syrians in the middle of a civil war to connect to free media on Syrnet for more reliable news.

There are a number of independent radio stations that transmit through Pocket FM
There are a number of independent radio stations that transmit through Pocket FM

Raspberry Pi powered these transmitters, chosen because of how easy it is to upgrade and add components to. Each transmitter is powered by solar power, and Syrnet is still transmitting through them as the war continues into its tenth year.

The post 100 Raspberry Pi moments appeared first on Raspberry Pi.

Recreate Tiger-Heli’s bomb mechanic | Wireframe #45

Code an explosive homage to Toaplan’s classic blaster. Mark Vanstone has the details

Tiger-Heli was developed by Toaplan and published in Japan by Taito and by Romstar in North America.

Released in 1985, Tiger-Heli was one of the earliest games from Japanese developer Toaplan: a top-down shoot-’em-up that pitted a lone helicopter against relentless waves of enemy tanks and military installations. Toaplan would go on to refine and evolve the genre through the eighties and nineties with such titles as Truxton and Fire Shark, so Tiger-Heli served as a kind of blueprint for the studio’s legendary blasters.

Tiger-Heli featured a powerful secondary weapon, too: as well as a regular shot, the game’s attack helicopter could also drop a deadly bomb capable of destroying everything within its blast radius. The mechanic was one that first appeared as far back as Atari’s Defender in 1981, but Toaplan quickly made it its own, with variations on the bomb becoming one of the signatures in the studio’s later games.

For our Tiger-Heli-style Pygame Zero code, we’ll concentrate on the unique bomb aspect, but first, we need to get the basic scrolling background and helicopter on the screen. In a game like this, we’d normally make the background out of tiles that can be used to create a varied but continuous scrolling image. For this example, though, we’ll keep things simple and have one long image that we scroll down the screen and then display a copy above it. When the first image goes off the screen, we just reset the co-ordinates to display it above the second image copy. In this way, we can have an infinitely scrolling background.

Our Tiger-Heli homage in Python. Fly over the military targets, firing missiles and dropping bombs.

 

The helicopter can be set up as an Actor with just two frames for the movement of the rotors. This should look like it’s hovering above the ground, so we blit a shadow bitmap to the bottom right of the helicopter. We can set up keyboard events to move the Actor left, right, up, and down, making sure we don’t allow it to go off the screen.

Now we can go ahead and set up the bombs. We can predefine a list of bomb Actors but only display them while the bombs are active. We’ll trigger a bomb drop with the SPACE bar and set all the bombs to the co-ordinates of the helicopter. Then, frame by frame, we move each bomb outwards in different directions so that they spread out in a pattern. You could try adjusting the number of bombs or their pattern to see what effects can be achieved. When the bombs get to frame 30, we start changing the image so that we get a flashing, expanding circle for each bomb.

Here’s Mark’s code for a Tiger-Heli-style shooter. To get it working on your system, you’ll need to install Pygame Zero. And to download the full code and assets, head here.

It’s all very well having bombs to fire, but we could really do with something to drop them on, so let’s make some tank Actors waiting on the ground for us to destroy. We can move them with the scrolling background so that they look like they’re static on the ground. Then if one of our bombs has a collision detected with one of the tanks, we can set an animation going by cycling through a set of explosion frames, ending with the tank disappearing.

We can also add in some sound effects as the bombs are dropped, and explosion sounds if the tanks are hit. And with that, there you have it: the beginnings of a Tiger-Heli-style blaster.

Get your copy of Wireframe issue 45

You can read more features like this one in Wireframe issue 45, available directly from Raspberry Pi Press — we deliver worldwide.

And if you’d like a handy digital version of the magazine, you can also download issue 45 for free in PDF format.

Baldur’s Gate III: our cover star for Wireframe #45.

Make sure to follow Wireframe on Twitter and Facebook for updates and exclusive offers and giveaways. Subscribe on the Wireframe website to save up to 72% compared to newsstand pricing!

The post Recreate Tiger-Heli’s bomb mechanic | Wireframe #45 appeared first on Raspberry Pi.

New Raspberry Pi OS release — December 2020

Par : Simon Long

Well, in a year as disrupted and strange as 2020, it’s nice to know that there are some things you can rely on, for example the traditional end-of-year new release of Raspberry Pi OS, which we launch today. Here’s a run-through of the main new features that you’ll find in it.

Chromium

We’ve updated the Chromium browser to version 84. This has taken us a bit longer than we would have liked, but it’s always quite a lot of work to get our video hardware acceleration integrated with new releases of the browser. That’s done now, so you should see good-quality video playback on sites like YouTube. We’ve also, given events this year, done a lot of testing and tweaking on video conferencing clients such as Google Meet, Microsoft Teams, and Zoom, and they should all now work smoothly on your Raspberry Pi’s Chromium.

Version 84 of the Chromium web browser

There’s one more thing to mention on the subject of web browsers. We’ve been shipping Adobe’s Flash Player as part of our Chromium install for several years now. Flash Player is being retired by Adobe at the end of the year, so this release will be the last that includes it. Most websites have now stopped requiring Flash Player, so this hopefully isn’t something that anyone notices!

PulseAudio

From this release onwards, we are switching Raspberry Pi OS to use the PulseAudio sound server.

First, a bit of background. Audio on Linux is really quite complicated. There are multiple different standards for handling audio input and output, and it does sometimes seem that what has happened, historically, is that whenever anyone wanted to use audio in Linux, they looked at the existing libraries and programs and went “Hmmm… I don’t like that, I’ll write something new and better.” This has resulted in a confused mass of competing and conflicting software, none of which quite works the way anyone wants it to!

The most common audio interface, which lies underneath most Linux systems somewhere, is called ALSA, the Advanced Linux Sound Architecture. This is a fairly reliable low-level audio interface — indeed, it is what Raspberry Pi OS has used up until now — but it has quite a lot of limitations and is starting to show its age. For example, it can only handle one input and one output at a time. So for example, if ALSA is being used by your web browser to play sound from a YouTube video to the HDMI output on your Raspberry Pi, nothing else can produce sound at the same time; if you were to try playing a video or an audio file in VLC, you’d hear nothing but the audio from YouTube. Similarly, if you want to switch the sound from your YouTube video from HDMI to a USB sound card, you can’t do it while the video is playing; it won’t change until the sound stops. These aren’t massive problems, but most modern operating systems do handle audio in a more flexible fashion.

More significant is that ALSA doesn’t handle Bluetooth audio at all, so various other extensions and additional bits of software are required to even get audio into and out of Bluetooth devices on an ALSA-based system. We’ve used a third-party library called bluez-alsa for a few years now, but it’s an additional piece of code to maintain and update, so this isn’t ideal.

PulseAudio deals with all of this. It’s a piece of software that sits as a layer between all the audio hardware and all the applications that send and receive audio, and it automatically routes everything to the right places. It can mix the audio from multiple applications together, so you can hear VLC at the same time as YouTube, and it allows the output to be moved around between different devices while it is playing. It knows how to talk to Bluetooth devices, and it greatly simplifies the job of managing default input and output devices, so it makes it much easier to make sure audio ends up where it is supposed to be!

One area where it is particularly helpful is in managing audio input and output streams to web browsers like Chromium; in our testing, the use of PulseAudio made setting up video conferencing sessions much easier and more reliable, particularly with Bluetooth headsets and webcam audio.

The good news for Raspberry Pi users is that, if we’ve got it right, you shouldn’t even notice the change. PulseAudio now runs by default, and while the volume control and audio input/output selector on the taskbar looks almost identical to the one in previous releases of the OS, it is now controlling PulseAudio rather than ALSA. You can use it just as before: select your output and input devices, adjust the volume, and you’re good to go.

The PulseAudio input selector

There is one small change to the input/output selector, which is the menu option at the bottom for Device Profiles. In PulseAudio, any audio device has one or more profiles, which select which outputs and inputs are used on any device with multiple connections. (For example, some audio HATs and USB sound cards have both analogue and digital outputs — there will usually be a profile for each output to select where the audio actually comes out.)

The PulseAudio profile selector

Profiles are more important for Bluetooth devices. If a Bluetooth device has both an input and an output (such as a headset with both a microphone and an earphone), it usually supports two different profiles. One of these is called HSP (HeadSet Profile), and this allows you to use both the microphone and the earphone, but with relatively low sound quality — equivalent to that you hear on a mobile phone call, so fine for speech but not great for music. The other profile is called A2DP (Advanced Audio Distribution Profile), which gives much better sound quality, but is output-only: it does not allow you to use the microphone. So if you are making a call, you want your Bluetooth device to use HSP, but if you are listening to music, you want it to use A2DP.

We’ve automated some of this, so if you select a Bluetooth device as the default input, then that device is automatically switched to HSP. If you want to switch a device which is in HSP back to A2DP, just reselect it from the output menu. Its microphone will then be deactivated, and it will switch to A2DP. But sometimes you might want to take control of profiles manually, and the Device Profiles dialog allows you to do that.

(Note that if you are only using the Raspberry Pi’s internal sound outputs, you don’t need to worry about profiles at all, as there is only one, and it’s automatically selected for you.)

Some people who have had experience of PulseAudio in the past may be a little concerned by this change, because PulseAudio hasn’t always been the most reliable piece of software, but it has now reached the point where it solves far more problems than it creates, which is why many other Linux distributions, such as Ubuntu, now use it by default. Most users shouldn’t even notice the change; there may be occasional issues with some older applications such as Sonic Pi, but the developers of these applications will hopefully address any issues in the near future.

Printing

One thing which has always been missing from Raspberry Pi OS is an easy way to connect to and configure printers. There is a Linux tool for this, called CUPS, the Common Unix Printing System. (It’s actually owned by Apple and is the underlying printing system used by macOS X, but it is still free software and available for use by Linux distributions.)

CUPS has always been available in apt, so could be installed on any Raspberry Pi, but the standard web-based interface is a bit unfriendly. Various third-party front-end tools have been written to make CUPS a bit easier to use, and we have decided to use one called system-config-printer. (Like PulseAudio, this is also used as standard by Ubuntu.)

So both CUPS and system-config-printer are now installed as part of Raspberry Pi OS. If you are a glutton for punishment, you can access the CUPS web interface by opening the Chromium browser and going to http://localhost:631, but instead of doing that, we suggest just going into the Preferences section in the main menu and opening Print Settings.

The new Printer Settings dialog

This shows the system-config-printer dialog, from which you can add new printers, remove old ones, set one as the default, and access the print queue for each printer, just as you should be familiar with from other operating systems.

Like most things in Linux, this relies on user contributions, so not every printer is supported. We’ve found that most networked printers work fine, but USB printers are a bit hit-and-miss as to whether there is a suitable driver; in general, the older your printer is, the more likely it is to have a CUPS driver available. The best thing to do is to try it and see, and perhaps ask for help on our forums if your particular printer doesn’t seem to work.

This fills in one of the last things missing in making Raspberry Pi a complete desktop computer, by making it easy to set up a printer and print from applications such as LibreOffice.

Accessibility

One of the areas we have tried to improve in the Desktop this year is to make it more accessible to those with visual impairments. We added support for the Orca screen reader at the start of the year, and the display magnifier plugin over the summer.

While there are no completely new accessibility features this time, we have made some improvements to Orca support in applications like Raspberry Pi Configuration and Appearance Settings, to make them read what they are doing in a more helpful fashion; we’ve also worked with the maintainers of Orca to raise and fix a few bugs. It’s still not perfect, but we’re doing our best!

One of the benefits of switching to PulseAudio is that it now means that screen reader audio can be played through Bluetooth devices; this was not possible using the old ALSA system, so visually-impaired users who wish to use the screen reader with a Bluetooth headset or external speaker can now do so.

One feature we have added is an easy way to install Orca; it is still available through Recommended Software as before, but given that is not easy to navigate for a visually-impaired person, there is now a keyboard shortcut: just hold down ctrl and alt and press the space bar to automatically install Orca. A dialog box will be shown on the screen, and voice prompts will let you know when the install has started and finished.

And if you can’t remember that shortcut, when you first boot a new image, if you don’t do anything for thirty seconds or so, the startup wizard will now speak to you to remind you how to do it…

Finally, we had hoped to be able to say that Chromium was now compatible with Orca; screen reader support was being added to versions 8x. Unfortunately, for now this seems to only have been added for Windows and Mac versions, not the Linux build we use. Hopefully Google will address this in a future release, but for now if you need a web browser compatible with Orca, you’ll need to install Firefox from apt.

New hardware options

We’ve added a couple of options to the Raspberry Pi Configuration tool.

On the System tab, if you are running on Raspberry Pi with a single status LED (i.e. a Raspberry Pi Zero or the new Raspberry Pi 400), there is now an option to select whether the LED just shows that the power is on, or if it flickers off to show drive activity.

LED control in Raspberry Pi Configuration

On the Performance tab, there are options to allow you to control the new Raspberry Pi Case Fan: you can select the GPIO pin to which it is connected and set the temperature at which it turns on and off.

Fan controls in Raspberry Pi Configuration

How do I get it?

The latest image can be installed on a new card using the Raspberry Pi Imager, or can be downloaded from our Downloads page.

To apply the updates to an existing image, you’ll need to enter the usual commands in a terminal window:

sudo apt update
sudo apt full-upgrade

(It is safe to just accept the default answer to any questions you are asked during the update procedure.)

Then, to install the PulseAudio Bluetooth support, you will need to enter the following commands in the terminal window:

sudo apt purge bluealsa
sudo apt install pulseaudio-module-bluetooth

Now reboot.

To swap over the volume and input selector on the taskbar from ALSA to PulseAudio, after your Raspberry Pi has restarted, right-click a blank area on the taskbar and choose Add / Remove Panel Items. Find the plugin labelled Volume Control (ALSA/BT) in the list, select it and click Remove; then click the Add button, find the plugin labelled Volume Control (PulseAudio) and click Add. Alternatively, just open the Appearance Settings application from the Preferences section of the Main Menu, go to the Defaults tab and press one of the Set Defaults buttons.

Updates

Some people have reported that some applications are ignoring the effect of the PulseAudio output switcher. This is probably caused by an old ALSA configuration file still being on the system. Once you have updated, execute the following in a terminal window, which should fix this:

rm ~/.asoundrc

To remove the old Audio Preferences application, which will not work with PulseAudio, do:

sudo apt purge pimixer

We are also aware that the output from the Raspberry Pi’s internal audio device is in mono in the image; this is now fixed. To get the fix, do an update in a terminal window:

sudo apt update
sudo apt full-upgrade
reboot

Some users have reported that in a dual-monitor setup, switching the audio output to the AV Jack causes problems – this is being investigated at the moment.

As ever, do let us know what you think in the comments.

The post New Raspberry Pi OS release — December 2020 appeared first on Raspberry Pi.

Diversity and inclusion in computing education — new research seminars

At the Raspberry Pi Foundation, we host a free online research seminar once a month to explore a wide variety of topics in the area of digital and computing education. This year, we’ve hosted eleven seminars — you can (re)discover slides and recordings on our website.

A classroom of young learners and a teacher at laptops

Now we’re getting ready for new seminars in 2021! In the coming months, our seminars are going to focus on diversity and inclusion in computing education. This topic is extremely important, as we want to make sure that computing is accessible to all, that we understand how to actively remove barriers to participation for learners, and that we understand how to teach computing in an inclusive way. 

We are delighted to announce that these seminars focusing on diversity and inclusion will be co-hosted by the Royal Academy of Engineering. The Royal Academy of Engineering is harnessing the power of engineering to build a sustainable society and an inclusive economy that works for everyone.

Royal Academy of Engineering logo

We’re very excited to be partnering with the Academy because of our shared interest in ensuring that computing and engineering are inclusive and accessible to all.

Our upcoming seminars

The seminars take place on the first Tuesday of the month at 17:00–18:30 GMT / 12:00–13:30 EST / 9:00–10:30 PST / 18:00–19:30 CET.

  • 5 January 2021: Dr Peter Kemp (King’s College London) and Dr Billy Wong (University of Reading) will be looking at computing education in England, particularly GCSE computer science, and how it is accessed by groups typically underrepresented in computing.
  • 2 February 2021: Professor Tia Madkins (University of Texas at Austin), Dr Nicol R. Howard (University of Redlands), and Shomari Jones (Bellevue School District) will be talking about equity-focused teaching in K–12 computer science. Find out more.
  • 2 March 2021: Dr Jakita O. Thomas (Auburn University, Alabama) will be talking about her research on supporting computational algorithmic thinking in the context of intersectional computing.
  • April 2021: event to be confirmed
  • 4 May 2021: Dr Cecily Morrison (Microsoft Research) will be speaking about her work on physical programming for people with visual impairments.

Join the seminars

We’d love to welcome you to these seminars so we can learn and discuss together. To get access, simply sign up with your name and email address.

Once you’ve signed up, we’ll email you the seminar meeting link and instructions for joining. If you attended our seminars in the past, the link remains the same.

The post Diversity and inclusion in computing education — new research seminars appeared first on Raspberry Pi.

Designing the Raspberry Pi Case Fan

When I first investigated inserting a fan into the standard Raspberry Pi case there were two main requirements. The first was to keep the CPU cool in all usage scenarios. The second was to reduce or eliminate any changes to the current case and therefore avoid costly tool changes.

The case fan and heatsink

As I had no experience developing a fan, I did what all good engineers do and had a go anyway. We had already considered opening the space above the Ethernet connector to create a flow of air into the case. So, I developed my first prototype from a used Indian takeaway container (I cleaned it first), but the below card version was easier to recreate

The first prototype

Input port over the Ethernet connector
Air duct taped into the top of the case

The above duct is what remains from my first effort, the concept is relatively simple, draw air in over the Ethernet port, and then drive the air down onto the CPU. But it wasn’t good enough, running CPU-burn on all four cores required a fan which sounded like it was about to take off. So I spoke to a professional who did some computational fluid dynamics (CFD) analysis for us.

It’s a kind of magic

CFD analysis of a cross section of the case

CFD analysis takes a 3D description of the volume and calculates a simulation of fluid flow (the air) through the volume. The result shows where the air moves fastest (the green and red areas)

What this showed us is the position of the fan is important since the fastest moving bit of air is actually quite far from the centre of the processor, also:

Bulk analysis of the air flow through the case

The picture above shows how most of the moving air (green and red) is mainly spinning around inside the fan. This happens because there is a pressure difference between the input and output sides of the fan (the sucky end and the blowy end). Fans just don’t work well that way, they are most efficient when unrestricted. I needed to go back to the drawing board. My next experiment was to add holes into the case to understand how much the airflow could be changed.

Improving airflow

Holes
More holes!

After running the tests with additional holes in both the lid and the base I concluded the issue wasn’t really getting air unrestricted in and out of the case (although the holes did make a small difference) but the effect the air duct was having on restricting the flow into the fan itself. Back to the drawing board…

During a long run in the fens, I thought about the airflow over the Ethernet connector and through the narrow duct, wondering how we can open this up to reduce the constriction. I realised it might be possible to use the whole ‘connector end’ of the case as the inlet port.

The breakthrough

My first cardboard ‘bulkhead’

Suddenly, I had made a big difference… By drawing air from around the USB and Ethernet connectors the lid has been left un-modified but still achieves the cooling effect I was looking for. Next was to reduce the direction changes in the air flow and try to make the duct simpler.

The bulkhead

The cardboard bulkhead does exactly what you need to do and nothing more. It separates the two halves of the case, and directs the air down directly at the processor. Using this design and the heatsink, I was able to achieve a cooling capable of easily running the cpuburn application but with an even smaller (quieter) fan.

The next job is to develop a plastic clip to attach the fan into the lid. That’s where our friends at Kinneir Dufort came in. They designed the injection moulded polycarbonate that makes an accurate interface with the Raspberry Pi’s PCB. The ‘bulkhead’ clips neatly into the slots in the lid, almost like it was planned!

The Raspberry Pi Case Fan has been developed with an advanced user in mind. It allows them to use the Raspberry Pi at its limits whilst retaining the unique finished exterior of the Raspberry Pi Case.

For those who love a good graph, here are the temperature results during a quad-core compile of the Linux kernel, as demonstrated in Eben’s launch post on Monday.

Buy your Raspberry Pi 4 Case Fan today

Raspberry Pi Case Fan is available from our Raspberry Pi Approved Resellers. Simply head over to the Case Fan page and select your country from the drop-down menu.

The post Designing the Raspberry Pi Case Fan appeared first on Raspberry Pi.

Spread the joy of learning through making

Par : Eben Upton

From our first prototype way back in 2006, to the very latest Raspberry Pi 400, everything we have built here at Raspberry Pi has been driven by a desire to inspire learning. I hope that each of you who uses our products discovers — or rediscovers — the joy of learning through making. The journey from technology consumer to technology creator can be a transformational one; today, on Giving Tuesday, I’m asking you to help even more young people make that journey.

Too few young people have the chance to learn how technology works and how to harness its power. Pre-existing disparities in access to computing education have been exacerbated by the coronavirus pandemic. At the Raspberry Pi Foundation, we’re on a mission to change this, and we’re working harder than ever to support young people and educators with free learning opportunities. Our partner CanaKit supports the Raspberry Pi Foundation’s mission, and they’ve extended the generous offer to match your donations up to a total of $5,000.

Alongside our low-cost, high-performance computers and free software, you may know that the Raspberry Pi Foundation provides free educational programmes including coding clubs and educator training for millions of people each year in dozens of countries. You might not know that the Raspberry Pi Foundation was founded as, and still remains, a nonprofit organisation. Our education mission is powered by dedicated volunteers, and our programmes are funded in part thanks to our customers who buy Raspberry Pi products, and in part by charitable donations from people like you.

A smiling girl holding a robot buggy in her lap

Every donation we receive makes an impact on the young people and educators who rely on the Raspberry Pi Foundation. Ryka, for example, is a 10-year-old who attends one of our CoderDojo clubs. Since March she’s been using our project guides and following our Digital Making at Home code-along live streams. Her parents tell us: 

“We were looking at ways to keep Ryka engaged during this lockdown period and came across Digital Making at Home. As a parent I can see that there has been discernible improvement in her abilities. We’ve noticed that she is engaged and takes interest in showing us what she was able to build. It has been a great use of her time.” 

– Parent of a young person who learns through our programmes

Ryka joins millions of learners in our community around the world, many of whom now rely on us more than ever with schools and extracurricular activities disrupted. Through the ongoing support of our donors and volunteers, we’ve been able to rise to the challenge of the pandemic:

Young coders and digital makers need our help in the year ahead as they take control of their computing education under challenging and uncertain circumstances. As a donor to the Raspberry Pi Foundation, you will be investing in our youngest generation of digital makers and helping to create a spark in a young person’s life. On Giving Tuesday, I am grateful to each of you for the role you play in creating a world where everyone can learn, solve problems, and shape their future through the power of technology. 

PS Thank you again to our friends at CanaKit for doubling the impact of every donation, up to $5000! 

The post Spread the joy of learning through making appeared first on Raspberry Pi.

New product: Raspberry Pi 4 Case Fan

Par : Eben Upton

Today we’re launching a stocking-filler product to help you squeeze more performance out of your Raspberry Pi 4. The $5 Raspberry Pi 4 Case Fan clips inside the lid of the Official Case, and keeps your Raspberry Pi 4 cool even when running the heaviest workloads, at the most aggressive overclocks.

Raspberry Pi 4 power optimisation

Like all electronic products, Raspberry Pi generates waste heat as it works. Along with most fanless products – like most mobile phones – Raspberry Pi 4 was originally designed to operate in a “sprint-and-recover” mode: if run at maximum performance for an extended period it would heat up, and eventually throttle back to limit its temperature.

What’s in the box?

In practice, the power optimisation work that we’ve done over the last eighteen months has largely eliminated throttling for an uncased board, operating at the stock clock frequency of 1.5GHz, and in a typical ambient temperature.

Here’s a graph of temperature during a quad-core compile of the Linux kernel: you can see the temperature barely exceeds 70C.

Quad-core kernel compile without case

Turning your Raspberry Pi “up to eleven”

But maybe you want to put your Raspberry Pi in a case; or you’ve noticed that your Raspberry Pi will overclock to 1.8GHz or more; or you want to use it in a higher ambient temperature. All of these things can put us back in sprint-and-recover mode.

Here’s the same workload running on a board in a Raspberry Pi official case: now we hit the 80C throttle point and slow down, and the compile job takes (slightly) longer to complete.

Quad-core kernel compile in Raspberry Pi 4 Official Case

To run indefinitely at full speed under these conditions you’ll need either a passive cooling solution (like the excellent Flirc case), or an active one like the Raspberry Pi 4 Case Fan. It draws air in over the USB and Ethernet connectors, passes it over a small finned heatsink attached to the processor, and exhausts it through the SD card slot. Here’s our workload running with the case fan: now the board remains well below 70C, and as expected the compile job takes the same amount of time as on the uncased board.

Gordon Hollingworth will be here on Wednesday to talk about how he designed the Raspberry Pi 4 Case Fan ducting with the aid of a stack of Chinese takeout boxes and a glue gun. 

Get your Raspberry Pi 4 Case Fan today

As with all our products, the Raspberry Pi Case Fan is available from our Raspberry Pi Approved Resellers. Simply head over to the Case Fan page and select your country from the drop-down menu.

If your country isn’t on the list yet, don’t worry, we’re constantly working to add further countries and resellers to the list. Until then, check out some of our Approved Resellers that offer international shipping.

The post New product: Raspberry Pi 4 Case Fan appeared first on Raspberry Pi.

New book: The Official Raspberry Pi Handbook 2021

Hey everyone, come and see, come and see! Here’s a great new bookazine from the makers of the official Raspberry Pi magazine. We do love the folks at The MagPi. Clever, they are.

If, like us, you’re over 2020 already, dive into the pages of The Official Raspberry Pi Handbook 2021, and pretend it never happened. That will totally work.

The front cover of the Raspberry Pi Handbook featuring a Raspberry Pi 4 on a dark background

To help you get the most of out of your Raspberry Pi computer, this official Handbook features 200 pages of essential information, inspiring projects, practical tutorials, and definitive reviews.

Beginner-friendly

A blue double page spread on Starter Electronics

If you’re an absolute beginner, you can learn from the Handbook how to set up your Raspberry Pi and start using it. Then you can move on to the step-by-step tutorials that will teach you how to code and make with your Raspberry Pi.

Shiny new stuff

A double page spread about Raspberry Pi 400

You’ll also (re)discover the new Raspberry Pi 400 and High Quality Camera, both released this year. And you’ll find out about the top kits and accessories for your projects.

Be inspired

A double page spread about Reachy robot. Robot is white with big black eyes and a stripy torso

And finally, we’ve also picked out some incredible Raspberry Pi projects made by people in the community to inspire you to get making and coding.

Where can I get the Handbook?

A double page spread on problem solving with Raspberry Pi

You can buy The Official Raspberry Pi Handbook 2021 now from the Raspberry Pi Press online store, or at the Raspberry Pi store in Cambridge, UK.

Personally, we prefer new book smell and the crackle of physical pages but, if you’re less picky and don’t mind on-screen reading, the lovely folks at The MagPi have a PDF version you can download for free.

The post New book: The Official Raspberry Pi Handbook 2021 appeared first on Raspberry Pi.

The MagPi #100: celebrate 100 amazing moments from Raspberry Pi history

Hey there, folks, Rob from The MagPi here! I hope you’ve all been doing OK.

Today we celebrate the 100th issue of The MagPi, the official Raspberry Pi magazine!

Flat view of the special front cover of the magazine featuring a big red number 100

Most of you probably know that The MagPi didn’t start off official, though: eight and a half years ago, intrepid community members came together to create The MagPi as a fanzine, and it ran as one for 30 issues (plus one special) until early 2015, when it became part of Raspberry Pi and went official.

Officially official

An orange rover robot which looks a bit like a dog with wheels and a cute smiling face

For 70 issues now, the rest of the team and I have worked hard to bring Raspberry Pi fans a monthly magazine packed full of amazing content from the global Raspberry Pi (and wider maker) community. In the last six-ish years, I’ve built robots with you, stuffed Raspberry Pi Zeros into games controllers, lit up my Christmas tree, written far too many spooky puns, gone stargazing, recorded videos for numerous Raspberry Pi launches, and tried to help everyone who wanted to get their hands on the (in)famous issue 40.

Celebrating a milestone

Hand held gaming devices which look like traditional Game Boys

I could go on, but I already have: for issue 100 we’re celebrating 100 incredible moments in Raspberry Pi history, from its humble beginnings to becoming the third best-selling computer ever, and one of the few to be on the International Space Station.

One of those moments was the release of Raspberry Pi 400, an incredibly cool model of Raspberry Pi that elicited a few ‘oohs’ and ‘aahs’ from me when mine arrived in the post. We give it the full MagPi breakdown with benchmarks and interviews, courtesy of our good friend Gareth Halfacree.

How to get issue 100

Photos of ten Christmas themed projects and short blurbs linking to longer articles about them

But wait, there’s more! We’ve managed to squeeze in our usual array of projects, tutorials, reviews, and community reports as well. Expect cool robots, funky guitars, handheld console building guides, and case reviews.

You can buy The MagPi 100 right this very moment from the online Raspberry Pi Press store, get it on our app for Android or iOS, or even just download the PDF.

Subscription offers!

Never want to miss an issue? Subscribe to The MagPi and we’ll deliver every issue straight to your door. Also, if you’re a new subscriber and get the 12-month subscription, you’ll get a completely free Raspberry Pi Zero bundle with a Raspberry Pi Zero W and accessories.

I really think you’ll like this issue. Here’s to another 100.

A gif of Patrick Stewart saying But the future is left for us to write

The post The MagPi #100: celebrate 100 amazing moments from Raspberry Pi history appeared first on Raspberry Pi.

Personal Raspberry Pi music streamer

Mike Perez from Audio Arkitekts took to YouTube to show you how to build your own music streamer using a Raspberry Pi. Haters of Bluetooth and RCA plugs, he’s done this for you.

Mike reports a “substantial difference in sound quality” compared to his previous setup (the aforementioned and reviled Bluetooth and RCA plug options).

This project lets you use a Raspberry Pi as a music player and control it from your mobile phone.

Hardware

Unboxing the Argon Neo Raspberry Pi Bundle

Mike started out with an $80 Argon Neo Raspberry Pi Bundle, which includes a Raspberry Pi 4 Model B. He made a separate video to show you how to put everything together.

This bundle comes with a nice, sleek case, so your music player can be on display discreetly.

Pretty case

Not sure about spending $80 on this kit? In the project video, Mike says it’s “totally, totally worth it” — partly due to the quality of the case.

Software

Mike grabbed a compatible Volumio image from Volumio’s ‘Get Started’ page and flashed it onto Raspberry Pi with Etcher.

Volumio app in action

You can use an Ethernet cable, but Mike wanted to utilise Raspberry Pi 4’s wireless connectivity to boot the Volumio app. This way, the Raspberry Pi music player can be used anywhere in the house, as it’ll create its own wireless hotspot within your home network called ‘Volumio’.

Eew! No more direct audio connection to your phone to listen to music.

You’ll need a different version of the Volumio app depending on whether you have an Android phone or iPhone. Mike touts the app as “super easy, really robust”. You just select the music app you usually use from the ‘Plugins’ section of the Volumio app, and all your music, playlists, and cover art will be there ready for you once downloaded.

And that’s basically it. Just connect to the Volumio OS via the app and tell your Raspberry Pi what to play.

Amp it up

To get his new music player booming all around the house, Mike used a Starke Sound AD4, which you can watch him unbox and review.

What kind of amplification system have you got paired up with your Raspberry Pi–powered music player?

The post Personal Raspberry Pi music streamer appeared first on Raspberry Pi.

Vulkan update: we’re conformant!

Par : Eben Upton

Today we have a guest post from Igalia’s Iago Toral, who has spent the past year working on the Mesa graphic driver stack for Raspberry Pi 4.

It’s been nearly a year since we first announced that we were developing a Vulkan driver for the latest generation of Raspberry Pi devices (Raspberry Pi 4, Raspberry Pi 400, and Compute Module 4).

Sascha Willems’ Vulkan radial blur demo

In June we released the source code for our prototype driver, and last month we announced that the driver had been successfully merged to Mesa upstream.

Today we have some very exciting news to share: as of 24 November the V3DV Vulkan Mesa driver for Raspberry Pi 4 has demonstrated Vulkan 1.0 conformance.

Khronos describes the conformance process as a way to ensure that its standards are consistently implemented by multiple vendors, so as to create a reliable platform for application developers. For each standard, Khronos provides a large conformance test suite (CTS) that implementations must pass successfully to be declared conformant; in the case of Vulkan 1.0, the CTS contains over 100,000 tests.

Vulkan 1.0 conformance is a major milestone in bringing Vulkan to Raspberry Pi, but it isn’t the end of the journey. Our team continues to work on all fronts to expand the Vulkan feature set, improve performance, and fix bugs. So stay tuned for future Vulkan updates!

The post Vulkan update: we’re conformant! appeared first on Raspberry Pi.

Make your own virtual reality 3D Shooter

In the latest issue of Wireframe magazine, Mark Vanstone shows you how to turn a 3D shooter into a VR game for a variety of viewers, from Google Cardboard to gaming headsets.

Our shooter, now in VR format. Blast aliens from the sky as they fly over the mountains.

Browser development has really matured of late, with a number
of exciting new features coming to the fore. Where WebGL was well supported, the new WebXR (previously WebVR) is now becoming standard
in modern browsers. JavaScript ES5 has now been superseded by ES6, and with these new technologies, making browser-based apps – and specifically 3D games – is now a serious proposition. The other part of VR technology, the hardware, has also evolved – as mobile tech has become more powerful, so have the opportunities for cost-effective VR experiences.

With a mobile phone you can create a stereoscopic display for use with a simple Cardboard viewer.

If you have an old mobile phone, perhaps an Make your own virtual reality 3D Shooter B iPhone 6 or a Samsung S7, you can get a Google Cardboard headset for £6 and turn it into a rudimentary VR viewer. In this article, we’ll show you how to set up a 3D shooter to run not only on that hardware, but also on other viewers such as the Gear VR or Daydream, and even gaming headsets such as the Oculus, HTC, or Valve. All of these have web browsers built in which can support WebXR or a 3D display, and although there are some differences between how they work, the process of displaying a 3D scene is mostly the same on all of them, so we can use the Three.js JavaScript library.

Three different VR headsets on a white background
There’s a wide range of VR viewers and headsets on the market, from Google Cardboard to pricey gaming headsets like the Oculus, HTC, HP, Microsoft, and Valve ranges.

To begin, we’ll start with the Three.js 3D shooter we made in Wireframe #32 – if you missed it, you can download a copy. We’ll use the same models and much of the same code. The first change, though, is to update the code to run as an ES6 module. The non-module version of Three.js is being phased out at the end of 2020, so it’s probably best to get with the times and use the new stuff. As with our earlier shooter, you’ll need to run this code from a secure web server, which, for mobile phones and gaming headsets, will mean uploading it to somewhere suitable, but if you want to see it running, you can play it at technovisual.co.uk/vr.

Basic VR viewers

Now we need to consider the hardware we’re going to use to run our game. Let’s start at our baseline, Google Cardboard, and work up from there. Available from many outlets online (including Google’s store), it’s a cut-out kit, which you fold up to create a viewer.


From a browser window inside a gaming headset environment, you can launch a Three.js VR experience

There are two lenses to look through, two magnets in a recess on the side, and velcro tabs to hold a mobile phone. The magnets on the side serve as a selection mechanism which we’ll explore later.

Next, we have Gear VR-style viewers. There are many different types, priced from around £12 to £40, and these are essentially a better-built plastic version of the Cardboard but with a button on top to act as a selector. Phones of varying sizes can be used, and as long as the device isn’t more than about four years old, it should be up-to-date enough to run the 3D software.

For example, the six-year-old Samsung S5 is capable of displaying VR, but it’s a bit too slow to make the experience pleasant, whereas a five-year-old iPhone 6 is quite capable of displaying simple VR scenes smoothly. (With
iPhones, you may need to switch on Experimental Features in the Safari settings, however.)

Proper pro kit

Gaming headsets are a bit different, since they have a built-in screen in the headset, and – in the case of the Oculus Go and Quest – an Android computer in there as well. Tethered headsets use the power of a connected computer to generate the display, and all of them use a slightly different
Three.js system from the cheaper viewers to generate the 3D display.

As time goes on, it’s likely that more mobile phones will be compatible with
the VR software used by the untethered gaming headsets. Gaming headsets also have sensors that track your movement as well as the tilt of the headset, providing six degrees of freedom.

Get the rest of the tutorial in Wireframe #44

This is just a taste of the comprehensive guide included in the latest issue of Wireframe magazine. If you’re not a subscriber, you can download a PDF copy for free from the Wireframe magazine website. Start at page 50 and work your way through to create your own VR shooter game.

And if you want to take advantage of Wireframe magazine’s latest subscription deal, you can get it for just £10 at the official Raspberry Pi Press online store.

The post Make your own virtual reality 3D Shooter appeared first on Raspberry Pi.

Classify your trash with Raspberry Pi

Maker Jen Fox took to hackster.io to share a Raspberry Pi–powered trash classifier that tells you whether the trash in your hand is recyclable, compostable, or just straight-up garbage.

Jen reckons this project is beginner-friendly, as you don’t need any code to train the machine learning model, just a little to load it on Raspberry Pi. It’s also a pretty affordable build, costing less than $70 including a Raspberry Pi 4.

“Haz waste”?!

Hardware:

  • Raspberry Pi 4 Model B
  • Raspberry Pi Camera Module
  • Adafruit push button
  • Adafruit LEDs
Watch Jen giving a demo of her creation

Software

The code-free machine learning model is created using Lobe, a desktop tool that automatically trains a custom image classifier based on what objects you’ve shown it.

The image classifier correctly guessing it has been shown a bottle cap

Training the image classifier

Basically, you upload a tonne of photos and tell Lobe what object each of them shows. Jen told the empty classification model which photos were of compostable waste, which were of recyclable and items, and which were of garbage or bio-hazardous waste. Of course, as Jen says, “the more photos you have, the more accurate your model is.”

Loading up Raspberry Pi

Birds eye view of Raspberry Pi 4 with a camera module connected
The Raspberry Pi Camera Module attached to Raspberry Pi 4

As promised, you only need a little bit of code to load the image classifier onto your Raspberry Pi. The Raspberry Pi Camera Module acts as the image classifier’s “eyes” so Raspberry Pi can find out what kind of trash you hold up for it.

The push button and LEDs are wired up to the Raspberry Pi GPIO pins, and they work together with the camera and light up according to what the image classifier “sees”.

Here’s the fritzing diagram showing how to wire the push button and LEDS to the Raspberry Pi GPIO pins

You’ll want to create a snazzy case so your trash classifier looks good mounted on the wall. Kate cut holes in a cardboard box to make sure that the camera could “see” out, the user can see the LEDs, and the push button is accessible. Remember to leave room for Raspberry Pi’s power supply to plug in.

Jen’s hand-painted case mounted to the wall, having a look at a plastic bag

Jen has tonnes of other projects on her Hackster profile — check out the micro:bit Magic Wand.

The post Classify your trash with Raspberry Pi appeared first on Raspberry Pi.

Read RFID and NFC tokens with Raspberry Pi | HackSpace 37

Add a bit of security to your project or make things selectable
by using different cards. In the latest issue of HackSpace magazine, PJ Evans goes contactless.

The HAT is not hard on resources, so you can use many variants of Raspberry Pi

NFC (near-field communication) is based on the RFID (radio-frequency identification) standard. Both allow a device to receive data from a passive token or tag (meaning it doesn’t require external power to work). RFID supports a simple ID message that shouts ‘I exist’, whereas NFC allows for both reading and writing of data.

Most people come into contact with these systems every day, whether it’s using contactless payment, or a card to unlock a hotel or office door. In this tutorial we’ll look at the Waveshare NFC HAT, an add-on for Raspberry Pi computers that allows you to interact with NFC and RFID tokens.

Prepare your Raspberry Pi

We start with the usual step of preparing a Raspberry Pi model for the job. Reading RFID tags is not strenuous work for our diminutive friend, so you can use pretty much any variant of the Raspberry Pi range you like, so long as it has the 40-pin GPIO. We only need Raspberry Pi OS Lite (Buster) for this tutorial; however, you can install any version you wish. Make sure you’ve configured it how you want, have a network connection, and have updated everything by running sudo apt -y update && sudo apt -y upgrade on the command line.

Enable the serial interface

This NFC HAT is capable of communicating over three different interfaces: I2C, SPI, and UART. We’re going with UART as it’s the simplest to demonstrate, but you may wish to use the others. Start by running sudo raspi-config, going to ‘Interfacing options’, and selecting ‘Serial Interface’. When asked if you want to log into the console, say ‘No’. Then, when asked if you want to enable the serial interface, say ‘Yes’. You’ll need to reboot now. This will allow the HAT to talk to our Raspberry Pi over the serial interface.

Configure and install the HAT

As mentioned in the previous step, we have a choice of interfaces and swapping between them means changing some physical settings on the NFC HAT itself. Do not do this while the HAT is powered up in any way. Our HAT can be configured for UART/Serial by default but do check on the wiki at hsmag.cc/iHj1XA. The jumpers at I1 and I0 should both be shorting ‘L’, D16 and D20 should be shorted and on the DIP switch, everything should be off except RX and TX. Check, double-check, attach the HAT to the GPIO, and boot up.

The Waveshare HAT contains many settings. Make sure to read the instructions!

Download the examples

You can download some examples directly from Waveshare. First, we need to install some dependencies. Run the following at the command line:
sudo apt install rpi.gpio p7zip-full python3-pip
pip3 install spidev pyserial

Now, download the files and unpack them:
cd
wget https://www.waveshare.com/w/upload/6/67/Pn532-nfc-hat-code.7z
7z x Pn532-nfc-hat-code.7z

Before you try anything out, you need to edit the example file so that we use UART (see the accompanying code listing).
cd ~/raspberrypi/python
nano example_get_uid.py

Find the three lines that start pn532 = and add a # to the top one (to comment it out). Now remove the # from the line starting pn532 = PN532_UART. Save, and exit.

Try it out!

Finally, we get to the fun part. Start the example code as follows:
python3 example_get_uid.py
If all is well, the connection to the HAT will be announced. You can now place your RFID token over the area of the HAT marked ‘NFC’. Hexadecimal numbers will start scrolling up the screen; your token has been detected! Each RFID token has a unique number, so it can be used to uniquely identify someone. However, this HAT is capable of much more than that as it also supports NFC and can communicate with common standards like MIFARE Classic, which allows for 1kB of storage on the card. Check out example_dump_mifare.py in the same directory (but make sure you make the same edits as above to use the serial connection).

Going further

You can now read unique identifiers on RFID and NFC tokens. As we just mentioned, if you’re using the MIFARE or NTAG2 standards, you can also write data back to the card. The examples folder contains some C programs that let you do just that. The ability to read and write small amounts of data onto cards can lead to some fun projects. At the Electromagnetic Field festival in 2018, an entire game was based around finding physical locations and registering your presence with a MIFARE card. Even more is possible with smartphones, where NFC can be used to exchange data in any form.

Get HackSpace magazine 37 – Out Now!

Each month, HackSpace magazine brings you the best projects, tips, tricks and tutorials from the makersphere. You can get it from the Raspberry Pi Press online store, The Raspberry Pi store in Cambridge, or your local newsagents.

Each issue is free to download from the HackSpace magazine website.

The post Read RFID and NFC tokens with Raspberry Pi | HackSpace 37 appeared first on Raspberry Pi.

Defeat evil with a Raspberry Pi foam-firing spy camera

Ruth and Shawn from YouTube channel Kids Invent Stuff picked a cool idea by 9-year-old Nathan, who drew a Foam-Firing Spy Camera, to recreate in real life.

FYI: that’s not really a big camera lens…

The trick with spy devices is to make sure they look as much like the object they’re hidden inside as possible. Where Raspberry Pi comes in is making sure the foam camera can be used as a real photo-taking camera too, to throw the baddies off the scent if they start fiddling with your spyware.

Here’s the full build video by Kids Invent Stuff

The foam-firing bit of Nathan’s invention was relatively simple to recreate – a modified chef’s squirty cream dispenser, hidden inside a camera-shaped box, gets the job done.

Squirty cream thing painted black and mounted onto camera-shaped frame

Ruth and Shawn drew a load of 3D-printed panels to mount on the box frame in the image above. One of those cool coffee cups that look like massive camera lenses hides the squirty cream dispenser and gives this build an authentic camera look.

THOSE cool camera lens-shaped coffee cups, see?

Techy bits from the build:

  • Raspberry Pi
  • Infrared LED
  • Camera module
  • Mini display screen
All the bits mentioned in the list above

The infrared LED is mounted next to the camera module and switches on when it gets dark, giving you night vision.

The mini display screen serves as a ‘lid’ to the blue case protecting the Raspberry Pi and mounts into the back panel of the ‘camera’

The Raspberry Pi computer and its power bank are crammed inside the box-shaped part, with the camera module and infrared LED mounted to peek out of custom-made holes in one of the 3D-printed panels on the front of the box frame.

The night vision mini display screen in action on the back of the camera

The foam-firing chef’s thingy is hidden inside the big fake lens, and it’s wedged inside so that when you lift the big fake lens, the lever on the chef’s squirty thing is depressed and foam fires out of a tube near to where the camera lens and infrared LED peek out on the front panel of the build.

Watch the #KidsInventStuff presenters test out Nathan’s invention

Baddies don’t stand a chance!

The post Defeat evil with a Raspberry Pi foam-firing spy camera appeared first on Raspberry Pi.

Q&A with NASA engineers behind Raspberry Pi–powered ISS Mimic

Did you see the coolest International Space Station (ISS) on Earth on the blog last week? ISS Mimic is powered by Raspberry Pi, mirrors exactly what the real ISS is doing in orbit, and was built by NASA engineers to make the ISS feel more real for Earth-bound STEAM enthusiasts.

Here’s (most of) the team behind ISS Mimic

The team launched ISS Mimic in celebration of 20 years of continuous human presence in space on the ISS. And they’ve been getting lots of questions since we posted about their creation so, we asked them back to fill you in with a quick Q&A.

And here are newbies Dallas and Estefannie (Estefannie made the ISS Mimic video)

1. Since this is NASA-related, “MIMIC” must be an acronym, right?

Yes, we forced one: “Mechatronic Instantiated Model, Interactively Controlled”

2. What’s your subtitle? 

“The second-most complicated International Space Station ever made”. We also like “1/100th scale for 1/100,000,000th cost”

3. Wait, are US tax dollars paying for you to make this?

No, it’s a volunteer project, but we do get lots of support. It’s done on our own time and money — though many NASA types and others have kicked in to help buy materials. 

ISS Mimic, filmed by YouTube’s finest Estefannie Explains it All

4. So you have supporters?

Yes — mostly other organisations that we have teamed up with. We partner with a non-profit makerspace near NASA, Creatorspace, for tools, materials, and outreach. And an awesome local 3D printer manufacturer, re:3D, has joined us and printed our (large) solar panels for free, and is helping to refine our models. They are also working towards making a kit of parts for sale for those who don’t have a printer or the time to print all the pieces, with a discount for educators.

Particularly helpful has been Space Center Houston (NASA’s visitor center), who invited us to present to the public and at an educator conference (pre-COVID), and allowed us to spend a full day filming in their beautiful facility. Our earliest supporter was Boeing, who we‘ve worked with to facilitate outreach to educators and students from the start.

The real International Space Station (ISS) in orbit

5. How long have you been working on this?

5 years — a looong time. We spent much effort early on to establish the scale and feasibility and test the capabilities of 3D printing. We maintained a hard push to keep the materials cost down and reduce build time/complexity for busy educators. We always knew we’d use Raspberry Pi for the brain, but were looking for less costly options for the mechatronics. We’d still like to cut the cost down a lot to make the project more attainable for lower-income schools and individuals.

6. Have you done any outreach so far?

All of the support has allowed us to take our prototype to schools and STEM events locally. But we really want this to be built around the world to reach those who don’t have much connection to space exploration and hands-on STEM. The big build is probably most suitable for teens and adults, while the alternative builds (in-work) would be much more approachable for younger students.

‘ISS Mimic’ on display

7. So, this just for schools? 

No, not at all. Our focus is to make it viable for schools/educators — in cost and build complexity — but we want any space nerd to be able to build their own and help drive the design.

8. Biggest challenge?

Gravity. And time to work on the project… and trying to keep the cost down.

9. What about a Lunar Gateway or Habitat version of ISS Mimic?

It’s on our radar! Another build that’s screaming to be made is hacking the LEGO ISS model (released this year) to rotate its joints and light LEDs.

10. How do we launch ideas at you or get into the design orbit? 

You can always drop your thoughts right here [in the comments section below] or join the design effort on Discord and GitHub. And there’s always the socials: FacebookInstagramTwitter

Raspberry Pi on the real ISS

There are two Raspberry Pi computers aboard the real ISS right now! And even better, young people have the chance to write Python code that will run on them — IN SPACE — as part of the European Astro Pi Challenge.

Tell the young space enthusiast in your life about Astro Pi to inspire them to try coding! All the info lives at astro-pi.org.

The post Q&A with NASA engineers behind Raspberry Pi–powered ISS Mimic appeared first on Raspberry Pi.

Raspberry Pi Christmas Shopping Guide 2020

The most wonderful time of the year is approaching! “Most wonderful” meaning the time when you have to figure out what gift best expresses your level of affection for various individuals in your life. We’re here to take away some of that stress for you — provided your favourite individuals like Raspberry Pi, of course. Otherwise you’re on your own. Sorry.

We’ve got ideas for the gamers in your life, what to get for the Raspberry Pi “superfan” who has everything, and options that allow you to keep giving all year round.

Newest and hottest

If keeping up with the Joneses is your thing, why not treat your nearest Raspberry Pi fan to one of our newest products…

Raspberry Pi 400 | $70

Top view of a woman's hands using the Raspberry Pi 400 keyboard and official Raspberry Pi mouse

This year, we released Raspberry Pi 400: a complete personal computer, built into a compact keyboard, costing just $70. Our community went wild about the possibilities that Raspberry Pi 400 opens up for home learners and for those who don’t have expensive tech options at their fingertips.

You just plug in a mouse, a monitor (any semi-modern TV screen should work), and go. The Raspberry Pi 400 Personal Computer kit costs $100 and comes with a few extras to help get you started. Or you can buy the Raspberry Pi 400 unit on its own.

Depending on where you are in the world, you may need to pre-order or join a waiting list, as Raspberry Pi 400 is in such high demand. But you could give a homemade ‘IOU’ voucher letting the recipient know that they will soon get their hands on one of our newest and most popular bits of kit.

Our latest book of coding coolness | £10

We publish some cool books around these parts. Laura Sach and Martin O’Hanlon, who are both Learning Managers at the Raspberry Pi Foundation, have written the very newest one, which is designed to help you to get more out of your Python projects.

In Create Graphical User Interfaces with Python, you’ll find ten fun Python projects to create, including a painting program, an emoji match game, and a stop-motion animation creator. All for just £10.

So, if you’ve a keen coder in your midst, this book is the best choice to stretch their skills and keep them entertained throughout 2021. Buy it online from the official Raspberry Pi Press store.

Gamers

Raspberry Pi 4 Retro Gaming Kit | £88

Lovely image courtesy of The Pi Hut

The Pi Hut’s Raspberry Pi 4 Retro Gaming Kit costs £88 and includes everything you need to create your very own retro gaming console. All your lucky kit recipient has to find is a screen to plug into, and a keyboard to set up their new Raspberry Pi, which comes as part of the kit along with a case for it. The Pi Hut has also thrown in a 16GB microSD card, plus a reader for it, as well as our official micro HDMI cable. Job done.

Picade 8″ or 10″ display | from £165

Pretty picture courtesy of Pimoroni

How cool does Picade look?! It’s sold by Pimoroni and you can buy an 8″ display set for £165, or a 10″ display version for £225. Show me a self-respecting gamer who doesn’t want a desktop retro arcade machine in their own home.

Picade is a Raspberry Pi–powered mini arcade that you build yourself. All you’ll need to add is your own Raspberry Pi, a power supply, and a micro SD card.

Code the Classics, Volume 1 | £12

And if the gamer on your gift list prefers to create their own retro video games, send them a copy of Code the Classics, Volume 1. It’s a stunning-looking hardback book packed with 224 pages telling the stories of some of the seminal video games of the 1970s and 1980s, and showing you how to create your own. Putting hours of projects in the hands of your favourite gamer will only set you back £12. Buy it online from the official Raspberry Pi Press store.

Raspberry Pi superfans

Raspberry Pi Zero W | $10

For just $10 apiece, you can drop a couple Raspberry Pi Zero W into any tinkerer’s stocking and they’ll be set for their next few projects. They will LOVE you for allowing them try a new, risky build without having to tear down something else they created to retrieve an old Raspberry Pi.

Babbage Bear | $9

What to get the superfan who already has a desk full of Raspberry Pi? An official Babbage Bear to oversee the proceedings! Babbage only costs £9 and will arrive wearing their own Raspberry Pi–branded T-shirt. A special Raspberry Pi Towers inhabitant made our Babbage this Christmassy outfit before we photographed them.

Official t-shirts | $12

  • Raspberry Pi “Pi 4” T-shirt
  • Raspberry Pi “Make Cool Stuff” T-shirt

If you’ve a superfan on your gift list, then it’s likely they already own a t-shirt with the Raspberry Pi logo on it — so why not get them one of these new designs?

Both costing just £12, the black Raspberry Pi “Pi 4” t-shirt was released to celebrate the launch of Raspberry Pi 4 and features an illustration of the powerful $35 computer. The white Raspberry Pi “Make Cool Stuff” option was created by Raspberry Pi’s own illustrator/animator extraordinaire Sam Alder. Drop that inside fact on the gift tag for extra superfan points.

Wearable tech projects | £7

And if they’re the kind of superfan who would like to make their own Raspberry Pi-–themed clothing, gift them with our Wearable Tech Projects book. This 164-page book gathers up the best bits of wearable technology from HackSpace magazine, with tutorials such as adding lights to your favourite cosplay helmet, and creating a glowing LED skirt. It’s on sale for just £7 and you can buy it online from the official Raspberry Pi Press store.

Keep giving all year

What if you could give the joy of opening a Raspberry Pi–themed gift every single month for a whole year? Our magazine subscriptions let you do just that, AND they come with a few extra gifts when you sign up.

The MagPi magazine

The official Raspberry Pi magazine comes with a free Raspberry Pi Zero kit worth £20 when you sign up for a 12-month subscription. The magazine is packed with computing and electronics tutorials, how-to guides, and the latest news and reviews.

Check out subscription deals on the official Raspberry Pi Press store.

HackSpace magazine

HackSpace magazine is packed with projects for fixers and tinkerers of all abilities. 12-month subscriptions comes with a free Adafruit Circuit Playground Express, which has been specially developed to teach programming novices from scratch and is worth £25.

Check out subscription deals on the official Raspberry Pi Press store

Wireframe magazine

Wireframe magazine lifts the lid on video games. In every issue, you’ll find out how games are made, who makes them, and how you can make your own using detailed guides. The latest deal gets you three issues for just £10, plus your choice of one of our official books as a gift.

Check out more subscriptions deals on the official Raspberry Pi Press store.

Custom PC

Custom PC is the magazine for people who are passionate about PC technology and hardware. You can subscribe to receive three issues for just £10, and you’ll also receive a book as a gift.

Check out subscription offers on the official Raspberry Pi Press store.

That’s all folks. Have a holly jolly one. Drop a question in the comments box below if you’re after something Raspberry Pi–themed which isn’t mentioned here. I’m half elf and should be able to help.

The post Raspberry Pi Christmas Shopping Guide 2020 appeared first on Raspberry Pi.

PRIMM: encouraging talk in programming lessons

Whenever you learn a new subject or skill, at some point you need to pick up the particular language that goes with that domain. And the only way to really feel comfortable with this language is to practice using it. It’s exactly the same when learning programming.

A girl doing Scratch coding in a Code Club classroom

In our latest research seminar, we focused on how we educators and our students can talk about programming. The seminar presentation was given by our Chief Learning Officer, Dr Sue Sentance. She shared the work she and her collaborators have done to develop a research-based approach to teaching programming called PRIMM, and to work with teachers to investigate the effects of PRIMM on students.

Sue Sentance

As well as providing a structure for programming lessons, Sue’s research on PRIMM helps us think about ways in which learners can investigate programs, start to understand how they work, and then gradually develop the language to talk about them themselves.

Productive talk for education

Sue began by taking us through the rich history of educational research into language and dialogue. This work has been heavily developed in science and mathematics education, as well as language and literacy.

In particular the work of Neil Mercer and colleagues has shown that students need guidance to develop and practice using language to reason, and that developing high-quality language improves understanding. The role of the teacher in this language development is vital.

Sue’s work draws on these insights to consider how language can be used to develop understanding in programming.

Why is programming challenging for beginners?

Sue identified shortcomings of some teaching approaches that are common in the computing classroom but may not be suitable for all beginners.

  • ‘Copy code’ activities for learners take a long time, lead to dreaded syntax errors, and don’t necessarily build more understanding.
  • When teachers model the process of writing a program, this can be very helpful, but for beginners there may still be a huge jump from being able to follow the modeling to being able to write a program from scratch themselves.

PRIMM was designed by Sue and her collaborators as a language-first approach where students begin not by writing code, but by reading it.

What is PRIMM?

PRIMM stands for ‘Predict, Run, Investigate, Modify, Make’. In this approach, rather than copying code or writing programs from scratch, beginners instead start by focussing on reading working code.

In the Predict stage, the teacher provides learners with example code to read, discuss, and make output predictions about. Next, they run the code to see how the output compares to what they predicted. In the Investigate stage, the teacher sets activities for the learners to trace, annotate, explain, and talk about the code line by line, in order to help them understand what it does in detail.

In the seminar, Sue took us through a mini example of the stages of PRIMM where we predicted the output of Python Turtle code. You can follow along on the recording of the seminar to get the experience of what it feels like to work through this approach.

The impact of PRIMM on learning

The PRIMM approach is informed by research, and it is also the subject of research by Sue and her collaborators. They’ve conducted two studies to measure the effectiveness of PRIMM: an initial pilot, and a larger mixed-methods study with 13 teachers and 493 students with a control group.

The larger study used a pre and post test, and found that the group who experienced a PRIMM approach performed better on the tests than the control group. The researchers also collected a wealth of qualitative feedback from teachers. The feedback suggested that the approach can help students to develop a language to express their understanding of programming, and that there was much more productive peer conversation in the PRIMM lessons (sometimes this meant less talk, but at a more advanced level).

The PRIMM structure also gave some teachers a greater capacity to talk about the process of teaching programming. It facilitated the discussion of teaching ideas and learning approaches for the teachers, as well as developing language approaches that students used to learn programming concepts.

The research results suggest that learners taught using PRIMM appear to be developing the language skills to talk coherently about their programming. The effectiveness of PRIMM is also evidenced by the number of teachers who have taken up the approach, building in their own activities and in some cases remixing the PRIMM terminology to develop their own take on a language-first approach to teaching programming.

Future research will investigate in detail how PRIMM encourages productive talk in the classroom, and will link the approach to other work on semantic waves. (For more on semantic waves in computing education, see this seminar by Jane Waite and this symposium talk by Paul Curzon.)

Resources for educators who want to try PRIMM

If you would like to try out PRIMM with your learners, use our free support materials:

Join our next seminar

If you missed the seminar, you can find the presentation slides alongside the recording of Sue’s talk on our seminars page.

In our next seminar on Tuesday 1 December at 17:00–18:30 GMT / 12:00–13:30 ET / 9:00–10:30 PT / 18:00–19:30 CEST. Dr David Weintrop from the University of Maryland will be presenting on the role of block-based programming in computer science education. To join, simply sign up with your name and email address.

Once you’ve signed up, we’ll email you the seminar meeting link and instructions for joining. If you attended this past seminar, the link remains the same.

The post PRIMM: encouraging talk in programming lessons appeared first on Raspberry Pi.

Mars Clock

A sci-fi writer wanted to add some realism to his fiction. The result: a Raspberry Pi-based Martian timepiece. Rosie Hattersley clocks in from the latest issue of The MagPi Magazine.

The Mars Clock project is adapted from code Phil wrote in JavaScript and a Windows environment for Raspberry Pi

Ever since he first clapped eyes on Mars through the eyepiece of a telescope, Philip Ide has been obsessed with the Red Planet. He’s written several books based there and, many moons ago, set up a webpage showing the weather on Mars. This summer, Phil adapted his weather monitor and created a Raspberry Pi-powered Mars Clock.

Mission: Mars

After writing several clocks for his Mars Weather page, Phil wanted to make a physical clock: “something that could sit on my desk or such like, and tell the time on Mars.” It was to tell the time at any location on Mars, with presets for interesting locations “plus the sites of all the missions that made it to the surface – whether they pancaked or not.”

The projects runs on a 2GB Raspberry Pi 4 with official 7-inch touchscreen

Another prerequisite was that the clock had to check for new mission file updates and IERS bulletins to see if a new leap second had been factored into Universal Coordinated Time.

“Martian seconds are longer,” explains Phil, “so everything was pointing at software rather than a mechanical device. Raspberry Pi was a shoo-in for the job”. However, he’d never used one.

“I’d written some software for calculating orbits and one of the target platforms was Raspberry Pi. I’d never actually seen it run on a Raspberry Pi but I knew it worked, so the door was already open.” He was able to check his data against a benchmark NASA provided. Knowing that the clocks on his Mars Weather page were accurate meant that Phil could focus on getting to grips with his new single-board computer.

Phil’s Mars Weather page shows seasonal trends since March 2019.

He chose a 2GB Raspberry Pi 4 and official-inch touchscreen with a SmartiPi Touch 2 case. “Angles are everything,” he reasons. He also added a fan to lower the CPU temperature and extend the hardware’s life. Along with a power lead, the whole setup cost £130 from The Pi Hut.

Since his Mars Clock generates a lot of data, he made it skinnable so the user can choose which pieces of information to view at any one time. It can display two types of map – Viking or MOLA – depending on the co-ordinates for the clock. NASA provides a web map-tile service with many different data sets for Mars, so it should be possible to make the background an interactive map, allowing you to zoom in/out and scroll around. Getting these to work proved rather a headache as he hit incompatibilities with the libraries.

Learn through experience

Phil wrote most of the software himself, with the exception of libraries for the keyboard and FTP which he pulled from GitHub. Here’s all the code.

The Mars Clock’s various skins show details of missions to Mars, as well as the location’s time and date

He used JavaScript running on the Node.js/Electron framework. “This made for rapid development and is cross-platform, so I could write and test it on Windows and then move it to the Raspberry Pi,” he says. With the basic code written, Phil set about paring it back, reducing the number and duration of CPU time-slices the clock needed when running. “I like optimised software,” he explains.

His decades as a computer programmer meant other aspects were straightforward. The hardware is more than capable, he says of his first ever experience of Raspberry Pi, and the SmartiPi case makers had done a brilliant job. Everything fit together and in just a few minutes his Raspberry Pi was working.

The SmartiPi Touch 2 case houses Raspberry Pi 4 and a fan to cool its CPU

Since completing his Mars Clock Phil has added a pi-hole and a NAS to his Raspberry Pi setup and says his confidence using them is such that he’s now contemplating challenging himself to build an orrery (a mechanical model of the solar system). “I have decades of programming experience, but I was still learning new things as the project progressed,” he says. “The nerd factor of any given object increases exponentially if you make it yourself.”

The MagPi Magazine | Issue 99

Check out page 26 in the latest issue of The MagPi Magazine for a step-by-step and to learn more about the maker, Phillip. You can read a PDF copy for free on The MagPi Magazine website if you’re not already a subscriber.

The post Mars Clock appeared first on Raspberry Pi.

ISS Mimic: A Raspberry Pi-powered International Space Station model that syncs with the real thing

A group of us NASA engineers work on the International Space Station (ISS) for our day-jobs but craved something more tangible than computer models and data curves to share with the world. So, in our free time, we built ISS Mimic. It’s still in the works, but we are publishing now to celebrate 20 years of continuous human presence in space on the ISS. 

Here’s the latest version of ISS Mimic, filmed by YouTube’s finest Estefannie Explains it All

This video was filmed and produced by our friend, new teammate, and Raspberry Pi regular Estefannie of Estefannie Explains it All. Most of the images in this blog are screen grabbed from her wonderful video too.

What does Mimic do?

Initial prototype of ISS Mimic ready for STEM outreach at FIRST Robotics Championship

ISS Mimic is a 1% scale model of the International Space Station, bringing the American football field-sized beauty down to a tabletop-sized build. Most elements in the final version of the build which you see in the video are 3D printed — recently even the solar arrays. It has 12 motors: 10 to control the solar panels and two to turn the thermal radiators. All of these are fed by live data streaming from the ISS, so what you see on ISS Mimic is what’s happening that very moment on the real deal up in space.  

Physical connection

Lunch onboard the real ISS

Despite the global ISS effort, most people seem to feel disconnected from space exploration and all the STEAM goodness within. Beyond headlines and rocket launches, even space enthusiasts may feel out of touch. Most of what is available is via apps and videos, which are great, but miss the physical aspect.

Some of the team showing off an earlier version of their homage to the ISS

ISS Mimic is intended to provide an earthbound, tangible connection to that so-close-but-so-far-away orbiting science platform. We want space excitement to fuel STEAM interest.

Raspberry Pi brains and Braun

As you may have guessed, a Raspberry Pi is the brain of the business.  Raspberry Pi taps into NASA’s public ISS live data stream to parse the telemetry into the bits we want. There’s JavaScript and tons of Python, including Kivy for the graphics.

A screen grab of the home screen for the mimic program
The main screen for the Mimic program

Users toggle through various touchscreen data displays of things like battery charge states, electrical power generated, joint angles, communication dish status, gyroscope torques, and even airlock air pressure — fun to watch prior to a spacewalk!

The user can also touchscreen-activate the physical model, in which case Raspberry Pi sends the telemetry along to Arduinos, which in turn command motors in the model to do their thing, rotating the solar panels and thermal radiators to the proper angle. The solar panel joints use compact geared DC motors with Hall-effect sensors for feedback. The sensor signals are sent back down to the Arduino, which keeps track of the position of each joint compared to ISS telemetry, and updates motor command accordingly to stay in sync. 

A diagram of the International Space Station tracking its speed
Some of the data Raspberry Pi can receive

The thermal radiator motors are simpler. Since they only rotate about 180° total, a simple RC micro servo is utilised with the desired position sent from an Arduino directly from the Raspberry Pi data stream.

When MIMIC is in ‘live mode’, the motor commands are the exact data stream coming from ISS. This is a fun mode to leave it in for long durations when it’s in the corner of the room. But it changes slowly, so we also include advanced playback, where prior orbit data stored on Raspberry Pi is played back at 60× speed. A regular 90-minute orbit profile can be played back in 90 seconds.

A diagram of the International Space Station orbit tracker
Tracking the ISS orbit

We also have ‘disco mode’, which may have been birthed during lack of sleep, but now we plan to utilise it whenever we want to grab attention — such as to alert users that the ISS is flying overhead.

LED addiction

We may have a mild LED addiction, and we have LEDs embedded where the ISS batteries would live at the base of the solar arrays. They change colour with the charge voltage, so we can tell by watching them when the ISS is going into Earth’s shadow, or when the batteries are fully charged, etc.

That doesn’t look like TOO many LEDs to us…

A few times when we were working on the model and the LEDs suddenly changed, we thought we had bumped something. But it turned out the first array was edging behind Earth. These are fun to watch during spacewalks, and the model gives us advanced notice that the crew is about to be in darkness.

We plan to cram more LEDs in to react to other data. The project is open source, so anyone can build one and improve the design — help wanted!  After all, the ISS itself is a worldwide collaboration with 19 countries participating by providing components and crew. 

Chaotic wire management

The solar panels on the ISS are mounted on what’s known as the ‘outboard truss’ — one each on the Port and Starboard ends of ISS. Everything on the outboard truss rotates together as part of the sun-tracking (in addition to each solar array rotating individually). So, you can’t just run the power/signal wires through the interface or they would twist and break. ISS Mimic has the same issue.

A closer look at the newest ISS Mimic’s mini solar panels

Even though our solar panels don’t generate power, their motors still require power and signals. The ISS has a specialised, unique build; but fortunately we were able to solve our problem with a simple slip ring design sourced from Amazon. 

So twisty. So shiny. So tricky to manage cables for.

Wire management turned out to be a big issue for us. We had bird nests in several places early on (still present on the Port side solar), so we created some custom PCBs just for wire management, to keep the chaos down. We incorporated HDMI connectors and cables in some places to provide nice shielding and convenient sized coupling — actually a bit more compact than the Ethernet we’d used before.  

The real ISS flexing its power-generating solar panels in space

Also, those solar panels are huge, and the mechanism that supports the outboard truss (everything on the sides that rotate together) on the ISS includes a massive 10 foot diameter bull gear called the Solar Alpha Rotary Joint. A pinion gear from a motor interfaces with this gear to turn it as needed.

Some of the 3D printed parts for the latest iteration of the build

We were pleasantly surprised that our 3D-printed bull gear held up quite well with a similar pinion-driven design. Overall, our 3D prints have survived better than expected. We are revamping most models to include more detail, and we could certainly use help here.

Education focus

Our sights are set firmly on educators as our primary area of focus, and we’ve been excited to partner with Space Center Houston to speak at public events and a space exploration educator conference with international attendance earlier this year.

Team ISS Mimic at STEM outreach during the FIRST Robotics National Championship

The feedback has been encouraging and enlightening. We want to keep getting feedback from educators, so please provide more insights by either commenting on this blog or via the contact info listed at the bottom. 

NASA Mission Control — failure is actually an option… sometimes

A highlight for the team was when the ISS Mimic prototype was requested to live for a month in NASA’s Mission Control Center and was synced to live data during an historic spacewalk. Mimic experienced an ‘anomaly’ when a loose wire caused one of the solar panel motors to spin at 100× the normal rate. 

Our tiny computer with the ISS Mimic’s control panel

You’ll be happy to know that none of the engineering professionals were fooled into thinking the real ISS was doing time-trials. Did I mention it’s still a work in progress? You can’t be scared of failure (for non-critical applications!), particularly when developing something brand-new. It’s part of shaking out problems and learning.

Space exploration has an exciting Future

Showing off ISS Mimic during a STEM outreach event at the Space Center in Houston

It’s an exciting time in human and robotic spaceflight, with lots of budding projects and new organisations joining the effort. This feels like a great time to deepen our connection to this great progress, and we hope ISS Mimic can help us to do that, as well as encourage more students to play in coding, mechatronics, and STEAM.

Shoutouts and social

Hi to [most of] Team ISS Mimic!

You can keep up with Team ISS Mimic on Facebook, Instagram and Twitter. For more info or to join the team, check out our GitHub page and Discord.

One of the best parts of this project has been teaming up with organisations to share the love. We partner with a non-profit makerspace near NASA called Creatorspace, for tools, materials, and outreach.  And an awesome local 3D printer manufacturer, re:3D, has joined us to print some of our larger components for free and is helping to refine our models.  Space Center Houston (NASA’s visitor centre) invited us to present to public and educator events, and generously allowed us to spend a full day filming in their beautiful facility.   Our earliest supporter was Boeing, who we’ve worked with to facilitate outreach to educators and students from the start.  And of course we are thankful to NASA for providing the public data stream that makes the project possible.

Astro Pi

Did you know that there are Raspberry Pi computers aboard the real ISS that young people can run their own Python programs on? Find out more at astro-pi.org.

The post ISS Mimic: A Raspberry Pi-powered International Space Station model that syncs with the real thing appeared first on Raspberry Pi.

❌