ptitjes Posted December 8, 2007 Report Share Posted December 8, 2007 Hello,When i look in main.asm of the sm_example_v2 in the MIOS Download page, i can see that the touchsensors feature of MIOS are disabled. As i can test that yet, i would like to know if and how the touchsensor feature may interact with a led/button matrix as programmed in the example ? (I would need both...)Thanks for your help. Didier. Quote Link to comment Share on other sites More sharing options...
Wilba Posted December 9, 2007 Report Share Posted December 9, 2007 My experience with MIOS touch sensors wasn't that good... I wanted an array of them fairly close together but there was some serious crosstalk between them.I don't think you can connect touch sensors as part of the switch matrix... switch matrix works by sinking current on one "row" of switches, i.e. one pin of DOUT is low, the others high, so that when switches are closed, the DIN inputs which are normally pulled high are pulled low. MIOS touch sensors work by DIN inputs that are NOT normally pulled high... there is a high pulse before sampling and if your finger is there, it "soaks up" the high pulse so it samples a low.http://www.ucapps.de/mbhp/mbhp_din_touchsensors.pdfSo I'm not exactly sure how you would turn that into a matrix version... and even if you can, I'm guessing there would be some cross-talk issues with it as well.But don't take just my word, experiment for yourself, you might have different results. Quote Link to comment Share on other sites More sharing options...
phineus Posted December 9, 2007 Report Share Posted December 9, 2007 I don't know if this is relevant - because I use an Arduino as my interface - but I found that putting a 10k resistor between signal and ground of each sensor eliminates the crosstalk, and keeps the sensor values from "drifting" w/ no input. They now drop to 0V as soon as you let go and the voltages do not affect each other. Again, my circuit is Arduino-based not MB - so it may be a whole different story in your case. HTHhttp://www.soundwidgets.com/stribe/ Quote Link to comment Share on other sites More sharing options...
Wilba Posted December 10, 2007 Report Share Posted December 10, 2007 This is a different kind of touch sensor... detecting the touch of a conductive contact... A 10k resistor to ground is going to cause a voltage divide at the DIN input, 10k/47k*5V=1.06V, well under logic high threshhold. I think this is what your finger is doing when it touches anyway... grounding the charge with your body. (It actually works better if you ground your body). Quote Link to comment Share on other sites More sharing options...
phineus Posted December 10, 2007 Report Share Posted December 10, 2007 Oops, I misunderstood. Quote Link to comment Share on other sites More sharing options...
ptitjes Posted December 10, 2007 Author Report Share Posted December 10, 2007 Sorry. Maybe i did not correctly formulate my question!I do not want to make a matrix of touch-sensors! I want to use touch sensors *alongside* the led/button matrix.So as the sm_example_v2 code is disabling the touchsensors, i am wondering if this is possible... Does touchsensors uses service_prepare and service_finish to enable/disable J14 or in another way ? And how is that preventing from using touchsensors alongside a led/button matrix ?Didier. Quote Link to comment Share on other sites More sharing options...
Wilba Posted December 10, 2007 Report Share Posted December 10, 2007 TK explained how the touch sensor works in MIOS, a long time ago...http://www.midibox.org/forum/index.php?topic=1544I don't know why the touch sensor was explicitly turned off for the switch matrix example. My guess is that it isn't relevant and you can combine touch sensors with DIN inputs not being used in the matrix.You'll have to experiment for yourself to find out if it works. Quote Link to comment Share on other sites More sharing options...
ptitjes Posted December 10, 2007 Author Report Share Posted December 10, 2007 TK explained how the touch sensor works in MIOS, a long time ago...http://www.midibox.org/forum/index.php?topic=1544Ok! Great thanks as i missed that one... I now have a better view of the touchsensor story.I don't know why the touch sensor was explicitly turned off for the switch matrix example. My guess is that it isn't relevant and you can combine touch sensors with DIN inputs not being used in the matrix.I had the same feeling!I planned to experiment on this, however i wanted to have a first understanding of it and maybe some people already knew if it was a show-stopper. Quote Link to comment Share on other sites More sharing options...
stryd_one Posted December 13, 2007 Report Share Posted December 13, 2007 When i look in main.asm of the sm_example_v2 in the MIOS Download page, i can see that the touchsensors feature of MIOS are disabled. This is just an (educated) guess, but I'll say that's from development time, when TK was attaching a scope to that pin, and driving it at strategic places in the code to measure performance of the matrix. (A cool trick by the way, good for testing time-sensitive stuff). TK often uses that pin for that purpose.Go ahead and use the touchsensors :) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.