Freitag, 23. November 2012

Programming an ATtiny85


I recently decided that I wanted to use an ATtiny85 for a small project I have in mind. So I ordered a couple from DigiKey. Once I got them I realized that I only had a very vague Idea on how to go about programming them. 
I ended up following instruction from the brilliant people of the High-Low Tech group at MIT: http://hlt.media.mit.edu/?p=1695 

Some things I noticed:
- Their instructions do *not* work with Arduino 1.0.2.
- Dont forget to select the correct board *and* the correct programmer (selecting a programmer was new to me, its in the "tools" menu)
- Yes, the Capacitor is essential. I didn't have 10uF capacitor around the first time I tried it. I tried various wrok-arounds (multiple capacitors in paralel, larger values, smaller values) and nothing worked. (In retrospect, at one point I did get it to work without the suggested capacitor, however there was a different problem, but I was unable to fix it, as I assumed it was the cap. So my recommendation: Just get the capacitor and it'll save you trouble.

Also, use the suggested debugging LEDs. It makes it a lot easyer to understand what is happening.

Here is my setup:


Green LED tells me the ATmega is talking to the ATtiny:


Once I finally got it running I basically fell in love. This thing is sooo simple. It works like magic. No external oscillator, no nothing. It just works. I think in many situations, once you have the initial setup its easier to use than the Arduino. I realized I will want to program ATtinies more often, so I decided to make myself an ATtiny programming shield:


I used a protoshield which I piked up from the METALAB at some point and had lying around. I connected everything like so: 



In addition I added a yellow LED + Resistor on pin 9 (Heartbeat - tells me the programmer is working OK). I also added a red LED on pin 8 (Error) and a green one on pin 7 (communication). The small green LED you see next to the ATtiny is for double-checking if everythng works. Its connected to pin 0 of the ATtiny and is executing the 'blink' sketch which I just uploaded to the ATtiny.


Sorry about the shoddy fotography. If I find a decent camera I might upload some nicer images.

This was a fun project and well worth the time :-)


Donnerstag, 1. November 2012

Kickstarter - A recap of my campaign


I recently successfully funded a project of mine via Kickstarter (link: http://www.kickstarter.com/projects/808216251/mediated-touch-a-telepresence-study). People have been curios about how the process went, so I decided to quickly recapitulate my experience. 

First of all, there is lots of stuff on how to run a Kickstarter campagin and stats about Kickstarter out there. I personally found this website the most helpfull while running the campaign: http://www.kicktraq.com/


So lets take a look at my project:

How did it go?




I marked some interesting points on this graph. 
(1) Begin. This was awesome. I basically clicked submit on the Kickstarter page - just because I was curious *if* it would work. And it did. Then I thought "I should send out an e-mail to people, telling them about this". By the time I had finished that thought, I already had my first backer, a former lab-mate. I ended up opting for not spamming my entire e-mail contacts, but selected a few ~ 20 people who I sent a message to, asking them to forward it to people who might be interested. 

Within the first day, I was backed with over 400$, of which 65$ where from people I knew - the rest where strangers to me. This was quite a thrilling experience. I could not really understand it - it was only later that I realized Kickstarter had selected my project as a staff pick:

During the next couple of days, my project was plastered all over (my corner of) Facebook by me, friends, people I study with and, to my surprise, the odd person who was a stranger to me. Also, people continued backing, and very soon, I hit my goal of 950$

After that things started stagnating a bit. Then something even worse happened. I lost money. I was not even aware this could happen. What I learned is, you must not only convince people to back you, you must continously keep them convinced. Loosing backing was quite a blow to my moral. However, I guess its just one of those things which happen and should not be taken too seriously. I never found out why the two people who 'backed out' backed out.

Things changed half way (2). This was a strange day. I don't know if this is random, or if this is significant. It might also explain day one. What happened is this: My Grandmother, Mother and Aunt decided to back my project with 300$. (It was done from one account, so they do not appear as individual backers). Then all of a sudden, 3 more people backed it, with substantial amounts of money. Quite a day, I was really hyper.

However, as with day one, one of the backers rescinded their backing.

I really did not do much in form of marketing. Towards the end of my project (4) I sent a fb message to a couple of friends who I knew would most likely be happy to back my project, asking them to do so, and telling them not to worry about adding a large sum, I really am just interested to see if I can get more backers. Most of them backed it. On the last day (and some even within the last hour) a bunch of friends ended up making the effort to back my project (5). I would guess that I know around 30 of the 100+ people who backed my project in person. About half of those backed it in the last two days.

And then, of course as soon as the backing period was over (6), I got a bunch of messages by people apologizing for missing the time-window. I assume, if I had written to these people in person, they probably would have backed the project as well.


 Here some more statistics from Kicktraq

After a big backer backs out, things look sad:



It can be corrected though:



 Entire course of project, including trend at each day:



What did I learn


This is what I did right
- My project is very unique. I think this contributed to it being featured on Kickstarter. Without being featured, things would have been very different.
- My project was appropriate in scale to my network. Luckely things went well and I did not have to take any extreme measured, however, before starting I sort of considered which networks I have (family, university, former work, friends in Canada, friends in Austria, friends in the Netherlands) and estimated how much backing I could potentially get if I reached all of them. The project I intended to do, and the reach I thought I had aligned nicely, so I figured I might be able to do this.
- The presentation. I think people liked my video and the way I had things set up. I think it was professional enough for people to believe that I can pull off my project, while being honest and personal enough that people felt comfortable giving me money even tough my rewards where not the most tangible ones. (a lot more people than I would have anticipated opted for the "no reward" option.

This is what I did poorly
- My funding goal. After I had almost reached my goal of 950$, I realized that I had actually anticipated to overshoot that goal by ~ 600$. However all of a sudden I found it difficult to explain to people why I needed their backing, even though I already had 100%. The backing also stagnated once I had reached 100%. This was a huge mistake. I did this, as I was planning on doing my project anyway, and even the 950$ would have been valuable, however I learned this: Be bold. Ask for as much money as you need. If you don't ask for the right amount in the first place, it is hard to justify this later on
- The rewards. This was probably the weakest point of my project. I did not know how to do them, as, unlike most Kickstarter projects, I am not designing a product and I am *not* interested in distributing and selling things. Because of that I thought that I need not put so much focus on this. Well, I think now that I was wrong. For example, I ended up receiving additional backing from one person after some exchange, in which I asked him what type of reward he actually would like to see. After I introduced that reward, he almost doubled his pledge. I did this on the last day. For me it all worked out - I got what I needed and am happy with my project. Next project, first thing I will work on will be the rewards.


A word of warning:

Kickstarter does not initially mention, that you will pay additional fees on top of the 5% which Kickstarter keeps. When it does it says Amazon keeps between 3% and 5%. 

What it does not mention however is that Amazon does not apply this percentage equally to all transactions. For the 1$ pledges I ended up paying 11 cent to amazon. So from every 1% pledge I get to keep 0.84$. This is quite hefty in my opinion. From 5$ pledges Amazon keeps between 0.30$ and 0.35$. Thats 6% to 7%.

All in all, I ended up receiving 89% of the total amount pledged. That is, in my opinion, a lot of fees. I am happy paying Kickstarter these fees, as I feel like it was extremely beneficial that I could use their platform  however, I am not sure how I feel about the Amazon fees.


Some links:


I found following blogpost to be extremely interesting  especially interesting:  http://boardgamegeek.com/article/8849498#8849498

More interesting discussion can be found here: 


Samstag, 27. Oktober 2012

Some Data Visualization

My friend Johanna asked me to help her figure out how to visualize some data she was working with.

(Maybe I can get her to update this blog with some actual information on the Data. My Estonian is about as good as my Esperanto or my Inuit, so I know what the labels on the data say, but well. Not what they mean)

She gave me a list of buildings of a district of Talinn. Each building had two datapoints: a) it was classified according to some (to me completely mystical) Estonian system and b) the year it was built in. My first thought was to just to give each classification a value and create a scatter plot:


This initially seemed quite useful. You can see which classifications concern newer buildings, which ones concern older buildings. You can see that very few - well actually, no buildings at all where built after 1940 and before 1945. However, I did not feel like one sees the entire picture. So I decided to add some jitter. Once I saw the result, I decided to add a whole lot more jitter. This is the graph I came up with:


Here we can see a whole lot more detail. For example the third, fourth and fifth category from the top looked fairly similar around the year 200 in the first graph. Here we see that there is actually a lot more going on. I still was not quite satisfied, so I considered it a programming challange and tried to see what I could come up with using processing.


I would have never anticipated the huge spike in the first classification just by looking at the chart I had previously made. I'm not quite sure if the mirrored thing is so smart, as it might make the differences between a large and a small number of occurrences appear to be smaller then it is... still, I think its a pretty graph.

Here is (some of) the code I used:
("some of" because estonian seems to break snippler which I use for the code formatting)


Finally, this is what happened, when i did not use pushMatrix() and popMatrix() correctly. I think its quite a beautiful result:




Dienstag, 2. Oktober 2012

How you can help my Kickstarter campaign



Three things you can do:

- If you could publicly back me, by contributing 1$ that would be A-M-A-Z-I-N-G. I know many of you don't have any more extra money to spare than I do, however, this 1$ means a lot. It shows the world that you are publicly supporting me. Not only by sharing a link, but by contributing what (sadly) seems to be the one thing which counts in this world: $$$. Depending on where I go with this project, demonstrating that I have a broad supporter base may be extremely valuable to me.

- Please criticize what I am doing. Please find the flaws in my reasoning, the fallacies of my ideas. I will post them on the kickstarter page in order to start a discussion, to start discourse. I will learn from your criticism and other will learn from it. There is so much valid criticism to what I do... lots of my ideas are very problematic. I want people to point this out so it can be discussed and analyzed. Science is negotiation, our future is negotiation. The more standpoints we find, the richer my project can become.

- Finally, please share what I am doing. If you know somebody who is interested in this type of thing - tell them about my project. 

Prototype for my Kickstarter Campaign

Hi Everyone

as you might or might not know, I recently launched a kickstarter campaign in order to collect funding for my bachelor thesis. 

Check it out: http://www.kickstarter.com/projects/808216251/mediated-touch-a-telepresence-study

The money will go towards the hardware I require for running my experiment. Part of the hardware will be a humanoid robot with 4 DOF. In the following video you can see a rough prototype of the head, which will be the most complex moving part of the robot:


 
(I had to add music, as my flatmates complained that they did not want to be heard talking in the background. I find Estonian makes for beautiful background sounds... but then again - I have no idea what they where saying :-D....)


I built these prototypes with parts I had around the house. The brackets where freebies which I was presented with by John Iovine from Images Scientific Instruments quite some time ago. (Thanks again, btw!...) 

 *
Here are some pictures of the process:
... the servos and the brackets which I used for mounting them. I'm just getting started.


Continuing to assemble things...


The servos did not hold as tight as I wanted them to - in order to give the whole thing some additional strength I cut thin strips of thermoplastic, heated it up and then wrapped it tightly around the joint. I like this way of attaching things as its quite effortless but super, super stable.


 You also see that I used thermoplastic as shims (or washers? don't know that word. hat to google it). The screws I use are so tiny that finding fitting ones is quite a task - this is again, easyer and better.




Chassis is finished, and firmly mounted on two bottles filled with water for stability:

 


Anyway thats it for now. Lets see how this whole Kickstarter thing goes :-)

Samstag, 8. September 2012

Software Sketch for BerrieBase


I threw this together to get a feel of what our software could potentially look like.




This is similar to various data-flow languages (like vvvv, pd and Max/MSP) ...

 In theory I really liked data-flow languages, but I have never found an environment I was comfortable enough with to stick with. My plan with our software is to keep it simpler than the ones I just mentioned, and have the ability to switch over to code view, if you want to do something more complex. Basically I want to be able to generate flow-charts from code and code from flow-charts. I imagine every graphical node to be represented by a function. A newly declared variable would also be a node, and all other variables would be represented by lines.

This will of course require users to stick to a more functional style of programming than the relatively imperative way that is used with Arduino. Which could be a curse or a blessing. I am not sure which one yet.

Mittwoch, 29. August 2012

More Pictures of BerryBase Prototypes

Some more Pictures of our Hardware Prototypes:
The Base:
The shift registers which connect the base with the RaspberryPi

The first Berrie Modules :-)




Montag, 13. August 2012

BerryBase - What we have so far


 The Base



These two PCBs will merge into one. We have them separated now for debugging and as it was easier to design this way. The bottom PCB (the smaller one) connects to the RaspberryPi. The top PCB is stacked on top of that.

The top PCB provides us with connectors for 8 modules. Each module (or Berry) has a couple of digital inputs and outputs connecting to the RaspberryPi (for interrupts etc.) as well as SPI and I2C.



 The GPIOBerry



This is the most basic extension. It gives you 16 programmable logic pins.



 The AnalogBerry



This Berry gives you 8 24bit Analog Inputs. (Yes, 24Bit may be slightly overkill.)



The BrainBerry


We had to do it. Its an Arduino Clone. It is both a I2C Master and Slave, Acts as your standard Arduino, while staying in constant communication with the RaspberryPi. (I want 8 of these modules for programming my Evil Super AI)



The ButtonBerry / FeedbackBerry




We figure we will be using this guy a lot for debugging. It has 8 buttons paired with 8 green status LEDs.

Thats it for now. More to come :-)

p.

BerryBase - How it came about


Since I first heard about the RaspberryPi, I was fascinated by the little computer. Once the final specs however came out, I realized that I did not really know what I would use it for. It seemed under-powered for the computer-vision application I originally had in mind. I considered using it as a microcontroller, but I soon realized that in most cases I would be better off using an Arduino instead.

I soon realized, that adding some basic circuitry might improve the situation. I also wanted to add a case. My idea was, that it would be cool to simply increase the number of I/O pins, as well as add some analog inputs. Additionally I wanted to be able to source significantly more power over the individual pins. I discussed this at length with my friend Michael Harst, but it stayed a simple idea.

First Prototype

I ended up meeting Yann Leretaille, Torben Friehe, Mathias Hemmerle & Alex Hannemann. Together we created the first prototype. It was Yann who also suggested "Everything should be Plug & Play". I thought he was crazy.

Somehow Yann and I however felt our original design restricting. We where especially unhappy with how we where handling the SPI and I2C ports. (Basically we where ignoring them). Eventuelly we started experimenting with ways of extending the SPI and I2C ports. While doing so we realized that we might as well create a modular system - we thought that the design would not be significantly more complex (we where wrong). And all of a sudden Yann's "Plug & Play" Idea no longer seemed crazy, once we restricted the Plug & Play functions to the modules we designed.

Sonntag, 12. August 2012

BerryBase PCBs

I am currently working on extension for the RaspberryPi.

Info will soon go online at www.berrybase.cc I just got this image sent from iteadstudio.

Am super psyched
 

Freitag, 18. Mai 2012

Images of the Mountains of Madness


OK, this post is quite different from the stuff I usually put here, but I was reading  The Mountains of Madness by HP Lovecraft and noticed that there recurring references to ancient ruins and stone formations. I was interested in how these sites where portrayed at the time the book was written. So I googled, and even though I know most of them before, looking at the old pictures somehow felt like I was getting closer to Lovecrafts original vision.

I figured it was well worth sharing...

Images taken from Library of congress website (http://www.loc.gov/index.html),
except the imag of Monument Valley, which is from the library of the University of Utah (http://content.lib.utah.edu/) and the images of Machu Picchu, which are random webfinds. (The first of these presumably from the original 1911 expedition, the latter one of unknown date, but due to the state of the ruins must also predate 1930.)

All images predate the writing of Mountains of Madness

***************************

[…]
As he had said, their edges were crumbled and rounded from untold aeons of savage weathering; but their preternatural solidity and tough material had saved them from obliteration. Many parts, especially those closest to the slopes, seemed identical in substance with the surrounding rock surface. The whole arrangement looked like the ruins of Macchu Picchu in the Andes,

 

 or the primal foundation walls of Kish as dug up by the Oxford Field Museum Expedition in 1929;





 and both Danforth and I obtained that occasional impression of separate Cyclopean blocks which Lake had attributed to his flight-companion Carroll. How to account for such things in this place was frankly beyond me, and I felt queerly humbled as a geologist. Igneous formations often have strange regularities - like the famous Giants’ Causeway in Ireland –




 but this stupendous range, despite Lake’s original suspicion of smoking cones, was above all else nonvolcanic in evident structure.
[…]

V

I think that both of us simultaneously cried out in mixed awe, wonder, terror, and disbelief in our own senses as we finally cleared the pass and saw what lay beyond. Of course, we must have had some natural theory in the back of our heads to steady our faculties for the moment. Probably we thought of such things as the grotesquely weathered stones of the Garden of the Gods in Colorado,



or the fantastically symmetrical wind-carved rocks of the Arizona desert.


Perhaps we even half thought the sight a mirage like that we had seen the morning before on first approaching those mountains of madness. We must have had some such normal notions to fall back upon as our eyes swept that limitless, tempest-scarred plateau and grasped the almost endless labyrinth of colossal, regular, and geometrically eurythmic stone masses which reared their crumbled and pitted crests above a glacial sheet not more than forty or fifty feet deep at its thickest, and in places obviously thinner.

[…]

We also came upon several star-shaped open spaces, evidently public squares, and noted various undulations in the terrain. Where a sharp hill rose, it was generally hollowed out into some sort of rambling-stone edifice; but there were at least two exceptions. Of these latter, one was too badly weathered to disclose what had been on the jutting eminence, while the other still bore a fantastic conical monument carved out of the solid rock and roughly resembling such things as the well-known Snake Tomb …


(here is a really nice photograph which shows it in context: http://eu.art.com/products/p15527056-sa-i3696219/posters.htm?ui=73968881EA724F93957B0D144DC46585)

… in the ancient valley of Petra.



*

Here is a link to the original novel by Lovecraft: http://www.dagonbytes.com/thelibrary/lovecraft/mountainsofmaddness.htm

I also created a .pdf of this post for other reasons, but in case you want it, here is the downlaod:

Music Visualization

This is a couple of months old, but I was playing around with music visualization and here are some of the results. The first two where created using Processing & Ess, the last was done using Processing and Minim.

 First two tracks are by me, last one is by my friend Hoob.

 This one actually is my favorite:


   

Here I like how the drums in the beginning clearly have a different visual response:

   

This one is slightly different in style - which just shows, that that programming tools one works with will influence the final artistic result:

 

Sonntag, 11. März 2012

More Fun with DUL Radio

Using Beads, the DUL processing library, and my own little signal processing class:
(you may want to turn up your speakers a tad when watching this...)

 

 There is something really beautiful about this. Cant wait to create more complex systems :-)

edit: follow this link for setup instructions --> http://fkeel.blogspot.com/2012/03/dul-radio.html

Samstag, 10. März 2012

WristFlicker

Somewhat over a year ago, I set out to build my "ShadowCoat".

Since then I have learned more than I ever thought I would learn about technology, art, innovation, media, AI and human computer interaction. Its been a really wild ride.

So anyway, my "ShadowCoat" never got finished as planned. However, In a downgraded version, I did end up completing my project.

The whole thing turned into WristFlicker. A motioncapture system which measures the movements of the wrist.

With great support of Audrey Girouard I managed to get it published at TEI :-)

So, here, take a look at the final version:



You can download our paper here: http://www.paulstrohmeier.info/WristFlicker.pdf

DUL Radio

(scroll all the way to the bottom for a link to the code)

At TEI2012 met a group of people from Aarhus University, demoing their new little wireless board.

http://www.digitalurbanliving.dk/news/news/dul-radio.php

Its called a DUL Radio and, well... its pretty cool. They where kind enough to give me a sample, and I have been playing around with the processing library they provided. I am also writing a small signal processing library, since I have noticed that there are certain functions I tend to re-use a lot.

Both libraries are used in following video:



*

So what can these things do?
- Up to 4 green sensorBoards can connect to on receiver.

Each sensorBoard has:
- a slot for a coin battery
- One 3 axis accelerometer built in
- Two analog inputs
- One of these inputs can in future be used as a PWM output.

This gives you a total of 4 Accelerometers, 8 Analog Inputs and 4 PWM outputs for your project!

*

Below you can see the receiver board on the left, one sensor board in the middle and an xBee pro module on the right. Note that the xBee pro does not have an accelerometer built in, nor does it come with its own powersource. Oh, and the DUL radio is much easyer to use :-)



 Just comparing their size with an arduino
And a closer look...











(thanks to Johanna Rannula for taking the pictures)
*

So how do you get these to work?


To clarify how simple this is: My biggest problem with getting this set up was, that I did not realize how easy it is. Becouse of this, I tried solving problems which did not exist.

So, for windows 7, 32bit, this is what you do:

a) Install driver


  • - Download it:
http://dl.dropbox.com/u/350755/AT90USBnRF-AT90USB162-usbdevice_cdc_rf-1_0_0-doc.zip
  • - Plug in the receiver
  • - go to Device Manager
  • - find Bootloader & Gateway USB Stick
  • - click Update Driver Software
  • - click Browse My Computer For Driver Software


Its not completely obvious where in that zip it actually is. This is the correct path:
AT90USBnRF-AT90USB162-usbdevice_cdc_rf-1_0_0-doc\...
...AT90USBnRF-AT90USB162-usbdevice_cdc_rf-1_0_0-doc\...
...demo\...
...AT90USBnRF-AT90USB162-usbdevice_cdc_rf\

I also had a wierd issue with my file encryption. When I tried to install the driver, I was told that "Access is Denied". I figured out that it was some wierd encryption issue. If you have that problem as well, you can solve it by:
RightClick on folder / General / Advanced / uncheck "encrypted" and apply to all folders

b) Do something with it

It appears, that the software of choice for interfacing with the DUL radio is Cycling74s Max/MSP/Jitter. If you are like me and graphical programming frustrates you, then you might want to check out their processing library:

http://dl.dropbox.com/u/350755/DULRadio.zip

How to install the library:


  • - Find your Processing Sketchbook
  • - Find or create a folder "libraries" in your sketchbook
  • - Create a folder called DULRadio and copy the content of the zip file there.


The library is still under development, so its sort of bumpy. The most important thing to realize is that dul.getDULData() returns an array of the datatype Object. You need to "cast" it into integers in order to work with it.

The way it is done in the example did not work for me. What I had to do is this:


int[] values = new int [4]; //create an int array for storing your data

// request data from the DUL radio
objData = dul.getDULData();
//use this to see the values which are coming in, prior to any manipulation:
println(objData);

//parsing objData
if (objData != null) { //only do this if there is data to work with
for (int i = 0; i < values.length; i++){
values[i] = (Integer) objData[i]; //cast the Objects as Integers
}
}

all the sensor data is now in the values array and should be easy to work with.

*

If you have any questions e-mail me. You can download the code here: www.paulstrohmeier.info/DUL_Processing.zip

p.

Donnerstag, 1. März 2012

ProjectionArt @ TEI2012

Tuesday was the day of meal and gathering at TEI. And apparently there was plans to project 'something' on the ceiling. Just nobody knew what.

So about 30 minutes before the banquet opened I was asked if I had something to project. I had been playing with the ESS library for processing and through something together in ~10 minutes.

Its simply two rows of white stripes which react to sound recorded through the microphone. But it looked fairly decent (sadly the pictures only show about two thirds of it) and people started interacting with it while waiting for their meal.




Thanks to Marty for the images :-)

Samstag, 18. Februar 2012

TEI2012 & New Website

All excited about TEI tomorrow. Will be presenting a paper, an art exploration as well as a submission to the design competition. :-)

Also, I now have a website.

www.paulstrohmeier.info / www.11235.info

check it out :-)