We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpPrograms › Basic user input program needed
Page Index Toggle Pages: 1
Basic user input program needed (Read 535 times)
Basic user input program needed
Nov 24th, 2007, 5:47am
 
Although this has to do with Arduino, I still need some help with user input. I can't seem to learn from the examples. I don't want shapes or things to dim or light up based on keystrokes. I simply want to take a value from the user and use the write() function to send it to my Arduino board.

It would be good if I could just have a text box that says "Enter a voltage: " , then the user inputs a number (preferably a float/decimal) then hits "Enter". Then store this user input in a variable. Then I can do whatever I want with it. Thanks a lot for any help.
Re: Basic user input program needed
Reply #1 - Nov 24th, 2007, 7:50pm
 
Are you asking how to input values in Processing and then sending them to Arduino? If so, then this post is relevant!

If you want input boxes, I recommend using some UI libraries.
http://processing.org/reference/libraries/index.html

Recently I've tested them all.
All of them do a pretty good job.

ControlP5: user can enter data and then hit Enter to submit the values

Interfascia: Only Library to work under OPENGL

Spring GUI: Awesome library, supports the ctr+V (paste) shortcut, also works under P3D, Has all the HTML form elements

MyGui: Works great but needs more code to customize it. If you need examples on how to use these, I found this site
http://www.mkv25.net/applets/

My favorite is SpringUI, very easy to understand and works like a charm... but doesn't work in OPENGL

Hope this helps
Page Index Toggle Pages: 1