Tag Archives: Uncategorized

Picademy Cymru

via Raspberry Pi

Road trip.

These are the two words that Clive, our Director of Education says to me on a regular basis. In fact, he has promised me a road trip to Pencoed in Wales to visit the factory where our Raspberry Pis are manufactured in the UK for some time now. Not just any road trip, but one that involves an ice cream van serving raspberry ripple ice creams (avec flake) whilst motoring across the country to Sonic Pi melodies, containing the entire Foundation crew. You would be forgiven for thinking that this is all just mere ravings of a crazy ex-teacher. But you’d be wrong.

The dream machine

The dream machine

I’m pleased to be able to announce that this dream is to become a reality! Albeit, minus the ice cream van. For one time only, we are taking Picademy, our free CPD training programme for teachers, on the road to Wales this coming November, hosted at the Sony UK Technology Centre in Pencoed, South Wales. We have 24 places on Picademy Cymru, taking place on 19th & 20th November, for practicing classroom teachers in Wales. If you fit this description then please fill out our application form here or via our Picademy page. We are looking for fun, experimental, not-afraid-to-have-a-go, Welsh teachers willing to share their experiences and practices with others. Primary and secondary teachers from any subject specialism are welcome – you don’t need any computing experience, just enthusiasm and a desire to learn.

Map_of_Wales

wales

A few months ago, Dr Tom Crick, Senior Lecturer in Computing Science (and Director of Undergraduate Studies) in the Department of Computing & Information Systems at Cardiff Metropolitan University and Chair of Computing at School Wales got in touch to encourage us to run a Picademy in Wales, offering the support and encouragement we needed in order to make it happen. He says:

This is perfect timing for the first Picademy Cymru and a great opportunity for teachers, even though we still have significant uncertainty around reform of the ICT curriculum in Wales. Nevertheless, there are hundreds of teachers across Wales who have been working hard, particularly at a grassroots level with Computing At School and Technocamps, to embed more computing, programming and computational thinking skills into the existing ICT curriculum, as well as preparing for the new computer science qualifications. This will be a fantastic event and I look forward to helping out!

Join us for a tour of the factory, hands-on Raspberry Pi workshops, cross-curricular resource generation, and Welsh cakes. (If Eben and Liz don’t eat all the Welsh cakes before we get our hands on them. It’s been known to happen before.)

2014 OSHWA Board Nominations Open until Oct. 15

via Open Source Hardware Association

OSHWA is looking for 2 new faces to join the board of directors for the Open Source Hardware Association. Please fill out this form to become a nominee or forward the link to the person you wish to nominate for them to fill out. The purpose of this form will be to tell voting members a bit about yourself. We will be publishing the nominees and their answers on Oct. 15th. Board members hold a 2-year position. Once board members have been chosen by the community, the current board will appoint a new President, VP, and Secretary. Board responsibilities include fundraising, advising on goals and direction, and carrying out compliance of the organization’s purposes and bylaws. Board members David Mellis, Star Simpson, Emile Patron, Jeffery Warren, and Addie Wagenknecht will remain on the board. We thank Danese Cooper and Windell Oskay for their years of service. Nominations will be open until Oct. 15th.

Nominee form.

Member voting will take place Oct. 20th and 21st. Want to vote in the election? Become a memberif you’re not already! Please note that only individuals can vote, corporate members cannot.

CNBC visit Pi Towers

via Raspberry Pi

At the start of September, a film crew from CNBC came to visit Cambridge. They spent some time with us at Pi Towers, and came to the Cambridge Jam the next day to talk to some of the kids there who use the Raspberry Pi. They produced two short videos, both full of footage from the Jam and our office – see how many familiar faces you can spot!

A digital making community for wildlife: Naturebytes camera traps

via Raspberry Pi

Start-up Naturebytes hopes their 3D printed Raspberry Pi camera trap (a camera triggered by the presence of animals) will be the beginning of a very special community of makers.

Supported by the Raspberry Pi Foundation’s Education Fund and Nesta, Naturebytes aims to establish a digital making community for wildlife with a very important purpose. Their gadgets, creations and maker kits (and, hopefully, those of others who get involved) will be put to use collecting real data for conservation and wildlife research projects – and to kick it all off, they took their prototype 3D printed birdbox-style camera trap kit to family festival Camp Bestival to see what everyone thought.

NatureBytes camera trap prototype

If you were one of the lucky bunch to enjoy this year’s Camp Bestival, you’d have seen them over in the Science Tent with a colourful collection of their camera trap enclosures. The enclosure provides a snug home for a Raspberry Pi, Pi camera module, passive infrared sensor (PIR sensor), UBEC (a device used to regulate the power) and battery bank (they have plans to add external power capabilities, including solar, but for now they’re using eight trusty AA batteries to power the trap).

A colourful collection of camera trap enclosures

A colourful collection of camera trap enclosures

The PIR sensor does the job of detecting any wildlife passing by, and they’re using Python to control the camera module, which in turn snaps photos to the SD card. If you’re looking for nocturnal animals then the Pi NoIR could be used instead, with a bank of infrared LEDs to provide illumination.

Naturebytes says:

When you’re aiming to create maker kits for all manner of ages, it’s useful to try out your masterpiece with actual users to see how they found the challenge.

Naturebytes at Camp Bestival

Explaining how the camera trap enclosures are printed

Assembling camera traps at Camp Bestival

Camp Bestival festival-goers assembling camera traps

With screwdrivers at the ready, teams of festival-goers first took a look at one of our camera enclosures being printed on an Ultimaker before everyone sat down to assemble their own trap ready for a Blue Peter-style “Here’s one I made earlier” photo opportunity (we duct-taped a working camera trap to the back of a large TV so everyone could be captured in an image).

In fact, using the cam.start_preview() Python function we could output a few seconds of video when the PIR sensor was triggered, so everyone could watch.

One camera trap in action capturing another camera trap

Naturebytes duct-taped a working camera trap to the back of a large TV so everyone could see a camera trap in action

Our grand plan is to support the upcoming Naturebytes community of digital makers by accepting images from thousands of Naturebytes camera traps out in gardens, schools or wildlife reserves to the Naturebytes website, so we can share them with active conservation projects. We could, for example, be looking for hedgehogs to monitor their decline, and push the images you’ve taken of hedgehogs visiting your garden directly to wildlife groups on the ground who want the cold hard facts as to how many can be found in certain areas.

Job done, Camp Bestival!

Job done, Camp Bestival!

Keep your eyes peeled – Naturebytes is powering up for launch very soon!

SplitRadixReal FFT Library.

via coolarduino

It’s well known, that running complex fft subroutine in embedded system isn’t rational. Input data have no complex imaginary part, and consequently about 50% of processing power lost for nothing. Another aspect, is memory consumption, complex fft output has 2x redundancy. Solution to this problems is also known, SplitRadix algorithm.  So I did once more same trick, like with Radix-4 code. I take readily available C code  of the SplitRadix, thanks to http://www.jjj.de/  and convert it to arduino library. The most troubling part was to figure out corresponding addresses in the Sinewave LUT, that would substitute integer sine and cosine values.

Difference between SplitRadixReal and Radix4:

  •  SplitRR: 5075 usec.
  •  RDX4:   6968 usec.

New library runs 1.4 times faster. And requires  2x less memory to run.

An example of the application, where saving on memory size doubles spectral resolution (and saves uCPU clock cycles as well), is my latest project Sound Camera,  I discovered that I can’t  get desirable frequency resolution (20 Hz) with my Radix4 fft library in this application. Its simply demands too much memory when fft size 2048,  all DUE 96 kbytes, and my compiler wasn’t agree with that: “section `.bss’ is not within region `ram’ collect2: ld returned 1 exit status”. And it’s on DUE SAM3X8E with its huge memory size, compare, for example, to Maple STM32 and bunch others, similar cortex-3 derivatives.

Seen this before in your sketch:

  • int f_r[FFT_SIZE] = { 0};
    int f_i[FFT_SIZE] = { 0};

Great news, you don’t need  f_i[.] anymore.

And last, re-print :

Created for Arduino DUE & like boards, word size optimized for 12-bits data input.

FFT takes as input ANY size of array 8, 16, 32, 64, 128, 256, 512, 1024, 2048.

Demands 2-x less memory to run !

(Does DSP Lib offer all this options? Please, drop me a message, if it does.)

LInk:   SplitRadixReal Library.


Updates to Minecraft Documentation – and a Python 3 version is on the way!

via Raspberry Pi

No … we’re not adding a Start Menu or a paperclip assistant. This update has nothing to do with Microsoft’s acquisition of Mojang. See the note below for information about this.

mcpi-game

You may remember when Mojang released Minecraft: Pi edition for free on Raspberry Pi back in early 2013. If you’re unfamiliar, Minecraft is a popular sandbox open world-building game (like on-screen lego) available for a number of different platforms like PCs, consoles and phones. The Pi edition has a Python programming interface allowing users to use code to build things and manipulate the virtual world around them. It’s a great way to learn coding, and there are plenty of great projects out there people have done and shared with the world.

mcpi-flying

Last week when we announced the release of the new Raspbian image, we mentioned that Minecraft is now installed by default. Now if you download NOOBS or the standalone Raspbian image, it will come with Minecraft pre-installed. It’s also worth mentioning that the Minecraft application is packaged, so rather than downloading the zip file you can easily install it like a standard application:

sudo apt-get update
sudo apt-get install minecraft-pi

The accompanying Python module will be installed globally along with the game itself you don’t need to save your Python scripts in a particular folder like you did before. If you’re following books, guides, tutorials or worksheets that were written before, the code will still work the same and if you install Minecraft the new way you’ll be able to save your scripts anywhere.

Once it’s installed, here’s the basic setup to get a “Hello world” in Minecraft:

from mcpi import minecraft

mc = minecraft.Minecraft.create()

mc.postToChat("Hello world")

mcpi-idle

When we launched the new Raspberry Pi website in April it came with a documentation section, which we’ve been expanding ever since. In May we announced the usage guides within this documentation were complete, which feature basic how to guides for using each of the main applications on Raspberry Pi.

We’ve just revamped the Minecraft section to explore more of the fundamental components of the Pi edition and its programming interface, including installation, running the game and Python side-by-side, exploring the programming interface and getting a good all-round introduction to what can be done.

You’ll also find this guide in our resources section.

mcpi-tnt-explode

The edition we have at the moment was built for Python 2, and that’s still the case. However, the education team brought this up at PyConUK at the weekend and a team of developers offered to work on porting it to Python 3 – with some success!

IMG_20140922_114131.resized

The project is on GitHub and you can download the repository and use it the way you would use the old version of Minecraft (when you downloaded a zip) if you want to test it – just use IDLE 3 instead! We’re also planning to make some improvements to the API to make it more Pythonic and more intuitive. I’m not sure what the timescale will be for the port, but watch this space for news.

Python 3 is really important to us and we’re keen to make sure all libraries people use on the Pi are available in Python 3. Python 2 should not be the default, we should be pushing forward and adapting Python 3. As it says on the Python 2 or Python 3 page on python.org:

Short version: Python 2.x is legacy, Python 3.x is the present and future of the language
python.org

So if you’re the maintainer of a Python library, please help by making sure it’s available for Python 3. If you’re using a Python library that’s not available in Python 3 – please let us know so we can add it to the list and we’ll do what we can do get them ported.

One last note about the Microsoft acquisition of the Minecraft development company Mojang: many people have asked us what this means for the future of Minecraft on Raspberry Pi. In statements on their website, Microsoft claim they intend to continue to support Minecraft on all existing platforms. We don’t know for sure what the future will bring but Minecraft is important to us, particularly its use in education, and we’re confident that it won’t be taken from us.

PiKon and other Pi projects from Sheffield University

via Raspberry Pi

Sheffield has been a maker city for many years – the thriving steel industry dates back to the 14th century. Today it has the likes of Pimoroni, who recently moved in to a huge new factory, making cases, HATs, media centres and more.

IMG_20140824_135803

The good ship Pimoroni

The University of Sheffield has been undertaking a number of Raspberry Pi projects in the last couple of years. The computer science department has a research group called Sheffield Pi-Tronics led by Hamish Cunningham. One project of note is their new Pi-powered telescope – PiKon. Not to be confused with PyCon

The £100 3D printed Pi-powered telescope

The University has released incredible images of the moon taken with the Raspberry Pi’s camera module connected to a 3D printed telescope which costs just £100 to make from readily available parts.

The moon

Moon, the

The Pikon astro-cam is a collaborative project by the Department of Physics at the University of Sheffield and Mark Wrigley of Alternative Photonics, a small company based in north Sheffield. The project was set up to deliver a working telescope for the Festival of the Mind event.

They have a working model and they’re aiming to make all the 3D printing resources and instructions available soon. They’re also looking for help producing a simple interface to make it more accessible to all:

So far, we have a working telescope which is operated by entering command lines into the Raspberry Pi. We are looking for enthusiasts and educators to help us take things further. We want to encourage people to create, innovate, educate and share their efforts on an open source basis.

pikonic.com

How it works (from pikonic.com):

visualtelescope2

The PiKon Telescope is based on the Newtonian Reflecting Telescope. This design uses a concave mirror (objective) to form an image which is examined using an eyepiece. The mirror is mounted in a tube and a 45 degree mirror is placed in the optical path to allow the image to be viewed from the side of the tube.

visualtelescope3The PiKon Telescope is based on a very similar design, but the image formed by the Objective is focused onto the photo sensor of a Raspberry Pi Camera. The camera sensor is exposed by simply removing (unscrewing) the lens on the Pi Camera. Because of the small size of the Raspberry Pi Camera board, it is possible to mount the assembly in the optical path. The amount of light lost by doing this is similar to the losses caused by mounting the 45 degree mirror in a conventional Newtonian design.

Former physicist and member of the Institute of Physics, Mark Wrigley, said:

We’ve called this project Disruptive Technology Astronomy because we hope it will be a game changer, just like all Disruptive Technologies.

We hope that one day this will be seen on a par with the famous Dobsonian ‘pavement’ telescopes, which allowed hobbyists to see into the night skies for the first time.

This is all about democratising technology, making it cheap and readily available to the general public.

And the PiKon is just the start. It is our aim to not only use the public’s feedback and participation to improve it, but also to launch new products which will be of value to people.

Also this week the group launched Pi Bank – a set of 20 kits containing Pi rigs that are available for short-term loan. This means local schools and other groups can make use of the kits for projects without having to invest in the technology themselves, with all the essentials, plenty of extra bits to play with – and experts on hand to help out.

pi-bank-stack

pi-bank-kit

See more of the Sheffield Pi-Tronics projects at pi.gate.ac.uk and read more about PiKon at pikonic.com

Any positive comments about Sheffield are completely biased as that’s where I’m from. If you’re interested in the history of Sheffield there’s a great documentary you should watch called The Full Monty.

World Maker Faire New York — a report direct from the Americas

via Raspberry Pi

Rachel and Clive spent the weekend with the Pimoroni crew at the World Maker Faire New York. Here is the news report that they telegrammed via Cyrus W. Field’s magnetic transatlantic telegraph cable.


They call Maker Faire the “Greatest Show (and Tell) on Earth” and  they’re probably right. Certainly there’s nothing on Earth that can prepare you for it, it’s that different. 2014-09-20 13.27.08

It starts even before you get there. Riding the E train in from Manhattan you can play “Spot who’s going to Maker Faire”. It’s pretty easy: they have this look of happy anticipation and glee that sets them apart from the people just going to work or to their proctologist. (OK, so some of them are dressed in robot suits made out of takeaway containers or have Asimov/Yoda/Spock quotes tattooed on their calves: there are no bonus points for picking those people out.) But it’s no geek meet: it’s refreshing to see huge numbers of school and family groups there as well as the usual suspects.

IMG_20140920_123020

IMG_20140920_122850

As you near the New York Hall of Science the buzz of the crowd is augmented by not-your-everyday sounds: exploding food, crackling Tesla coils and a 51ft long, pedal-powered crocodile blaring out “Soul man”. The site is huge, taking at least three days just to get to the toilet and back*.

Mo from Five Ninjas talked constantly for 2 days without a single break

Mo from Five Ninjas talked constantly for 2 days without a single break

The Raspberry Pi stand proved as popular as ever and we talked to hundreds of young people, educators, makers and parents. What was interesting was the increased awareness of the Raspberry Pi as a tool for making and learning. Last year, common questions were “What’s that?” or “What does it do?” Now the majority of people wanted to know how to use the Pi to do specific things; or how to move on from the basics; or how to use it in education.

IMG_20140920_152630~2

Rachel talking about digital creativity

Rachel talking about digital creativity

We were also delighted to see the Raspberry Pi used in so many projects and products around the show and want to thank all of the folk using it, especially those who we didn’t manage to speak to on our whistle-stop tour of the Faire. Cheers!

2014-09-20 17.07.31

IMG_20140920_123656

IMG_20140920_105603

The exhibits and demonstrations at Maker Faire are as eclectic as it comes. Some of the stuff is fun and some serious. Some are thought provoking and some simply silly (we like silly). But as a whole it’s testament to creativity, ingenuity, invention, engineering, whimsy and science. Best of all, making things has learning built in.

IMG_20140921_174323

The Hall of Science was built as part of the 1964 New York World’s Fair, a theme of which was “Man’s achievement on a shrinking globe in an expanding universe”. Looking at some of the amazing things I’ve seen over the past weekend it’s clear that this sentiment is even more fitting than ever.

Winning!

Winning!


 

[*This may have just been me. The night before I left for New York for Maker Faire, a giant skeleton ninja shimmied over my wall and sowed the back yard with poisoned giant skeleton ninja caltrops. Ten minutes before my taxi arrived I stepped on one of them. Inoculated to a depth of 10mm with every bacterium known to science I set off for the airport and two days of dragging a foot the size and toastiness of a well-fed coypu. (N.B. The caltrops may have been a needle sharp, week-old lamb neck bone that my brother’s dog had been gnawing on. The effect was the same.)]

Snakes and Ladders, Pi style

via Raspberry Pi

Les Pounder is a big player in the Linux & free software community in the North West. I first met him a few years ago when he was running Barcamp Blackpool, Blackpool GeekUp, Oggcamp in Liverpool, UCubed (Ubuntu & Upstream Unconference) in Manchester plus Linux user groups and other events. When I set up the Manchester Raspberry Jam in 2012, it was modelled on the style of a UCubed event – and Les came along to help out.

Les was working as a systems administrator around the time the Pi came out. Within a year or so of the community blossoming and his involvement growing, he decided to embark on a new career with the Pi at its heart. He got some work running CPD for teachers, introducing them to the Pi and to coding, he started writing articles for Linux Format, he started putting Raspberry Pi projects together for Element14, and since Linux Voice began he’s been contributing articles and Pi tutorials for them. He’s also currently working on a book with Wiley on Raspberry Pi & Arduino projects.

Les recently set up the Blackpool Raspberry Jam – and at their inaugural event he demonstrated a new project he made which brings the traditional board game Snakes and Ladders in to the digital world of IO with the Model B+. It’s called Pythons and Resistors. Over to Les:

For this project we will look back to our childhood and bring a much loved game from our past into the future. The humble board game.

les1

Board games have been a traditional family pastime for many generations but with the rise of computer games their novelty has started to dwindle. These card and paper based games have little to offer the children of today who have been brought up on a diet of downloadable content packs and gamer scores.

But what if we could take a game from yesteryear and adapt it using the Raspberry Pi?

Meet the latest interactive board game: Pythons and Resistors.

board

The board game is based on a simple snakes and ladders setup, with 100 squares in total via a grid of 10 x 10 squares. The object of the game is for 2 or more players to roll a dice and move their game piece to match the number given on the dice. If the player lands on a python’s head, then they will slither down the game board to the tail of the Python. If the player lands on the bottom of a resistor then they will climb up the game board. The winner is the first player to reach square 100, which is at the top left of the board.

dice_LED

 

gpio

See the full tutorial in the Element 14 community and see the final code on Les’s GitHub.

World Maker Faire and PyConUK

via Raspberry Pi

It’s been quiet around Pi Towers lately. Quiet and disquieting, rather like standing in your nan’s best front room when you were a kid and really needing a wee but were too afraid to break the silence. But we have good and exciting reasons for our quietude: we’ve all been busy preparing for two of our biggest events of the year. This weekend the education team is spreading it’s feelers of learning goodness around the world, from the Midlands to East Coast America.

world-maker-faire

Carrie Anne, Dave and Ben are at PyConUK while Rachel and I, along with James (our Director of Hardware), were beaten with a sock full of oranges until we sobbingly agreed to go to World Maker Faire New York.

The Maker Faire contingent will be joining our friends on the Pimoroni stand, demoing all sorts of goodies both new and old; selling shiny swag; giving out freebies; and talking and talking until we cough our larynxes into our fifteenth cup of Joe (as my American-English dictionary tells me I should call coffee if I want to be street).

2014-09-19 10.31.31

New swag bags! Grab ‘em while they’re hot

Our director of hardware engineering James Adams will be there – he’s giving a talk on What’s next at Raspberry Pi? on [Saturday at 2.30pm according to this / Sunday 2pm according to this] in the NYSCI Auditorium – and Rachel and I will be speaking about digital creativity (details TBA). If you are at Maker Faire do come and visit us. At Maker Faire Bay Area earlier this year it was great to see so many educators and I hope to speak to at least as many in New York. But whatever your interests in Raspberry Pi – from digital creativity to hardware to making stuff (of course!) – we would love to see you.

If you can’t make it to New York, here’s a Q&A Make’s Matt Richardson conducted with James:

Meanwhile in Coventry Carrie Anne, Ben, Dave and Alex are running Python workshops, giving talks about Raspberry Pi in education and chatting to teachers, educators and developers in the Python community.

pyconuk

pyconuk2

Raspberry Pi team hard at work

Fresh Coffee at Mailchimp

via Raspberry Pi

Ben: Here’s a guest post from Steven Sloan, a developer at MailChimp.

IMG_4456

Grounds for innovation

Here at MailChimp, we’re always trying to listen hard and change fast. Turns out, this requires a good bit of coffee. Each department has its own take on how to keep the stuff flowing, mostly with the standard Bunn-O-Matic commercial machines. A few folks regularly avail themselves of our espresso setup. The developers fill two airpots—one with regular, the other double strength.

And then there’s the marketing team and our precious Chemex.

We make a pour-over pot once every hour or so, all day long, 5 days a week, 50-something weeks a year. Last December, when we were gathering data for our annual report, we got curious about how many Fresh Pots that might amount to. We tried to count it up, but begrudgingly had to accept the fact we didn’t have a good measure beyond pounds consumed. We even tried to keep track with a bean counter, but that didn’t last long.

For a while, the exact nature of our coffee consumption seemed like it would remain just another mystery of the universe. But then one day, talking to Mark while waiting on yet another Fresh Pot, I said, “Hey, I bet we could track the temperature with a Raspberry Pi and post to the group chat when there’s a fresh one.”

I wasn’t too serious, but Mark’s response was one often heard around MailChimp when ridiculous projects are proposed: “Sounds great, just let me know what you need to get it done.”

A few days later, I had a materials list drawn up from Adafruit’s thermometer tutorial, and we were off to the races.

IMG_4442

A fresh Pi

With a Raspberry Pi in hand, the first thing I did was add a script to the boot process that sent an email using Mandrill with its IP so I could find it on our network without trouble.

Then, I had to tackle the problem of detecting pot states with only a single datapoint: current temperature. I hoped that comparing the running averages of different time spans would be enough to determine the pot’s status. (The average Chemex temperature over the course of a few minutes, for instance, would tell us something different than the average temperate over the course of an hour.)

Since this was a greenfield project, I wanted to work with an unfamiliar language. I felt like the more functional nature of Clojure would be a great fit for passing along a single piece of state. This turned out to be a great decision, and I’ll explain why in a minute.

Graph it home

I hacked together a quick program that would spit out the current temperature, minute’s running average, hour’s running average, and the running average’s rate of change to a log file so I could analyze them.

...
{"current":32.062, "minute":24.8747, "hour":23.5391, "running-rate":0.039508}
{"current":32.437, "minute":25.0008, "hour":23.5635, "running-rate":0.0423943}
{"current":32.875, "minute":25.1322, "hour":23.5897, "running-rate":0.045361}
{"current":33.625, "minute":25.2738, "hour":23.6177, "running-rate":0.048569}
{"current":33.625, "minute":25.413, "hour":23.6476, "running-rate":0.05159}
{"current":33.625, "minute":25.55, "hour":23.6793, "running-rate":0.054437}
...

Log files in hand, I temporarily turned back to Ruby using the wonderful Gruff charting library to visualize things and make patterns easier to spot.

A few batches of hot water gave me a decent idea what things should look like, so I moved our coffee equipment to my desk to get some live data. This let me check in with the actual running state of the program and compare it with the status of the pot (and led to some coworker laughs and a wonderful smell at my workspace all day).

07-c

A brewing or fresh pot is easy to recognize, but figuring out when the pot is empty turned out to be a little tricky. It takes a while for the Chemex to completely cool off, which means it could be empty and still warm, which I’m sure would lead to more than a few disappointing trips to the kitchen. Luckily, the rate a pot cools tells us if it is empty or not—for instance, a half-full pot stays warm longer than an empty one simply because of the coffee still in it. Always nice to have physics on your side.

Watchers for the win

Armed with the collection of datapoints (running averages, rate of change, etc.) for each of the pot’s states, I moved on to figuring out how to notify our department’s group chat room when a pot was brewing, ready, empty, or stale. This is where some of the built-in features of Clojure came in handy.

I already had a program that logged the current state of itself every second. By switching the actual state to an agent, I could apply watchers to it. These watchers get called whenever the agent changes, which is perfect for analyzing changes in state.

Another agent added was the pot itself. The watcher for the temperature would look for the above mentioned boundaries, and update the pot’s state, leaving another watcher to track the pot and notify our chat room. When it came time to pick an alias to deliver the notifications, Dave Grohl was the natural choice.

Here’s a simple example of the pot watcher looking for a brewing pot:

(def pot-status
  (agent {:status "empty"}))

(defn pot-watcher [watcher status old_status new_status]
  (if (= (:status new_status) "brewing")
    (notify/is_brewing)))

(add-watch pot-status :pot-watcher pot-watcher)

The great thing is the watcher only gets called when the status changes, not on each tick of the temperature. Using agents felt great to me in this case as they provided a clean way to watch state (without callbacks or a ton of boilerplate) and maintain separation of concern between different parts of the program.

hipchat1

Freshness into the future

I’m still working out a few kinks, tuning in the bounds, and keeping a log of pots. It’s been a fun experience and I learned a ton. Something tells me this won’t be the last time we work with Raspberry Pi on a project. What’s next, Fresh Pots in space? Luckily, we’ve got plenty of coffee to propel us.

tumblr_n9kwt5IBUt1ri8rtfo1_1280

Ben: Thanks to Steven and MailChimp for permission to use the post – we’re very pleased to see the Pi used as the tool of choice of coffee-hungry developers around the world! Coffee is important to us here at Pi Towers…

Trojan Room Coffee Pot

Blast from the past – remember this coffee pot? Click to read more

MailChimp is what I use to power Pi Weekly – my weekly Raspberry Pi news & projects email newsletter – check it out at piweekly.net!

New Raspbian and NOOBS releases

via Raspberry Pi

If you head over to the downloads page, you’ll find new versions of our Raspbian image and NOOBS installer. Alongside the usual firmware and kernel improvements, major changes to the Raspbian image include:

  • Java updated to JDK 8
  • Mathematica updated to version 10
  • Sonic Pi updated to version 2
  • Minecraft Pi pre-installed

Following its release last week, of our port of Epiphany has replaced Midori as the default browser, bringing with it hardware-accelerated video support and better standards compliance.

Epiphany is now the default browser

Epiphany is now the default browser

Our Raspbian image now includes driver support for the BCM43143 802.11n WiFi chip. Last week Broadcom released a rather neat USB hub and WiFi adapter combo based on this chip, which should now work out of the box. More info is available here.

BCM43143 802.11n wireless dongle

BCM43143 802.11n USB hub and WiFi adapter

Finally, to free up SD card space, the offline NOOBS package now only contains the Raspbian archive. To install Arch, Pidora, OpenELEC, RaspBMC or RISC OS you will require a network connection.

Sound Camera.

via coolarduino

 

device-2014-09-11-120157 device-2014-09-11-120328 device-2014-09-12-000047 edited

 

One more project, that shows breathtaking beauty of the FFT (Fast Fourier Transform). Once again, like in last 3D Ultrasonic Radar Project,    Arduino DUE was nominated to be Maestro, doing major part of the Digital Signal Processing in real time.  As you can see below, the hardware includes 4 “modules”:

  1. Sensor board
  2. Arduino DUE
  3. Bluetooth shield
  4. Android tablet.

Last two items aren’t strictly necessary. Alternative would be to connect TFT display directly to arduino, but I decided not to spend my time on re-inventing drawing-rendering software. Better to delegate all visualization stuff to the equipment that was  specifically design by big monsters in high tech industry.  I spend quite time digging into android graphics subject anyway, only hoping I can apply my knowledge somewhere else later on.

Sound_Camera

Sensor board holds 4 microphones from  SFE.  Plus a few decoupling components, capacitors and inductor in power line.

Software.

   Brief summary: Arduino sampling 4 analog inputs, close to 41 kHz,  x 4 = 164 ksps,  software library Radix4 posted on this blog was imported into project practically intact. DMA feature on Arduino DUE allows sampling rate up to 1 MSPS, and I already successfully tested its capability in 3D Radar project.  Having 2048 fft size, at the first processing stage  output there are 1024 bins 20 Hz each. Than, using arctangent LUT, phase of each bin is extracted.  Difference in phases two vertically position microphones gives Y component, and two horizontally spaced mic’s – X component. Sound source is localized with accuracy ~ 0.5 degree. Have to say, that on the lower frequency end, 100 Hz – 1 kHz , where wavelength is huge compare to spacing between two mic’s ( 3.4 meters at 100 Hz ), accuracy is deteriorating proportionally to wavelength.

Arduino is calculating data really fast, providing  X,  Y, and M  every 50 milliseconds. M – is for magnitude. Than, all this data stream flows to android over BT.  Everything else is obvious, watch the video.

Speaker outputs white noise, as for single tone (frequency) only one pixel would be visible on screen. Android software “colorized” picture based on a frequency, low range – starting from red, and up to violet on high end of the frequency band, through all 1024 color wheel possibilities.  You can see, that picture saturated with green and blue, and there is almost no red color. There are two things, first is a speaker, not performing well at low end. Second nuance is the fact, that low frequencies are not “grouped” so effectively, due to the localization error, what I tried to explain in a paragraph above. I created an option in the menu to select different types of colorization, based on a frequency or based on a magnitude. They are look pretty similar for white noise source, so there is only one video clip.

Have fun.


Let’s get Physical! New physical computing animation

via Raspberry Pi

With the success of the first two productions from Saladhouse, our animator friends in Manchester (What is a Raspberry Pi? and Setting up your Raspberry Pi), we proceeded to make plans for a third in the series. The topic we chose to cover this time is one which demonstrates the additional power of the Pi in learning – an introduction to the realm of physical computing.

Look through the amazing projects in our blog, the MagPi or Pi Weekly and you’ll see many of them use the portability of the small form factor and low powered nature of the Pi along with the extensibility the GPIO pins give you – not to mention the wealth of community produced add-on boards available making it all much easier.

B+ gpio closeup

Those pins sticking out there. General Purpose Input/Output. Did we mention there are 40 on the B+?

Here at Pi Towers we all love physical projects – from robotics and home automation to flatulence alarms and scaring the elderly – and we believe they’re a great way to introduce young people to coding, computational thinking, product development and understanding systems.

The video refers to some resources for projects you can make yourself. We featured the hamster disco on our blog in July, and you may have heard talk of some of the others on twitter – which are all brand new, constructed and tested by our education team. They are:

hamster-party-cam grandpa-scarer fart-detector robo-butler

See more in our resources section.

Huge thanks to Sam and Scott from Saladhouse for their hard work on this – and also to our voice actors Arthur (son of Pi co-founder Pete Lomas) and Maia! And yes, that’s Eben narrating.

IMG_0908 IMG_0910 IMG_0918 2014-07-04 20.01.22
A little gift I brought Dave back from Memphis...

A little gift I brought Dave back from Memphis…

The Raspberry Pi Guy Interviews Clive & Gordon

via Raspberry Pi

Last month we put out a call for questions for our education and engineering teams. Matt Timmons-Brown, aka The Raspberry Pi Guywas given the chance to interview Clive Beale who heads up our education team; and Gordon Hollingworth who heads up software engineering.

We hope you find that fills a few gaps and enjoyed hearing from us at Pi Towers. Thanks to Matt for filming and a great job editing.