CREU Project Blog


Multitouch LED Display PART II (SIMPLE BIDIRECTIONAL LED TEST)
September 27, 2007, 4:12 am
Filed under: Electronics, LED Display, Multitouch, download

We basically set up our bi-directional LED the circuit according to diagram shown in the last last post.  We did followed all the instruction stated the paper on the implementation of a simple bidirectional LED demo, but it just doesn’t work!!   There are I think two possibilities why this is not working.  

  1. We did something seriously wrong
  2. Something is wrong with the microcontroller

At the current moment, I really don’t know how to fix this but here is a picture of the setup followed by the source code 

bidirectionalled.jpg


#define digi_fwd 2
#define digi_rev 3
void setup(){
  Serial.begin(9600);
  Serial.println("Arduino");
  pinMode(digi_fwd, OUTPUT);
  pinMode(digi_rev, OUTPUT);
}

void loop(){
  //Emitting
  digitalWrite(digi_fwd, HIGH);
  digitalWrite(digi_rev, LOW);

//Reverse Bias
  digitalWrite(digi_fwd, LOW);
  digitalWrite(digi_rev, HIGH);

  //Discharge
  digitalWrite(digi_rev, LOW);
  pinMode(digi_rev, INPUT);

  count = 0;

  while(digitalRead(digi_rev)){
    count++;
  }

  Serial.println(count, DEC);
  pinMode(digi_rev, OUTPUT);
}

The Arduino Sketch can be downloaded here


No Comments Yet so far
Leave a comment



Leave a comment
Line and paragraph breaks automatic, e-mail address never displayed, HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <pre> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>