Forum 2005-2010 (read only)
(Read 8025 times)
Jan 17, 2011, 08:38 pm
Hi, I've gotta question about using the touchOSC app w Processing/Arduino. Basically, I have the app working with sample code I've found online, btwn both processing and arduino but so far I've only managed to blink an LED/send an output either high or low. What I've been trying is to have a slider/fader on touchOSC function like a potentiometer, where the movement of the slider pad works like an analog value in order to brighten/dim an LED, or change the speed of a motor (as an example). All I've managed to do when I try and play around with the code is to cause my test LED to blink in response to moving a slider on the app's screen. Can anyone point me in a direction that could help me figure this out? Any suggestions would be greatly appreciated. Thank you
Jan 20, 2011, 05:12 pm
I'm trying to do this also. Have you made any progress?
...blowing up boards one connection at a time
Jan 21, 2011, 01:58 am
i got something similar working a bit ago...
touchOSC to processing -> use the plug functions to connect the incoming OSC messages to a function inside of processing. once you have the functions and messages connected, you can call serial commands to send messages to an arduino. you'll have to build a simple protocol to send messages and have commands. like @r025,g056,b128+ where the '@" is the packet beginning, and the '+' is the packet ending.
on the arduino side, if you have the blinking LED going, you have all the connection stuff working, just parse your packet that you sent, and apply it to functions inside your arduino code.
don't expect blazing fast reactions... there are a lot of little steps happening, all the can be optimized, but are outside my skills... (if you get to the point of making it super fast let me know)
hope some of this makes sense and is helpful.