Building a Touch Table 101

5 05 2009

As promised, here is the article on how my team and I built our interactive kitchen table step by step with all the details from hardware to software. Note that this is just ONE of a few methods to build a touch table in your garage and other methods may be more suited for the purpose of your touch table. To learn more about the various different methods, I highly recommend joining the NUIGroup community who is always there to contribute to discussions and help you with any questions you have 😀

Alright, lets begin!

Methodology used: Diffused Illumination

Hardware Setup
Materials required:
1) Piece of glass / acrylic
– this is the surface you’d like to project your screen onto. My team chose to use glass instead of acrylic as acrylic is a bit soft and bendable, hence not very stable for a kitchen counter top where you’ll be messing around with your ingredients.

2) Stand to place your piece of glass/acrylic
– can be wooden, metal, self-made, as long as you have enough height to project your screen onto the surface from below.

3) Projector
4) Web camera
5) Piece of Mirror

Once you have the hardware needed, set it up such that the arrangement is similar to the image below. (Please excuse the illustration.. drew it in a hurry with no thought for the colours chosen haha!)

Adjust the mirror angle and projector settings until you get the size you want of the projected screen on the surface. Once you get the alignment right, position your web camera such that you are able to see the whole projected surface area. Note that you need not position the web camera where I placed it.

Alright that’s it for the hardware! Simple huh? Now lets move on to the software needed.
 

Software setup

1) TBeta by NUIGroup

This is the software needed to track shadows detected by the web cam and send the data retrieved from it to another channel or software. I highly recommend that you read the tutorial on how to adjust the different settings (e.g: Threshold, contrast, callibration, dynamic subtraction, etc). For our table, we took a while to get the settings right so that it will detect only shadows that were pressed on the surface.

2) FLOSC
What FLOSC does is that it takes values sent to it by Tbeta and sends it over to your interface application. For ours, we used it to send positional coordinate values to our application written in Flash.

3) TUIO
TUIO will contain the code which you will need to add to your Flash ActionScript file so that your Flash application listens to data from the same port that FLOSC is sending data to. In other words, if FLOSC is sending data to port 3333, you set your Flash to listen to data from port 3333 using TUIO. You can then use TUIO to extract the necessary data for your application like the X and Y position of the shadows detected on the interface. Note that the TUIO API also has code which you can add to your Flash application to detect TouchEvents (e.g: TouchEvent.CLICK).

4) Adobe Flash
Thanks to the TUIO API, all you have to do is code your whole Flash application as per normal, add the necessary 2 or 3 lines of code to read the TUIO API and replace all your MouseEvents with TouchEvents :D! It is really that simple. The way I coded the interface was to do it fully using MouseEvents in Flash and then later changing it to TouchEvent when I wanted to test it out on the touch table.
 

Limitations of not having InfraRed Lasers
The limitations of our setup is that we didn’t have any InfraRed Lasers / Camera to detect the touch. We were using shadows and sometimes when the shadows can’t be seen clearly especially in areas where the background colour is not dark enough, it is not detected as a touch. Hence, I designed the interface such that all the buttons that will be pressed have dark-coloured backgrounds. If you used InfraRed lasers on the other hand, it would be very sensitive and accurate leading to a much more responsive table. The reason why we didn’t include the InfraRed gadgets was because we couldn’t find them here in Singapore and didn’t want to spend a bomb ordering them from overseas. If you do get the opportunity however, I highly recommend using InfraRed lasers.

Alright! So there you have it, my quick guide to building a touch table. If you find any parts of this tutorial unclear or have further questions, feel free to e-mail me or drop a comment here! Will reply and update this post accordingly as soon as I can 😀

And thanks for the very encouraging comments on the project guys! Really appreciate it! Enjoy hacking in your backyard! ^_~

Additional resources you might want to check out:
Discussions about building a touch table on NUIGroup
Build your own InfraRed Camera (thanks James!)
Quick tutorial on building a touch table using Total Frustrated Internal Reflection
Reactivision for tracking fiducial markers





Recipease: Interactive Kitchen Table

20 04 2009

Hey guys! Know I’ve not been blogging for a looong time… mainly because I’ve been busy working on projects at school and exams are around the corner. However, thought I should just put up a quick post about one of my projects, Recipease, a project I worked on as part of the CS3248: Design of Interactive Media module. What we did was create a multi-touch table that is supposed to show a concept of how major problems faced by people during the food preparation process can be reduced.

Before I say more, here is a video demonstration of our table.

Yup so that’s about it in short! Promise to update this post with more information later. In the meantime, if you have any questions about the project / engineering behind it, etc etc do feel free to either e-mail me or leave comments here. I promise to follow-up on it as soon as my exams are over!

And oh yea, do let me know what you think of it as well in terms of concept, interface and interaction design, functions, or even the actor! Thanks for watching! ^__^

Update:
Thanks for all the encouraging and positive comments guys! Really appreciate them. As promised, here is the follow-up with more information about the project.

Our assignment requirement is to take any existing electronic appliance or propose a new one that would solve a problem or make a house chore easier. The problem we set out to solve was that faced by users in the kitchen.

Before we built this, we performed some surveys and interviews to identify the common problems that caused people anxiety during both food preparation and cooking. Our user group consisted both of young adults and housewives, including both novice and expert cooks. Based on the list of problems gathered, we came up with 3 primary functions:

Use Case: Our primary use case is where a person, has some ingredients in his fridge but do not want to crack his head thinking what he can cook with them. He wants a system that can tell him what he can cook based on what he has or feels like eating (sometimes you may have fish and chicken but only feel like eating chicken).

1) Ingredient Recognition
Problem it solves:
– trouble of not recognizing what user has especially with ingredients user hardly purchase
– unsure of what user can cook with what he/she has

2) Recipe Recommendation
Problem it solves:
– saves trouble of thinking about what he can cook
– widens choice of recipes user can cook. Not limited to only what the user knows
– informs users of which ingredients are missing
– if user is cooking more than one dish, system notifies of whether there is enough for both dishes combined

3) Recipe Scaling
Problem it solves:
– most recipes available are based on the assumption that users are cooking for one diner. However, sometimes users throw parties/gatherings that require preparing a dish for more people.
– able to tell user whether he has enough for a gathering and if not, how much of which ingredient is missing

Our user testing of the table after it was built showed that this concept does help in reducing the anxieties users felt during food preparation and pre-cooking. Glad that those of you who have seen the video felt the same as well.

About the module
Got a couple of e-mails asking whether this module teaches students how to build a touch table. The answer is no, but in fact the professor (Prof Zhao ShengDong) made it better than that. What he did was he made the assignment very open-ended, with the only requirement being to come up with a concept that will make a house chore easier for a user. This can be a new electronic appliance or an improvement of an existing invention. It is totally up to students how they want to implement/show their idea. Hence you have students building touch tables, interactive screens that utilize the Wii mote and even remote controls for house appliances using the cell phone. In other words, this module does not teach or spoon feed you on how to do things but rather create an environment that encourages students to experiment. How much you learn depends on how much time and energy you invest into your idea. Having said that, Prof Zhao will be constantly keeping track of the progress of projects and is a great resource of how to go about your project and who to approach for further advice.

The Team!

This is my crazy team who just can’t stop making me laugh while working throughout the project. Somehow we never fail to do something really silly which we’ll be stuck at for hours before suddenly encountering an “Eureka!” moment. Lots of silly things happened during video filming as well, like someone’s handphone ringing and ingredients rolling off the table.

Back row (from left) : Teong Leong, Joel a.k.a Kar Meng, Jeremy Wong
Front row (from left) : Me! , Yiyang

Concluding words
This was a really fun project which made me realize how fun research can potentially be. I used to shun away from it thinking it was for n3rds but came to realize it can turn out to be pretty cool especially if you’re working on a fun project within your scope of interest. Would really love to thank my Prof Zhao for making CS3248 a really fun module and encouraging us to go on with our ideas!

How to build a touch table?
Got a lot of questions about how my team built the touch table and all the various programs we used. I’m currently in the process of writing a step by step tutorial on it and will upload it within the next 2-3 days! In the meantime, look out for it! ^_~

Update: The tutorial is done. Check it out here 😀





Slime mind-controls ant

15 11 2008

This is one of the most bizzarre facts I’ve ever come across. Those innocent, harmless looking slime creatures are actually more powerful than lions.

Now I wonder whether the same would happen for humans who “accidentaly” consume the slime. 😐

Resources you might want to check out:
National Geographic on YouTube <– LOTS of cool stuff.





Wildlife.. interesting behaviour

11 11 2008

Everytime I watch lions attack a deer on TV, I get super angry because first of all the deer wasn’t alone.. it was with a group of other deers and when one of them is attacked by the lion, the other deers run away. After they have ran a distance and the baby deer is in the lion’s grasp, they just STARE and WATCH instead of helping. One lion and a group of deers? Come on! It is not impossible for them to save their comrade. They can’t be that selfish right?

And then came this infamous video on YouTube!

According to the voices in the video, this is the first time the buffaloes are pulling together to fight against the lions in the park. Maybe, like humans, one buffalo thought about things more than the rest leading to their new found collective behaviour. The next curiosity I had following from this is now that it is harder to eat buffaloes in the park, will the lions adopt a different attack strategy? It’d be interesting if the few lions manage to come up with a strategy that can beat the huge group of buffalos. Coz then we would have the Sun Tzu of the wild!





Creature that can survive in space!

9 05 2008

I’ve been back in Malaysia for about 3 days and after catching up with all the good food and shopping, I decided to spend some time at home writing. I was wondering what would be interesting, went through my drafts and saw this! I’ve been wanting to blog about this since last year but never found the time. Special thanks to Jiin Joo for telling me about this “alien”-ish creature!

Waterbear image
The Waterbear!

This creature is no other than the Waterbear which bears the scientific name Tardigrade for slow-walking animal. For starters, (this will disappoint you) they are not your average-sized mammal but microscopic creatures that resemble a GUMMI bear with a face, claws and paws. They come in Gummi bear colours of orange, red and green too! 😀

Check out this video of the Waterbear walking. You can actually see its paws and feet:

Where can you find them? According to Microscopy UK, they can be found almost anywhere especially in water droplets of dark moss. Among some of the extreme places where their existence has been encountered are at the top of the Himalayas, in hot springs and under thick layers of solid ice. One of the unique traits of the Waterbear that allows them to survive in literally any condition is their ability to “sleep” and “revive” themselves again. They are capable of deactivating their metabolism turning into a suspended state which will “reactivate” when exposed to water. Talk about people who need a bucket of water splashed on their faces to wake up. Watch the video of the Waterbear’s “returning from the dead” process here.

The other extreme conditions they are able to survive in (where most living things suffer/die) are temperatures over 100C, absolute zero, pressures many times the atmospheric pressure, in vacuum and even a decade without water. There are a few parties online who mention a NASA Space Shuttle experiment (which I failed to find on the official NASA website) where a few microbes including the Waterbear were placed on a rock and put in outer space. Upon entering the vacuum, the microbes went into a suspended state and despite long-term exposure their DNAs were not affected by any radiation. In other words, the Waterbear’s DNA is radiation resistant. This rare ability to survive in vacuum and withstand radiation has caused speculations that these creatures are capable of interplanetary travel and may have come to Earth from other planets. It still remains a question of how long the Waterbear will be able to survive in this suspended state(some say a few years) and whether it is able to withstand the harsh conditions that deep space holds to travel to another galaxy.

The Waterbear is certainly one of those marvels of science (and mystery of outer space?) with a lot for us to learn from. Who knows, when we discover the secrets behind their DNA we might be able to apply the knowledge gained to modify and make our DNAs more resistant to radiations and MAYBE… (a huuuge maybe) hibernate long enough for inter-galactic travel. Mysteries are knowledge waiting to be mined and as the saying goes, with knowledge comes great power 😀
.

Interesting resources you might want to check out:
The incredible waterbear!
The Waterbear it is! from Scientific Blogging
Earth Life could possibly reach Titan from Slashdot. (Discussions under comments are really interesting)
Hunting for ‘bears’ in the backyard





Japanese see-through frogs

2 10 2007

See-through frogSee-through tadpoles

After my 3rd mid-term exam for the day, I swiftly hopped onto my laptop to relax a bit before the next war. (Not that the exams all went well, overall they were O.K). Anyway, the moment I got online, my ever resourceful brother IMed me this news about a new scientific breakthrough: See-through frogs.

Yes, literally. According to numerous video reports, the Japanese-bred (yes, its the Japanese again!) frogs have a semi-translucent skin since birth allowing viewers to see the organs form and grow within them. With this breakthrough, researchers and students no longer need to dissect these amphibian creatures to study their organs, addressing concerns brought up by animal rights activists on the ethics of frog dissections in schools.

Another benefit of this breakthrough, as mentioned by lead researcher Masayuki Sumida is how “researchers can now observe how toxins affect bones, livers and other organs at lower costs”. The largest plus point that totally blew my mind though was how these frogs are more “modifiable” than just feeding them something and watching how their bodies react to it.

Believe it or not, you can actually inject “markers” into them or attach it to genes to watch how these genes spread within them. As quoted from this article,

Sumida said researchers could also inject into the transparent frogs an illuminating protein attached to a gene, which would light up the gene once it manifests — for example, showing at what stage cancer starts.

Maybe now we can understand cancer cells better, the way they behave, what ticks them and hopefully very soon, what kills them. However, as many have said, this is limited to observations and experiments on frogs (aka amphibian creatures) that have very different body mechanisms from mamalian animals. Nevertheless, this is a step forward in science which will definitely lead to more breakthroughs be it for diseases, cancers, genetic disorders or who knows, maybe even see-through human beings.

Side note: In case you’re wondering, amphibian skin is very different from mamalian (human) skin and hence, this breakthrough cannot be applied to create “see-through human beings”. Being able to create see-through human beings will definitely be a GIGANTIC leap in answering the many mysteries of the human anatomy but then again, do you want to see a see-through human being? I know I’d be really freaked out if I saw one. Not only that, is it ethical to breed such a human being and have diseases injected into him/her for experimental purposes? We will all then be debating the issue of human experimentation over again.

Seriously, deep down inside I really hope they can create such human-beings to find a faster cure for the various diseases plaguing this world(especially AIDS and cancer) but I get chills thinking about how these noble and miracle human-beings would be living their lives. Who knows, our society may even come to classify them as a new “minority race” specially created for scientific experimentation.

Resources:
No need for dissection as see-through frogs jump in
Video reports from various sources