Language \ Environment \ Libraries \ Comparison  
   
Back  
   
  If you see any errors or have any comments, let us know.  
Class   Gainer
   
Name  

peekDigitalInput()

   
Examples  
// Example   input digital port(once)

import processing.gainer.*;

Gainer gainer;
PFont myFont;

void setup() {
  size(300, 255);
  myFont = loadFont("CourierNewPSMT-24.vlw");
  textFont(myFont, 24);

  gainer = new Gainer(this, "COM4"); 
}

void draw() { 
  background(0);
 
  text("digitalInput[0]: " +gainer.digitalInput[0],10,80); 
  text("digitalInput[1]: " +gainer.digitalInput[1],10,110);
  text("digitalInput[2]: " +gainer.digitalInput[2],10,140);
  text("digitalInput[3]: " +gainer.digitalInput[3],10,170);

}
  
void mousePressed()
{
  gainer.peekDigitalInput();
}
  

  
 

Description   It makes bring values to digitalInput[] from digital input ports at one time. command "R*"
   
Syntax  
gainer.peekDigitalInput()
   
Parameters  
gainer   any variable of type Gainer

   
Returns   void
   
Usage   Application
   
 
 






   
 
Updated:??
 
 








Creative Commons License
 
  Processing is an open project initiated by Ben Fry and Casey Reas  
  © Info