This article about how communication between Arduino and Java via USB. Due to “Arduino Playground” http://playground.arduino.cc/Interfacing/Java that describes how to communicate between Java and Arduino via USB port. This article is adapted to an osscilloscope. Arduino In the example, Arduino Uno to generate 25% PWM wave on PIN3 and then connects PIN3 and A0 together. In the loop() function, read an analog value from A0 and send thru USB by Serial.println() function. void setup () { Serial.begin(115200); while (!Serial) { ; // wait for serial port to connect. Needed for Leonardo only } pinMode(3,OUTPUT); //PWM 25% duty cycle on pin 3 analogWrite(3,64); } void loop () { int in = analogRead(A0); Serial.println(in); } Java The Java project “Simple oscilloscope” created by Netbean IDE and use JFreeChart library for creating graphs. The Simple oscilloscope implements SerialPortEventListener, when data is incoming on USB port the program call function...
Java ,Jboss ,Electronic ,Jboss ,Mysql ,Arduino ,Application Server, Database ,Hack ,Technology ,SOAP ,Web Service, Programming ,Language ,Developer