Thursday 31 March 2011

Lense delivered ! At last !

I just received from dealextreme.com my 2.1mm lense for m12...! Almost 20 days after having placed the order... As I need a second PS3 Eye camera (because my table is only 20cm high), I'll order it with a DIY lense kit from Peauproduction.




It looks pretty neat, I'll be testing that tomorrow night ! As it won't cover the whole display (32" is too big to be seen from only 20cm), I'll set the resolution to like 800*600 in native (in order to reduce the display size).


I've read in this post that some people had a some issue with the backlight (and especially with the 32LG3000 tv I've bought). It seems to be emiting quite a lot of IR arround 780nm, leaving some massive light pollution... As I don't have the same setup (he has a pane of glass directly under the LCD screen that - of course - reflects a LOT, as I only have a couple of diffusers (with the reflective side up). I hope that'll do the trick, but I'm still thinking about switching to 850nm in case that something's wrong.


I'll be posting the results during this weekend...

Thursday 24 March 2011

Installing the LCD

Okay, now, I need to make everything go inside... Quite complicated actually ! The table is very small and the screen quite massive in comparison.

I've taken as main computer for my table my girlfriend's old laptop (not that old actually) that has its screen smashed up, and the battery dead : perfect for what I need !

It's a MacBook, Core Duo 1.83GHz with 2GB Ram and 60Gb HD. The GPU is rubbish, but that should do the job.



Using a laptop is handy, as it takes a lot less space and gives off less heat (and has a remote control in my  case :D).

Now trying to fit everything in the table :



Hum, that'll do it, but it's tight... A few screwing / cutting later :






And that's it ! With a couple of modifications, it'll be amazing. The tempered glass over it makes the table very solid, and I just need to add some silicon to make it waterproof (that's still a coffee table, isn't it?).

Next steps : placing the fans to make it even cooler (no pun intented) and test the lasers. And I'm still waiting for my lense...

For the second cam, I'll order at PeauProduction with everything already modified... !

Preparing the Coffee table

Ok, here we are. That's my coffee table inside my little Parisian flat, a Ramvik from Ikea. It's quite nice, with some tempered glass over it. Actually, the main part is thinner than I expected, I'm pretty sure I'll need 2 cameras to be able to track de whole display.



And here we go !

 





Placing the LCD plastic frame


And here we are ! The main case is only 20cm high, so, yeah, I'm sure I'll need to go for 2 cameras with some distortion lenses...

The 32" TV screen

I've ordered on eBay a 32" LG LCD TV from a very nice guy from Auvergne in France, a 32LG3000. That model was used by a guy on nuigroup.com and I knew it hadn't any FFC issue.

Except the fact that I had to take a day off a friday to wait for the delivery and that the bloody f****g ars****le that was supposed to drop it pretended I wasn't there (typical), I've got to say I'm very pleased with that order.




The 32LG3000 is only 2 years old, has a quite nice contrast ratio and is HD Ready (and not Full HD). For MT purpose, HD ready can be better, as it has more spaces between the pixels and the IR light seems to go easier through it (apparently). Anyway, a HD ready is often cheaper and will use less CPU usage for native resolution display, so that's still good news :)



The disassembly is quite straight forward too, nothing really annoying with it.





A good thing to do is to take a picture of every component before unplugging it to be sure to know how to replug everything. Here are some of those pictures I've taken. 










And here is the LCD matrix. Actually, I've got to say it's bigger than I expected ! I can't wait to test it....

First test !

 Ok, now that I have everything I need to test the solution, let's go for it :


The components used here are just here for testing purpose. Here's what I'm missing :
  • PS3 Eye modified camera (still waiting for my Lense !)
  • the 32" (82cm) LCD screen
  • the acrylic for the table


I'll then use my 17" screen, the Philips modified camera (@15 FPS yiipii !), a piece of glass, and... A upside-down wooden stool  :/



 The amazing stool


As I don't have the lense, and the Philips webcam is zooming a LOT, I can't put it under the setup, as it would need arround 1m depth to be able to see the whole frame. I had to put it on the side and it's then even less accurate. But anyway, this is for testing purpose !





 With the LCD matrix over it


First display test (I forgot to put the diffuser...)




 
What a lovely finger ! (didn't do it on purpose :x)

And it works ! I only used 1 laser (at the top left) and we can see a liiiittle white spot on the upper right black image... That might sound weird for people that don't know MT technologies, and quite dumb for people that are familiar with it, but, c'mon, the first blob is always kinda amazing !

Well... Let's go for the real stuff then !


Assembling the camera

Now that the test LCD is ready, let's go for the camera :

To track the blobs, I've followed nuigroup.com and I've bought on fnac.com a PS3 Eye camera for 18€ (21€ including shipping). This camera being able to capture 640*480 at 60fps is the perfect low price device you'll want to buy for your Multitouch table.

Be very careful, as there are actually 2 kinds of PS3 Eyes, that you (unfortunately) can't distinguish from, except by taking them appart. As very well exeplained by PeauProduction in that post, one kind has its IR block filter very easy to remove, whilst the other has it almost impossible without breaking the lense.


To clarify a bit, here's the thing :
A PS3 Eye has 4 parts you must have in order to correctly make it track IR light from your fingers :
  • The camera (the base)
  • A Lense mount
  • A lense
  • A bandpass filter.


A OEM PS3 camera has the lense mount glued with the lense : if you want to change the lense, you'll have to buy a new mount. But, in the "good" camera, the IR block filter can be removed from the mount. If you chose to do that, you can add the Bandpass filter (or a floppy disk piece) and you'll have a fully fonctionnal IR camera. But if you want to change the lense (i.e. if your table isn't high enough and your camera can't see the whole display), that'd bring you to the second choice : changing the lense mount, and then the lense. If you have the "bad" camera, you'll HAVE to do that anyway.

 The lense mount


There are two types of  mounts : the m12, which is the best (but arround $20), and a noname. A couple of people including me found perfectly compatible mounts in random webcams. If you find that webcam on eBay (6€), it has a lense mount (which isn't glued !) that you can take appart for your PS3 Eye.


This webcam is worth 6€ on eBay and can be taken appart for the lense mount



Whilst I was waiting for it to be shipped, I've found a Philips webcam (kinda rubbish) that I took appart and - surprise - it also had that lense mount ! I begin to think this is a really common mount...




That webcam also has the compliant lense mount.


The Philips webcam was even better, as you can very easily take away the IR block filter for testing purpose (as you are waiting for the PS3 Eye or some lense to be shipped). As seen on the picture, a simple knife is enough to get rid of it. The IR filter is simple to spot, it has a reddish reflect when you place it under a light.






If you have the "good" PS3 Eye camera, you can also take that filter appart, follow this very well explained process.




The bandpass filter


Once the IR filter taken appart, your camera is able to see IR light. Good start ! Now, the problem is that it will also see visible light... And you will have a massive light pollution : your camera will have some hard time identifying IR blobs from ambiant light.

Thus, you need to have a bandpass filter that will block all light except the IR light. A typical bandpass filter (not that effective though) is a piece of a floppy disk. If you still can find one (good luck!), you'll notice that you can't see through... It blocks visible light, but not IR light : if you press a remote command button in front of it, and look at your modified webcam, you'll see the white IR light through it.

But it isn't that effective, as it will let a big IR spectre go through, and other IR light from your room will still gets you a hard time detecting your blobs.


To solve that issue, you can buy some bandpass filters at Omegabob2 on eBay or at the PeauProduction online store for $24 : a proper bandpass filter will only let specific wavelength go though, and then will considerably reduce the ambiant light. As I bought 780nm lasers, I've bought a 780DF60 bandpass filter for PS3 Eye. 780DF60 means that it will let light at 780nm go through, +/- 60mn, then from 720nm to 840nm (as seen on the following chart).






 The lense

If you have the "good" PS3 Eye, and want to keep the OEM lense, you don't need this part.

If you have the "bad" one, or want to change the lense (as I do), you'll need to buy one at PeauProduction (arround $20). You'll have to calculate the focal length you need...

I've found on the nuigroup.com forums that that particular fish eye 2.1mm lense worth $6 worked well with PS3 cameras...I've ordered one, and am still waiting for it ! I hope that one is gonna be Ok.


First test with the modified Philips webcam... IR light spotted :D

Wednesday 23 March 2011

Disassembly of the 17" LCD screen

Disassembling the LG 1730S 17" LCD screen was actually quite simple : the whole procedure is straight forward (just unscrew all the screws you find) and take everything appart. Juste be very carefull about the LCD matrix as it's veerrryy fragile !


Here are some pictures I took during the whole procedure (with my cat overseeing it) :



 The main components (including the coffee table!)








 "I has watfing you !"*





Testing the screen... Ok !

Everything's ok ! Let's go for the camera.


* "I am watching you" !

Parts and where I found them

Okay, I was ready to find all the components needed for a LLP set up. Here's the list :
  • A LCD with no FFC issue (I'll explain later)
  • Clear, flat surface (Glass, Acrylic, Polycarbonate, Plexiglass, etc.) 
  • Infrared Laser(s) x 4
  • Line Generating Lens x 4
  • Diffuser sheet
  • Infrared Camera/Modified Webcam
  • Few meters of electrical wire
  • Some electrician stuff
  • And of course the table.

The LCD Screen

I used for the prototype my old 17" LG 1730S. Chosing a LCD display for a MT Table is quite a challenge, as they can have the "FFC (Flat Flexible Cable) issue I've spoken earlier about. That problem can be sum up like this :

LCD screen are getting smaller and smaller, so are getting the cables and wires in them. FFC is a kind of flat wire (like tape actually) that are used in all LCDs to free some space. As you probably know, a LCD matrix is transparent and the light must go entirely though it. But sometimes, there is a FFC standing in front of the LCD matrix that you can't move (see picture below). In that case, a whole area of the screen won't be lightened when the LCD is disassemble and will be dark.

 Typical FFC Issue.


I've seen in the Lumenlab FFC database that this screen didn't have that problem, so I chose it.


Infrared Lasers

To be detected, your fingers must be lighted with IR light, in order for your camera to distinguish visible light from IR light. The common lasers used for that purpose are 780nm 25mW from Aizix.net. As I wanted to go for a 32" (82cm) LCD TV screen, I wanted the lasers to be powerful enough. For a smaller set up (17"), a 780nm 10mW would be ok.

A 780nm 25mW IR laser

The lasers must have a Line Generator in front of them, in order to create the laser plane. I chose the 89°, to waste less power from the laser, still from Aizix.net. A 120° would be ok too, and easier to calibrate (as it's quite a lot wider).


Infrared Camera

There are a quite a lot of solutions about the camera : the nuigroup.com community mainly bases its set ups with the PS3 Eye camera (Playstation 3), as it's quite cheap, has a good image quality and is VERY fast (60fps at 640*480). That was the way to go for me !


I bought one for 18€ at Fnac.com in France, and got it a couple of days later. Very cheap / fast.


The PS3 Eye Camera


But the camera isn't capable of seeing IR light without a couple of modifications :
  • It has a IR light filter (that you'll want to remove as it's doing the opposite of what we want it to do)
  • The lense is not bad, but for a smaller set up (table height) you'll want to go for a lower focal length
  • Half of the PS3 Eyes (it seems to be quite random actually) have the IR filter you can't remove without destroying the whole lense. As everything's glued in it, you'll want to go for another lense mount.
  • You need to add a IR bandpass filter to cut off the light noise from visible light
I'll explain later of to do all that and where to buy all the components.


Everything's ordered then, I can set up the main parts...

A couple of researches...

It's been more than a year now that I started to look into Multitouch technologies. I was indeed very keen on getting to know more about it, and could'nt wait to start building my own table. Of course, like almost everyone, I wanted it to be able to do everything : blob recognition, object tracking, fiducial tracking... But that was getting more and more complicated.

I joined the nuigroup.com community (the main reference for everything about MT technologies) and spend a lot of dozains of hours (really) reading threads and posts.

As quite a lot of people did, I chose to start with a "simple" technique : the LLP (Laser Light Plane) or the Rear DI (Diffused Illumination). I was almost sure that a too long / difficult way would have me dropping the projet half finished.

But as I wanted my change my coffee table into a multitouch one, it appeared that Rear DI was only compliant with the projection mode (using a projector) and that that implied the table to be quite big, even using a mirror. As I wanted to use a LCD screen, the LLP was then the way to go for my first table!





LLP chart from Seth Sandler


LLP has quite a lot of pros (taken from nuigroup.com) :
  • No compliant surface (silicone) needed
  • Can use any transparent material like glass (not just acrylic)
  • No LED frame required
  • An enclosed box is not required
  • Simple setup
  • Could be slightly cheaper than other technique

But of course it's not perfect, and the cons are quite rubbish :
  • Cannot track traditional objects and fiducials 
  • Not truly pressure sensitive (since light intensity doesn’t change with pressure).
  • Can cause occlusion if only using 1 or 2 lasers where light hitting one finger blocks another finger from receiving light.



And I was ready to start looking for some parts...