Week 16_Interface and application programming

I've worked a bit on Processing especially with the video and video/capture libraries and than a bit more on openProcessing.

I discovered a powerful opensource software called OBS_OpenBroadcastSoftware and a really useful website called Plot.ly.
Here some Plot.ly dashboards connect to sensors in my lab.

Than I spent time on Blynk.cc and Scratch .

After I played a lot with this makeymakey board with some scratch script.

Temp Interface Serial plotter

This are the Serial Plotter screenshot about my board thermistor value from latest version on the Arduino ide.

Temp Interface coded on Processing

I've designed a really clear interface that let you know the temperature reads and modified by my board.

All is based on the serial communication throw the atTiny and Processing. By the first the board print the temperature to the serial and than processing draw the chart.

Throw the chart you can tha communicate with the board and change the Value (by dragging that lil blue line) of the DESIRED TEMPERATURE in order to made the peltier cell made is job.

This is the sketch:


				import processing.serial.*;
				PImage sfondo;
				Serial myPort;
				float val;

				void setup()
				{
				  size(800, 600);
				  myPort = new Serial(this, "/dev/cu.usbmodem641", 9600);
				  sfondo=loadImage("chart.jpg");
				}

				ArrayList dati=new ArrayList();
				float scaleX=1;
				float scaleY=10;
				int graphPosX=200;
				int graphPosY=550;
				int maxDati=400;
				int temperaturaVoluta=20;

				void readSensor(){
				  while (myPort.available() > 1) {
				    myPort.read();
				  }
				  if (myPort.available() > 0){
				    val = myPort.read();
				    dati.add(val);
				    if (dati.size()>maxDati){
				      dati.remove(0);
				    }
				  }
				  println(val);
				}

				void draw()
				{
				  image(sfondo,0,0);
				  stroke(0,0,255);
				  readSensor();
				  for (int i=0;igraphPosX) && (mouseX10 && setValue<40){
				      temperaturaVoluta=setValue;
				      myPort.write(setValue);
				    }
				  }
				}
				

Finally here the curve with a initial trying of smoothing it.

Here te archive with sketches (.pde/.ino) I've used to for this interface and thats all.