Showing posts with label puppets. Show all posts
Showing posts with label puppets. Show all posts

Tuesday, 6 November 2012

What is @twitr_janus - A summary overview, November 2012 for MCN attendees

This post is an updated summary of what @twitr_janus is, and what it demonstrates

This is mainly aimed at attendees at the Museums Computer Network conference, Seattle, 2012, especially the Slack Day hacking workshop, where this cutey will be being demonstrated live. (if I can put it back together again)

Firstly, here is @twitr_janus in cabin baggage ready to be checked in as hand luggage. I am not sure it will be allowed on board the aircraft...
@twitr_janus skull

What is @twitr_janus?

DSCN2094

@twitr_janus is a live physical avatar - a puppet that can be controlled remotely over the Internet using the data sources of common web services like Google Drive and Twitter and direct web-enabled services such as Skype. It is a (very) crude alpha prototype that demonstrates several simple ways to remotely interact physically using web data services or piggybacking the connectivity of audio/visual web services.

Its real point though, is to demonstrate how real-time sensory interaction can be achieved by hacking together feeds, APIs or just features of common freebie web services. It can see you, hear you, talk to you and move its eyes to watch you. That's not creepy at all.



How does this work?

@Twitr_janus electronics To control @twitr_janus, data is sent to it over the Internet using free web tools that have interactive elements. These include sending a tweet in a specific Twitter account and creating custom forms that piggyback the form processing script of a Google spreadsheet, but many other web services could be used.

At the other end of the web, the structured data is retrieved so it can be manipulated. This is done using the open source Processing language running on a connected computer. Processing can parse (strip out selective data) from open RSS feeds and/or APIs.

The data is then converted into physical action. An open source text-to-speech library for Processing is used to generate speech from text data. It can speak either tweets from its Twitter account, or from the contents of a field in a Google spreadsheet.
@twitr_janus uses the open source hardware platform Arduino to convert other data to physical motion. Eye control is achieved by an Arduino sketch loaded on the board, which reacts to data parsed from feeds from a Google spreadsheet. This signal data controls the position of two servos that direct the focus of its stare.

Its jaw is lip-synched to speech output by converting the analogue audio signal levels into a control signal for a car-door lock actuator motor. An audio amplifer is used to create asignal large enough to detect, and the Arduino sketch triggers a relay power circuit for the actuator based on signal peaks. It also has LEDs to indicate the last source of its control data.

Finally it can see and hear via a webcam. It does this using web video software Skype. This can be remotely activated using the correct settings in Skype

WTF?

Burnt out servoThe important point is simply that almost any modern web service will use, or often be built upon, a data publishing model. Because these web services have built-in data publishing features, such as APIs (application programming interface) or feeds such as RSS, they convert the human input tools into predictable data output that can be manipulated. None of this requires you to set up any infrastructure.


This principle can be used to hack new things together. It's all very enjoyably Frankenstein. @twitr_janus is just a specimen beast, created to illustrate this with a physical example. It simply demonstrates some possibilities beyond obvious web front end stuff, of hacking data from current open source or freely available web services, to create physical interaction.

It's crude, often breaks and has cost the lives of two Arduino boards, at least five servos and one vintage glue gun (RIP), but it does show how web data doesn't have to be just on-screen.

Other things that could be quickly prototyped using this method can easily be imagined such as:
  • Tweetometer for marketing campaigns. Use Twitter data about your campaign tags to make a physical thermometer go up and down to indicate success. (e.g. Trend ranking, number of retweets, etc.)
  • Animatronic avatar interaction to query collections or events databases. If data can be extracted, it can be spoken
  • Physical puppet automatically announces new events as they appear in the api of your events database
  • etc. etc.




Free code and stuff...

Twitr Janus tweet retrieving script in Processing(with apologies to my professional developer colleagues for the state of this hackery!)
The basic (and very rough) code is available for forking/hacking/recycling as you see fit. Note, this will be only the last working version:
Processing control sketch (version 15)
(polls web feeds from Google and Twitter to extract data)
Github code download
PDF version
Arduino sketch (used to manipulate data and/or analogue signals into physical actions)
Github code download
PDF version

There are detailed posts about the specific physical build of @twitr_janus in the archive if this blog. Physical build notes crop up in back posts here on makingweirdstuff (interspersed with other nonsense) 
E.g. Posts about building eyeballs

Monday, 20 August 2012

Twitr_janus head designs

I can't decide quite what the vibe should be for Twitr_janus.  It should be slightly unsettling or distrubing, but not too evil. More like just a tiny bit weird, than downright scary...
Twitr_janus head designs

Twitr_janus head designs
Twitr_janus head designs

Twitr_janus head designs

Friday, 17 August 2012

Pimping a Google spreadsheet form, to create a bespoke control form with sliders

Link here to download complete Processing sketch on Github

This expands on the previous post, which explained how to use the RSS feed from a published spreadsheet to extract remote control data from that feed and use it in a Processing sketch.

Here this idea is extended to use a Google form, instead of typing into the sheet. This has the advantage that all the values to be sent can be prepared at once, then the form submitted.  It is still a bit clunky, but it does imporve it slightly. A mthod of controlling the inputs to submit data between fixed upper and lower values for both horizontal and vertical position variables is described below.

The Google spreadsheet showing form data and control data based on the last form entry

Twitr_janus Google spreadsheet


The values in the fields F2, G2 and H2 are the data that will be used remotely by the sketch.  The data in these fields are being constructed from the control character ¬ in E2, and the last instance of a form return from columns B (representing up/down eyeball data), C (representing left/right eyeball data) and D (speech text) for the Twitr_janus puppet.

The Google expression in cell F2 to return the last NUMERIC value of column B is...

=trim(E2&(FILTER( B2:B ; ROW(B2:B)=MAX(FILTER( ROW(B2:B) ; ISNUMBER(B2:B))))))

The Google expression in cell G2 to return the last NUMERIC value of column C is
=trim(E2&FILTER( C2:C ; ROW(C2:C)=MAX(FILTER( ROW(C2:C) ; ISNUMBER(C2:C)))))

and the Google expression in cell H2 that returns the last TEXT value of column D is
=trim(E2&FILTER( D2:D ; ROW(D2:D)=MAX(FILTER( ROW(D2:D) ; ISTEXT(D2:D)))))


The puppet is not yet built, so a surrogate virtual face is being used to react to the data. It is rather basic...

Twitr_janus' virtual face
The standard form for the spreadsheet was set up as usual and has text boxes. This is  slightly better than direct typing into the sheet, in that the 3 values can be sent in one go. However, it requires the user to have to know the values needed to make the eyeballs move and allows any value to be submitted, which will cause problems.

To get round this, the source code of the form needed to be adjusted. It looked like this:

Source code for standard Google form
















The post method used here will only work if you are logged in as an editor of the sheet, but if you are logged in the form code can be used on any webpage. This means you can copy it and hack it, then embed on your page.

Source code for the pimped Google form



Original dull ole' Google form
Twitr_janus
Beautiful pimped form with
range limited sliders - nice!
The main thing to note here was the adjustments to the input controls for the two eyeball data fields.
The original input has the attribute type="text". This is shown on the left astext boxes.

The pimped version on the right (from an iPad screen) uses the attribute type ="range".

Range is an HTML5 feature that displays a slider.

It also allows for min and max attributes to be set, which limit the data entry to between those two values. Just what was needed!

ta-da!



Tuesday, 18 May 2010

More cobbling

Some fine footwear for an otherwise austere scientist

Thursday, 13 May 2010

trousers


After some efforts in tailoring, trousers are nearly completed

Monday, 10 May 2010

Puppet boots


The beginnings of some rather dandy boots for Mr Punch.

Stages 1 and 2 are modelling the positive core in plasticine, followed by laminating with brown paper and PVA papier mache

Sunday, 9 May 2010

Swish shirt


Why, hello. Who's got a dandy new tailored shirt then?

Friday, 2 April 2010

Scientist's lab coat

I am not sure if this is a tiny tad too long, but has the right feel for the character. Stereotypical science geek attire, but with a slightly military/ secret police feel to the collar.

Monday, 22 March 2010

Policeman is nearly complete


'ello, 'ello, 'ello. What's all this then? 'bout bleedin' time I 'ad some clothes, matey...

Friday, 19 March 2010

shoes...

Plasticene and papier mache. I love it!
pink thing is the mould - brown thing, the shoe... policeman's shoes...

Tuesday, 9 March 2010

Policeman gets clothes


Jumble sale jeans are perfect for making a good navy uniform.
This is not yet fitted with trims or buttons, but starting to show the final look.

Tuesday, 2 March 2010

Puppet bodies getting better

This shows the Policeman puppet. The head sits freely in a central hole and is held and, in use, is manipulated by the last three fingers of the hand curled round it.
The hands are detached from the body to allow maximum freedom od movement.

The body is connected to the sleeve with a short stitched hinge joint.

Thursday, 4 February 2010

Crocodile head

Crocodile with elastic jaw opening. This opposes the cable controlled jaw snap shut.
I wonder if elastic to close jaw would be better. Possibly more relaxing to use in practise, as most of the time not tension would be required in the hand to keep the jaw shut.
hmm...

Saturday, 30 January 2010

Mr Punch gets new clothes

My, doesn't he look dashing. I liked the last costume, but this one is more theatrical. The shadows work rather tastily here!

I can't decide if he should have a hat. Does anyone out there reading this have any opinion on if it would improve the look?

Saturday, 23 January 2010

Another puppet body pattern

Policeman.

This design is a 2-finger control, with the head on a stick in the remaining curled three fingers. This is better than the fixed head version. It can shake its head in despair etc.!

Sunday, 17 January 2010

Hands getting attached

Here is Judy's right hand being glued into place into her arm sleeve.

The hand is modelled and baked Fimo, painted and varnished, with a thin bamboo rod inserted as a mount to keep the arm rigid. This is hot-glued into the fabric arm. The fabric of the arm is reinforced by surrounding with thin plastic from a soft drink bottle to form a rigid, hollow tapering tube which will allow thumb operation.

Saturday, 16 January 2010

First body made from latest pattern...

This will most likely be Judy. The body is full of flocked (i.e. quite fluffy) cotton cloth, cut up and stuffed inside. There are a few coins in each foot to give them some swing. Four pence in each to be exact!

Wednesday, 13 January 2010

Body parts

Two-part body made from templates. Part one is the white body with no arms. Part two is the puppeteer sleeve in black with arms in white attached as sleeves to allow thumb and forefinger through. These are combined to create a puppet operated from behind.