Tanglebots workshop preparation

It’s workshop time again at Foam Kernow. We’re running a Sonic Kayak development open hacklab with Kaffe Matthews (more on this soon) and a series of tanglebots workshops which will be the finale to the weavingcodes project.

Instead of using my cobbled together homemade interface board, we’re using the pimoroni explorer hat (pro). This comes with some nice features, especially a built in breadboard but also 8 touch buttons, 4 LEDs and two motor drivers. The only downside is that it uses the same power source as the Pi for the motors, so you need to be a little careful as it can reset the Pi if the power draw is too great.

2hat

We have a good stock of recycled e-waste robotic toys we’re going to be using to build with (along with some secondhand lego mindstorms):

toys

Also lots of recycled building material from the amazing Cornwall Scrap Store.

material

In order to keep the workshop balanced between programming and building, and fun for all age groups, we want to use Scratch – rather than getting bogged down with python or similar. In a big improvement to previous versions of the Pi OS, the recent raspbian version (jessie) supports lots of extension hardware including the explorer hat. Things like firing the built in LEDs work ‘out of the box’ like this:

2scratch-led

While the two motor controllers (with speed control!) work like this:

2scratch-motor

The touch buttons were a bit harder to get working as they are not supported by default, so I had to write a scratch driver to do this which you can find here. Once the driver script is running (which launches automatically from the desktop icon), it communicates to scratch over the network and registers the 8 touch buttons as sensors. This means they can be accessed in scratch like so:

2scratch-touch

Teaching at the Düsseldorf Institute for Music and Media

Last week I was kindly invited by Julian Rohrhuber to do a couple of talks and teach a livecoding workshop alongside Jan-Kees van Kampen at the Düsseldorf Institute for Music and Media. Jan-Kees was demoing /mode +v noise a Supercollider chat bot installation using IRC, so it was the perfect opportunity to play test the work-in-progress slubworld project, including the plutonian botzlang language. It also proved a good chance to try using a Raspberry Pi as a LAN game server.

IMG_20130620_163002

There wasn’t enough time to get deeply into botzlang, but we were able to test the text to sound code that Alex has been working on with a good sound system, and the projection of the game world that visualises what is happening based on the Naked on Pluto library installation:

world5

The Raspberry Pi was useful as a dedicated server I could set up beforehand and easily plug into the institutes wireless router. We didn’t need to worry about internet connectivity, and everyone could take part by using a browser pointed at the right IP address. With access to the “superuser” commands from the Naked on Pluto game, the participants had quite a bit of fun making objects and dressing each other up in different items, later making and programming their own bots to say things that were sonified through the speakers.

A fluxus workshop plan

I’ve been getting some emails asking for course notes for fluxus workshops, I don’t really have anything as structured as that but I thought it would be good to document something here. I usually pretty much follow the first part of the fluxus manual pretty closely, trying to flip between visually playful parts and programming concepts. I’ve taught this to teenagers, unemployed people, masters students, professors and artists – it’s very much aimed at first time programmers. I’m also less interested in churning out fluxus users, and more motivated by using it as an introduction to algorithms and programming in general. Generally it’s good to start with an introduction to livecoding, where fluxus comes from, who uses it and what for. I’ve also started discussing the political implications of software and algorithmic literacy too.

So first things first, an introduction to a few key bindings (ctrl-f fullscreen/ctrl-w windowed), then in the console:

  1. Scheme as calculator – parentheses and nesting simple expressions.
  2. Naming values with define.
  3. Naming processes with define to make procedures.

Time to make some graphics, so switch to a workspace with ctrl-1:

  1. A new procedure to draw a cube.
  2. Calling this every frame.
  3. Mouse camera controls, move around the cube.
  4. Different built in shapes, drawing a sphere, cylinder, torus.

Then dive into changing the graphics state, so:

  1. Colours.
  2. Transforms.
  3. Textures.
  4. Multiple objects, graphics state persistent like changing a “pen colour”.
  5. Transform state is applicative (scale multiplies etc).

Then tackle recursion, in order to reduce the size of the code, and make much more complex objects possible.

  1. A row of cubes.
  2. Make it bend with small rotation.
  3. Animation with (time).

At this point they know enough to be able play with what they’ve learnt for a while, making procedural patterns and animated shapes.

After this it’s quite easy to explain how to add another call to create tree recursion, and scope state using (with-state) and it all goes fractal crazy.

This is generally enough for a 2 hour taster workshop. If there is more time, then I go into the scene graph and explain how primitives are built from points, faces and show how texture coords work etc. Also the physics system is great to show as it’s simple to get very different kinds of results.

Fluxus workshop in Falmouth

After rushing around Europe doing a lot of livecoding over the last week (more on that soon) I’m really pleased to announce this workshop closer to home in Falmouth:

CLAN and CREATIVE SKILLS present: CREATIVE CODING taster session for ABSOLUTE BEGINNERS with Dave Griffiths

Friday May 31st 10.30am – 12.30pm
AIR building, Falmouth University, Tremough Campus TR10 9EZ
Places: For 10 people only

Deposit: There are limited places so you will need to pay a £15 deposit to secure your place when you book, which will be refunded before the workshop. If you don’t turn up you lose your deposit. To book: Please email: admin@creativeskills.org.uk

In this workshop for beginners with award winning game designer, creative coder and live coding artist Dave Griffiths you will find out about the emerging art form of live coding and learn how to write simple programmes to create animations in 3D space. You will be introduced to fluxus, an open source game engine for live coding worlds into existence, used by artists, performers and digital practitioners for installations, VJing, games and education.

What will you do? What will you achieve?

You will create 3D animated forms, and have an introduction to fundamental programming concepts, naming of values and processes, recursion and digital representation of colour, 3D shape and texture.

There will be coffees and teas.

At 1pm Dave will talk at a free event-

CLAN – Cornwall Locative/ Interactive Arts Network

1-2pm AIR Sandpit

Speakers: creative coder Dave Griffiths is joined by digital archaeologist Tom Goskar.

Re-interpreting history

A script for sniffing bits of supercollider code being broadcast as livecoding history over a network and re-interpreting them as objects in fluxus, written during an excellent workshop by Alberto de Campo and Julian Rohrhuber at /*VIVO*/ Mexico City.

(osc-source "57120")

(define (stringle str)
    (map
        char->integer
        (string->list str)))


;;(osc-destination "osc.udp:255.255.255.255:57120")
;;(osc-send "/vivo" "s" '("fluxus:hola"))

(define (safe l n)
    (list-ref l (modulo n (length l))))

(define (render arg)
    (let ((l (map (lambda (t) (/ t 255)) (stringle arg))))
        (with-state
            (scale (vector (safe l 0)
                    (safe l 1)
                    (safe l 2)))
            (rotate (vmul (vector (safe l 32)
                    (safe l 12)
                    (safe l 30)) 360))
            (colour (vector (safe l 0)
                    (safe l 3)
                    (safe l 4)))

            (build-torus 0.1 1 4 20))))

(clear)
(scale 2)
;;(render "hello 343 323")

(every-frame 
    (begin
        (when (osc-msg "/hist")
            (printf "~a~n" (osc 1))
            (when (osc 1)
                (render (osc 1))))))

/* vivo */ musings

So much to think about after the /* vivo */ festival, how livecoding is moving on, becoming more self critical as well as gender balanced. The first signs of this was the focus of the festival being almost entirely philosophical rather than technical. Previous meetings of this nature have involved a fair dose of tech minutiae – here these things hardly entered the conversations.

Show us your screens

One of the significant topics for discussions was put under the spotlight by Iohannes Zmölnig – who are the livecoding audience, what do they expect and how far do we need to go in order to be understood by them? Do we consider the act of code projection as a spectacle (as in VJing) or is it – as Alex McLean asserts – more about authenticity, showing people what you are doing, what you are interacting with, and an honest invitation? Julian Rohrhuber and Alberto De Campo discussed how livecoding impacts on our school education conditioning, audiences thinking they are expected to understand what is projected in a particular didactic, limited manner (code projection as blackboard). Livecoding could be used to explore creative ways of compounding these expectations to invite changes to the many anti-intellectual biases in our society.

Luis Navarro Del Angel presented another important way of thinking about the potential of livecoding – as a new kind of mass creativity and participation, providing artistic methods to wider groups than can be achieved by traditional means. This is quite close to my own experience with livecoding music, and yet I’m much more used to thinking about what programming offers those who are already artists in some form, and familiar with other material. Luis’s approach was more focused on livecoding’s potential for people who haven’t found a form of expression, and making new languages aimed at this user group.

After some introductory workshops the later ones followed this philosophical thread by considering livecoding approaches rather than tools. Alex and I provided a kind of slub workshop, with examples of the small experimental languages we’ve made like texture, scheme bricks and lazybots, encouraging participants to consider how their ideal personal creative programming language would work. This provides interesting possibilities and I think, a more promising direction than convergence on one or two monolithic systems.

This festival was also a reminder of the importance of free software, it’s role to provide opportunities in places where for whatever reasons education has not provided the tools to work with software. Access to source code, and in the particular case of livecoding, it’s celebration and use as material, breeds independence, and helps in the formation of groups such as the scene in Mexico City.

Baltan Laboratories FaceSponge workshop

This is a very late report on a workshop on Facebook livecoding/hacking we gave at Baltan Laboratories in Eindhoven in May. We were invited us to run a workshop based on Naked on Pluto as part of their Tools Series:

The Tools Series is a series of Baltan Sessions that examines the complex and changing relationships artists and designers have with the technologies and tools they develop, modify or use to create, with an aim to explore social awareness around the tool choices they make as well as the (aesthetic) influences of these choices on the work they create.

During the Naked on Pluto project one of the key ways to confront the problems of centralised social networks turned out to be to encourage a deeper understanding of the processes and protocols of these sites.

So, like the previous workshop at CCCB, we centred this around a web application called FaceSponge, which we developed as a social programming interface giving quick access to the Facebook API and allowing participants to try out each other’s scripts. The other key issue was to find out people’s opinions, and so we collected answers on post-it’s to three questions for each area, which the participants later sorted for presentation to the public.

Social advertising

This workshop was perfectly timed with Facebook’s IPO, and as 82% of it’s revenue comes from advertising we started off by working on a simple spoof advert. We took one friend, and picked something they have ‘liked’ and wrote some code to promote it. This is what happens on social networks where a brand gets advertised to you because one of your friends follows or likes it. Being able to put a friend’s name in an advert is seen as an exciting future of advertising (or perhaps less so as the share price continues to drop).

function runme() {
    FB.api("/me/friends", function(friends) {
        var friend=friends.data[0];
        FB.api("/"+friend.id+"/likes", function(likes) {
            var like=likes.data[0];
            display(friend.name+" endorses "+like.name+" BUY SEVERAL TODAY!");
            FB.api("/"+like.id+"/picture?type=large", function(picture) {
                display_image(picture);
            });
        });
    });
}

Privacy

There are vast amounts of pictures available on facebook, and it was fun to write a script that presented them all back at in a chaotic manner without any other information. This also gave us a chance to show how the privacy on Facebook is imaginary, as the URL’s FB gives you for your friend’s pictures are public – regardless of anyone’s privacy settings.

// showing the holes in the walls                                               
// you think your photos are private?                                           
// these images are accessible without a login                                  
function runme() {
    FB.api('/me/friends', function(friends) {
        friends.data.forEach(function(friend) {
            FB.api('/'+friend.id+'/photos', function(f) {
                 if (f.data.length>0) {
                     var gallery=f.data[0];
                     // show the public url                                     
                     display(gallery.images[0].source);
                     // show the image                                          
                     display_image(gallery.images[0].source);
                 }
            });
        });
    });
}

Social pressures

The third area we were interested in exploring was the more subtle ways that social media are affecting communication methods. We came up with this strange script that collects the last things posted by your friends and puts them together without information on who posted them, or who they are for:

function runme() {
    FB.api('/me/friends', function(friends) {
        friends.data.forEach(function(friend) {
            FB.api('/'+friend.id+'/feed', function(feed) {
                if (feed.data && feed.data.length>0
                    && feed.data[0].message) {
                    display(feed.data[0].message);
                }
            });
        });
    });
}

We continued to play with and adapt these scripts in order to show more information. The mood was interesting as it flipped from serious to hilarity and then slight awkwardness at what we were dredging up. We followed each of these practical sessions by collecting feedback on thoughts and emotions for each section. Although this was a very demanding workshop (changing between coding, politics, funny juxtapositions of friend’s personal data and having to think about how it felt) we recorded a wide range of thoughts – from the dismissive, “doesn’t matter” to the outright enraged. Perhaps one of the most important aspects of this workshop was being able to expose these mechanisms to groups of people normally considered ‘users’.

Live notation at the Arnolfini

I was honoured to take part in the live notation unit’s event at the Arnolfini on Friday, and to perform with Alex McLean and Hester Reeve in the evening.

Live notation is a project exploring connections between Live Art and Live Coding, both art forms revolving around performance, but with very different cultures and backgrounds.

The day started with workshops. The first one by Yuen Fong Ling played with the power structures inherent in Life Drawing. We tried breaking some conventions, instead of everyone drawing the same model – one scenario involved arranging the easels in a line where one person drew the model and everyone else copied the previous person in line. This ‘drawing machine’ resulted in an intriguing pictorial version of “Chinese whispers”. The second workshop involved programming choreography live via drawing and an overhead projector, firstly with workshop leader Kate Sicchio as the dancer, and then more and more livecoders joining in until the roles were reversed.

The performances consisted of a mix of live art and livecoding, and also served to demonstrate the breadth of approaches that these art forms represent – Wrongheaded performed a spectacular livecoding invasion of religious ritual, while Kate Sicchio followed beautiful instructions she’d received a couple of hours before interpreting Nicholas Poussin’s painting ‘The Triumph of David’ using brightly coloured silks. Thor Magnusson unleashed a sub bass rumbling agent driven visual approach to livecoding with a very considered minimal performance. As an audience member, I think livecoding needs a dose of cross fertilisation with related areas, especially if they are outside of the computer music sphere – we can think more about our roles, the situation and less about the mechanics. As a performer, I’m still processing (and waiting for photos) and will write a bit more on our performance in a few days.

Next week: Plant spirit drawing & social network livecoding

The next few days are going to be hectic – a train powered scramble between cities for various activities.

Firstly I’m taking part in FoAM’s Open House event on Saturday in Brussels:

Enter a rarity cabinet of people and experiments: a lively display of human-plant hybrids, tasty table conversations, crisis-proof clothing and other curios in their natural habitat – the FoAM lab. Expect to experience a colourful collection of sketches and prototypes in various stages of completion, providing an insight into the collaborative and creative processes developed at FoAM.

My part is going to involve various experiments with Germination X, some playtesting and getting more feedback so I can evaluate the mandrake avatar changes. I’ve also rebuilt the code for “draw your own plant spirit” – this time we can directly upload people’s drawings to the public server for testing their spirit designs in the game.

The second event I’m taking part in is Baltan Laboratories The Tool Series #5: FaceSponge Workshop with Aymeric Mansoux in Eindhoven on Wednesday 23rd. We’ll be examining and exploring our real data on social networks, looking behind the interfaces and protocols we are supposed to see, with a top secret collaborative social network livecoding interface which has emerged from the Naked on Pluto project.