HDSP2003 / HDSP2000LP

Zielig kwam hij binnen. Kreeg aanschafprijs daardoor bijna helemaal retour…

dead bug…

Ta-dááa’. With a little help from my nails…

HDSP2003_datasheet

Arduino sketch — just testing brightness by frequency

//*** HDSP2003
//*** Brightness by strobing
//*** phuinink@gmail.com

int column[] = {2, 3, 4, 5, 6};
int data = 7;
int clock =8;
int snelheid = 0;

void setup(){
  pinMode(data, OUTPUT);
  pinMode(clock, OUTPUT);
  digitalWrite(data, LOW);
  digitalWrite(clock, HIGH);
  for (int i = 0; i < 5; i++){
    pinMode(column[i], OUTPUT);
  }
  for (int i = 0; i < 5; i++){
    digitalWrite(column[i], LOW);
  }
}

void loop(){
  snelheid++;
  for (int hh=0; hh<(1000/snelheid); hh++){
    for (int i = 0; i < 5; i++){
      for (int j = 0; j < 24; j++){
        digitalWrite(clock, HIGH);
        digitalWrite(data, j%2);//int(random(2)));
        digitalWrite(clock, LOW);
      }
      digitalWrite(column[i], HIGH);
      delayMicroseconds(snelheid*snelheid);
      digitalWrite(column[i], LOW);
    }
  }
}

Toen ASCII erin gezet:

Arduino Sketch HDSP200x

//*** HDSP2003
//*** Brightness by strobing
//*** phuinink@gmail.com

const byte ascii_5x7[] = {
  // 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
  0x01, 0x02, 0x04, 0x08, 0x10, 

  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0xF2,  0x00,  0x00,  
  0x00,  0xE0,  0x00,  0xE0,  0x00,  
  0x28,  0xFE,  0x28,  0xFE,  0x28,  
  0x24,  0x54,  0xFE,  0x54,  0x48,  
  0xC4,  0xC8,  0x10,  0x26,  0x46,  
  0x6C,  0x92,  0xAA,  0x44,  0x0A,  
  0x00,  0xA0,  0xC0,  0x00,  0x00,  
  0x00,  0x38,  0x44,  0x82,  0x00,  
  0x00,  0x82,  0x44,  0x38,  0x00,  
  0x28,  0x10,  0x7C,  0x10,  0x28,  
  0x10,  0x10,  0x7C,  0x10,  0x10,  
  0x00,  0x0A,  0x0C,  0x00,  0x00,  
  0x10,  0x10,  0x10,  0x10,  0x10,  
  0x00,  0x06,  0x06,  0x00,  0x00,  
  0x04,  0x08,  0x10,  0x20,  0x40,  
  0x7C,  0x8A,  0x92,  0xA2,  0x7C,  
  0x00,  0x42,  0xFE,  0x02,  0x00,  
  0x42,  0x86,  0x8A,  0x92,  0x62,  
  0x84,  0x82,  0xA2,  0xD2,  0x8C,  
  0x18,  0x28,  0x48,  0xFE,  0x08,  
  0xE4,  0xA2,  0xA2,  0xA2,  0x9C,  
  0x3C,  0x52,  0x92,  0x92,  0x0C,  
  0x80,  0x8E,  0x90,  0xA0,  0xC0,  
  0x6C,  0x92,  0x92,  0x92,  0x6C,  
  0x60,  0x92,  0x92,  0x94,  0x78,  
  0x00,  0x6C,  0x6C,  0x00,  0x00,  
  0x00,  0x6A,  0x6C,  0x00,  0x00,  
  0x10,  0x28,  0x44,  0x82,  0x00,  
  0x28,  0x28,  0x28,  0x28,  0x28,  
  0x00,  0x82,  0x44,  0x28,  0x10,  
  0x40,  0x80,  0x8A,  0x90,  0x60,  
  0x4C,  0x92,  0x9E,  0x82,  0x7C,  
  0x7E,  0x88,  0x88,  0x88,  0x7E,  
  0xFE,  0x92,  0x92,  0x92,  0x6C,  
  0x7C,  0x82,  0x82,  0x82,  0x44,  
  0xFE,  0x82,  0x82,  0x44,  0x38,  
  0xFE,  0x92,  0x92,  0x92,  0x82,  
  0xFE,  0x90,  0x90,  0x90,  0x80,  
  0x7C,  0x82,  0x92,  0x92,  0x5E,  
  0xFE,  0x10,  0x10,  0x10,  0xFE,  
  0x00,  0x82,  0xFE,  0x82,  0x00,  
  0x04,  0x02,  0x82,  0xFC,  0x80,  
  0xFE,  0x10,  0x28,  0x44,  0x82,  
  0xFE,  0x02,  0x02,  0x02,  0x02,  
  0xFE,  0x40,  0x30,  0x40,  0xFE,  
  0xFE,  0x20,  0x10,  0x08,  0xFE,  
  0x7C,  0x82,  0x82,  0x82,  0x7C,  
  0xFE,  0x90,  0x90,  0x90,  0x60,  
  0x7C,  0x82,  0x8A,  0x84,  0x7A,  
  0xFE,  0x90,  0x98,  0x94,  0x62,  
  0x62,  0x92,  0x92,  0x92,  0x8C,  
  0x80,  0x80,  0xFE,  0x80,  0x80,  
  0xFC,  0x02,  0x02,  0x02,  0xFC,  
  0xF8,  0x04,  0x02,  0x04,  0xF8,  
  0xFC,  0x02,  0x0C,  0x02,  0xFC,  
  0xC6,  0x28,  0x10,  0x28,  0xC6,  
  0xE0,  0x10,  0x0E,  0x10,  0xE0,  
  0x86,  0x8A,  0x92,  0xA2,  0xC2,  
  0x00,  0xFE,  0x82,  0x82,  0x00,  
  0x40,  0x20,  0x10,  0x08,  0x04,  
  0x00,  0x82,  0x82,  0xFE,  0x00,  
  0x20,  0x40,  0x80,  0x40,  0x20,  
  0x02,  0x02,  0x02,  0x02,  0x02,  
  0x00,  0x80,  0x40,  0x20,  0x00,  
  0x04,  0x2A,  0x2A,  0x2A,  0x1E,  
  0xFE,  0x12,  0x12,  0x12,  0x0C,  
  0x1C,  0x22,  0x22,  0x22,  0x22,  
  0x0C,  0x12,  0x12,  0x12,  0xFE,  
  0x1C,  0x2A,  0x2A,  0x2A,  0x1A,  
  0x00,  0x10,  0x7E,  0x90,  0x40,  
  0x12,  0x2A,  0x2A,  0x2A,  0x3C,  
  0xFE,  0x10,  0x10,  0x10,  0x0E,  
  0x00,  0x00,  0x5E,  0x00,  0x00,  
  0x04,  0x02,  0x02,  0xBC,  0x00,  
  0x00,  0xFE,  0x08,  0x14,  0x22,  
  0x00,  0x82,  0xFE,  0x02,  0x00,  
  0x3E,  0x20,  0x1C,  0x20,  0x3E,  
  0x3E,  0x10,  0x20,  0x20,  0x1E,  
  0x1C,  0x22,  0x22,  0x22,  0x1C,  
  0x3E,  0x28,  0x28,  0x28,  0x10,  
  0x10,  0x28,  0x28,  0x28,  0x3E,  
  0x3E,  0x10,  0x20,  0x20,  0x10,  
  0x12,  0x2A,  0x2A,  0x2A,  0x24,  
  0x20,  0x20,  0xFC,  0x22,  0x24,  
  0x3C,  0x02,  0x02,  0x02,  0x3C,  
  0x38,  0x04,  0x02,  0x04,  0x38,  
  0x3C,  0x02,  0x0C,  0x02,  0x3C,  
  0x22,  0x14,  0x08,  0x14,  0x22,  
  0x20,  0x12,  0x0C,  0x10,  0x20,  
  0x22,  0x26,  0x2A,  0x32,  0x22,  
  0x00,  0x10,  0x6C,  0x82,  0x82,  
  0x00,  0x00,  0xEE,  0x00,  0x00,  
  0x82,  0x82,  0x6C,  0x10,  0x00,  
  0x20,  0x40,  0x40,  0x40,  0x80,  
  0xA8,  0x68,  0x3E,  0x68,  0xA8,  
  0xBE,  0x2A,  0x2A,  0x2A,  0xA2,  
  0x00,  0x20,  0x50,  0xA0,  0x00,  
  0x04,  0x22,  0x7C,  0xA0,  0x40,  
  0x84,  0xFC,  0x04,  0x00,  0x20,  
  0xFE,  0x02,  0x02,  0x12,  0x02,  
  0x1C,  0x22,  0x14,  0x08,  0x36,  
  0x4E,  0x3E,  0x60,  0x40,  0x40,  
  0x0C,  0x12,  0x52,  0xB2,  0x1C,  
  0x08,  0x1C,  0x2A,  0x2A,  0x2A,  
  0xF8,  0x40,  0x40,  0x3C,  0x02,  
  0x7C,  0x92,  0x92,  0x7C,  0x00,  
  0x42,  0x44,  0x38,  0x04,  0x02,  
  0x20,  0x3E,  0x20,  0x3E,  0x22,  
  0x10,  0x20,  0x3C,  0x22,  0x20,  
  0x18,  0x24,  0x7E,  0x24,  0x18,  
  0x1C,  0x22,  0x0C,  0x22,  0x1C,  
  0x82,  0xC6,  0xAA,  0x92,  0x82,  
  0x3A,  0x46,  0x40,  0x46,  0x3A,  
  0x54,  0x54,  0x54,  0x54,  0x54,  
  0x44,  0x28,  0x10,  0x28,  0x44,  
  0x10,  0x10,  0x54,  0x10,  0x10,  
  0x00,  0x70,  0x88,  0x88,  0x70,  
  0x60,  0x90,  0x8A,  0x80,  0x40,  
  0xFE,  0xFE,  0x92,  0x92,  0x92,  
  0x0A,  0x1A,  0x2A,  0x4A,  0x8A,  
  0x8A,  0x4A,  0x2A,  0x1A,  0x0A,  
  0x28,  0x2C,  0x38,  0x68,  0x28,  
  0x04,  0xFE,  0x80,  0x80,  0x80,  
  0x4C,  0x92,  0x92,  0x7C,  0x00,  
  0x04,  0x02,  0x7C,  0x80,  0x40,  
  0x38,  0x44,  0x38,  0x44,  0x38,  
  0xAA,  0x54,  0xAA,  0x54,  0xAA,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x00,  0x00,  0xBE,  0x00,  0x00,  
  0x38,  0x44,  0xFE,  0x44,  0x00,  
  0x12,  0x7E,  0x92,  0x92,  0x42,  
  0xBA,  0x44,  0x44,  0x44,  0xBA,  
  0xA8,  0x68,  0x3E,  0x68,  0xA8,  
  0x00,  0x00,  0xEE,  0x00,  0x00,  
  0x50,  0xAA,  0xAA,  0xAA,  0x14,  
  0x00,  0x80,  0x00,  0x80,  0x00,  
  0x7C,  0xBA,  0xAA,  0xAA,  0x7C,  
  0x12,  0xAA,  0xAA,  0xAA,  0x7A,  
  0x10,  0x28,  0x54,  0xAA,  0x44,  
  0x80,  0x80,  0x80,  0x80,  0xC0,  
  0x00,  0x00,  0x00,  0x00,  0x00,  
  0x7C,  0xAA,  0xBA,  0x82,  0x7C,  
  0x80,  0x80,  0x80,  0x80,  0x80,  
  0x00,  0xE0,  0xA0,  0xE0,  0x00,  
  0x22,  0x22,  0xFA,  0x22,  0x22,  
  0x00,  0x48,  0x98,  0xA8,  0x48,  
  0x00,  0x00,  0xA8,  0xA8,  0x70,  
  0x00,  0x00,  0x40,  0x80,  0x00,  
  0x04,  0xF8,  0x10,  0x10,  0xE0,  
  0x60,  0xFE,  0x80,  0xFE,  0x80,  
  0x00,  0x00,  0x10,  0x10,  0x00,  
  0x08,  0x00,  0x02,  0x04,  0x00,  
  0x00,  0x48,  0xF8,  0x08,  0x00,  
  0x00,  0xE8,  0xA8,  0xE8,  0x00,  
  0x44,  0xAA,  0x54,  0x28,  0x10,  
  0xF0,  0x04,  0x0C,  0x14,  0x2E,  
  0xF0,  0x00,  0x12,  0x26,  0x1A,  
  0xFE,  0xFE,  0xFE,  0xFE,  0xFE,  
  0x0C,  0x12,  0xA2,  0x02,  0x04,  
  0x1E,  0xA8,  0x68,  0x28,  0x1E,  
  0x1E,  0x28,  0x68,  0xA8,  0x1E,  
  0x1E,  0xA8,  0xA8,  0xA8,  0x1E,  
  0x9E,  0xA8,  0xA8,  0xA8,  0x9E,  
  0x9E,  0x28,  0x28,  0x28,  0x9E,  
  0x1E,  0x68,  0xA8,  0x68,  0x1E,  
  0x7E,  0x90,  0xFE,  0x92,  0x92,  
  0x70,  0x8A,  0x8C,  0x88,  0x88,  
  0x3E,  0xAA,  0x6A,  0x2A,  0x22,  
  0x3E,  0x2A,  0x6A,  0xAA,  0x22,  
  0x3E,  0xAA,  0xAA,  0xAA,  0x22,  
  0xBE,  0x2A,  0x2A,  0x2A,  0xA2,  
  0x00,  0xA2,  0x7E,  0x22,  0x00,  
  0x00,  0x22,  0x7E,  0xA2,  0x00,  
  0x00,  0xA2,  0xBE,  0xA2,  0x00,  
  0x00,  0xA2,  0x3E,  0xA2,  0x00,  
  0x10,  0xFE,  0x92,  0x82,  0x7C,  
  0xBE,  0x90,  0x88,  0x84,  0xBE,  
  0x1C,  0xA2,  0x62,  0x22,  0x1C,  
  0x1C,  0x22,  0x62,  0xA2,  0x1C,  
  0x1C,  0xA2,  0xA2,  0xA2,  0x1C,  
  0x9C,  0xA2,  0xA2,  0xA2,  0x9C,  
  0x9C,  0x22,  0x22,  0x22,  0x9C,  
  0x44,  0x28,  0x10,  0x28,  0x44,  
  0x3A,  0x4C,  0x54,  0x64,  0xB8,  
  0x3C,  0x82,  0x42,  0x02,  0x3C,  
  0x3C,  0x02,  0x42,  0x82,  0x3C,  
  0x3C,  0x82,  0x82,  0x82,  0x3C,  
  0xBC,  0x02,  0x02,  0x02,  0xBC,  
  0x60,  0x10,  0x4E,  0x90,  0x60,  
  0xFE,  0x44,  0x44,  0x44,  0x38,  
  0x7E,  0xA4,  0xA4,  0x58,  0x00,  
  0x04,  0xAA,  0x6A,  0x2A,  0x1E,  
  0x04,  0x2A,  0x6A,  0xAA,  0x1E,  
  0x04,  0xAA,  0xAA,  0xAA,  0x1E,  
  0x84,  0xAA,  0xAA,  0xAA,  0x9E,  
  0x04,  0xAA,  0x2A,  0xAA,  0x1E,  
  0x04,  0x6A,  0xAA,  0x6A,  0x1E,  
  0x2E,  0x2A,  0x1C,  0x2A,  0x3A,  
  0x30,  0x4A,  0x4C,  0x48,  0x00,  
  0x1C,  0xAA,  0x6A,  0x2A,  0x1A,  
  0x1C,  0x2A,  0x6A,  0xAA,  0x1A,  
  0x1C,  0xAA,  0xAA,  0xAA,  0x1A,  
  0x1C,  0xAA,  0x2A,  0xAA,  0x1A,  
  0x00,  0x80,  0x5E,  0x00,  0x00,  
  0x00,  0x00,  0x5E,  0x80,  0x00,  
  0x00,  0x40,  0x5E,  0x40,  0x00,  
  0x00,  0x40,  0x1E,  0x40,  0x00,  
  0x0C,  0x12,  0x52,  0xB2,  0x1C,  
  0xBE,  0x90,  0xA0,  0xA0,  0x9E,  
  0x0C,  0x92,  0x52,  0x12,  0x0C,  
  0x0C,  0x12,  0x52,  0x92,  0x0C,  
  0x0C,  0x52,  0x52,  0x52,  0x0C,  
  0x4C,  0x52,  0x52,  0x52,  0x4C,  
  0x0C,  0x52,  0x12,  0x52,  0x0C,  
  0x10,  0x10,  0x10,  0x54,  0x10,  
  0x18,  0x26,  0x3C,  0x64,  0x18,  
  0x1C,  0x82,  0x42,  0x02,  0x1C,  
  0x1C,  0x02,  0x42,  0x82,  0x1C,  
  0x1C,  0x42,  0x42,  0x42,  0x1C,  
  0x1C,  0x42,  0x02,  0x42,  0x1C,  
  0x20,  0x12,  0x4C,  0x90,  0x20,  
  0xFE,  0x48,  0x48,  0x30,  0x00,  
  0x20,  0x92,  0x0C,  0x90,  0x20};

int column[] = {
  2, 3, 4, 5, 6};
int data = 7;
int clock =8;

int snelheid = 0;

void setup(){
  Serial.begin(9600);
  for (int i = 0; i < 5; i++){
    pinMode(column[i], OUTPUT);
  }
  for (int i = 0; i < 5; i++){
    digitalWrite(column[i], LOW);
  }
  pinMode(data, OUTPUT);
  pinMode(clock, OUTPUT);
  digitalWrite(data, LOW);
  digitalWrite(clock, HIGH);
}

void loop(){
  for (int asc = 32; asc< 256; asc++){      // all available ASCII
    for (int tijd = 0; tijd< 25; tijd++){   // 55 times same display, less is faster
      for (int i = 0; i < 5; i++){          // 5 columns
        for (int j = 0; j < 28; j++){       // 4 x 7 row-elements
          digitalWrite(clock, HIGH);
          digitalWrite(data, ascii_5x7[(-(j/7)+asc)*5+i] &(2<<(j%7))); // translate
          digitalWrite(clock, LOW);
        }
        digitalWrite(column[i], HIGH);
        delayMicroseconds(3000);
        digitalWrite(column[i], LOW);
      }
    }
  }
}

Inmiddels de tekstfunctie:
schrijfTekst(string, snelheid, helderheid)
gemaakt.
//*** HDSP200x
//*** ASCII-DEMO
//*** phuinink@gmail.com

const byte ascii_5x7[] = {
// 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
0x01, 0x02, 0x04, 0x08, 0x10,

0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0xF2, 0x00, 0x00,
0x00, 0xE0, 0x00, 0xE0, 0x00,
0x28, 0xFE, 0x28, 0xFE, 0x28,
0x24, 0x54, 0xFE, 0x54, 0x48,
0xC4, 0xC8, 0x10, 0x26, 0x46,
0x6C, 0x92, 0xAA, 0x44, 0x0A,
0x00, 0xA0, 0xC0, 0x00, 0x00,
0x00, 0x38, 0x44, 0x82, 0x00,
0x00, 0x82, 0x44, 0x38, 0x00,
0x28, 0x10, 0x7C, 0x10, 0x28,
0x10, 0x10, 0x7C, 0x10, 0x10,
0x00, 0x0A, 0x0C, 0x00, 0x00,
0x10, 0x10, 0x10, 0x10, 0x10,
0x00, 0x06, 0x06, 0x00, 0x00,
0x04, 0x08, 0x10, 0x20, 0x40,
0x7C, 0x8A, 0x92, 0xA2, 0x7C,
0x00, 0x42, 0xFE, 0x02, 0x00,
0x42, 0x86, 0x8A, 0x92, 0x62,
0x84, 0x82, 0xA2, 0xD2, 0x8C,
0x18, 0x28, 0x48, 0xFE, 0x08,
0xE4, 0xA2, 0xA2, 0xA2, 0x9C,
0x3C, 0x52, 0x92, 0x92, 0x0C,
0x80, 0x8E, 0x90, 0xA0, 0xC0,
0x6C, 0x92, 0x92, 0x92, 0x6C,
0x60, 0x92, 0x92, 0x94, 0x78,
0x00, 0x6C, 0x6C, 0x00, 0x00,
0x00, 0x6A, 0x6C, 0x00, 0x00,
0x10, 0x28, 0x44, 0x82, 0x00,
0x28, 0x28, 0x28, 0x28, 0x28,
0x00, 0x82, 0x44, 0x28, 0x10,
0x40, 0x80, 0x8A, 0x90, 0x60,
0x4C, 0x92, 0x9E, 0x82, 0x7C,
0x7E, 0x88, 0x88, 0x88, 0x7E,
0xFE, 0x92, 0x92, 0x92, 0x6C,
0x7C, 0x82, 0x82, 0x82, 0x44,
0xFE, 0x82, 0x82, 0x44, 0x38,
0xFE, 0x92, 0x92, 0x92, 0x82,
0xFE, 0x90, 0x90, 0x90, 0x80,
0x7C, 0x82, 0x92, 0x92, 0x5E,
0xFE, 0x10, 0x10, 0x10, 0xFE,
0x00, 0x82, 0xFE, 0x82, 0x00,
0x04, 0x02, 0x82, 0xFC, 0x80,
0xFE, 0x10, 0x28, 0x44, 0x82,
0xFE, 0x02, 0x02, 0x02, 0x02,
0xFE, 0x40, 0x30, 0x40, 0xFE,
0xFE, 0x20, 0x10, 0x08, 0xFE,
0x7C, 0x82, 0x82, 0x82, 0x7C,
0xFE, 0x90, 0x90, 0x90, 0x60,
0x7C, 0x82, 0x8A, 0x84, 0x7A,
0xFE, 0x90, 0x98, 0x94, 0x62,
0x62, 0x92, 0x92, 0x92, 0x8C,
0x80, 0x80, 0xFE, 0x80, 0x80,
0xFC, 0x02, 0x02, 0x02, 0xFC,
0xF8, 0x04, 0x02, 0x04, 0xF8,
0xFC, 0x02, 0x0C, 0x02, 0xFC,
0xC6, 0x28, 0x10, 0x28, 0xC6,
0xE0, 0x10, 0x0E, 0x10, 0xE0,
0x86, 0x8A, 0x92, 0xA2, 0xC2,
0x00, 0xFE, 0x82, 0x82, 0x00,
0x40, 0x20, 0x10, 0x08, 0x04,
0x00, 0x82, 0x82, 0xFE, 0x00,
0x20, 0x40, 0x80, 0x40, 0x20,
0x02, 0x02, 0x02, 0x02, 0x02,
0x00, 0x80, 0x40, 0x20, 0x00,
0x04, 0x2A, 0x2A, 0x2A, 0x1E,
0xFE, 0x12, 0x12, 0x12, 0x0C,
0x1C, 0x22, 0x22, 0x22, 0x22,
0x0C, 0x12, 0x12, 0x12, 0xFE,
0x1C, 0x2A, 0x2A, 0x2A, 0x1A,
0x00, 0x10, 0x7E, 0x90, 0x40,
0x12, 0x2A, 0x2A, 0x2A, 0x3C,
0xFE, 0x10, 0x10, 0x10, 0x0E,
0x00, 0x00, 0x5E, 0x00, 0x00,
0x04, 0x02, 0x02, 0xBC, 0x00,
0x00, 0xFE, 0x08, 0x14, 0x22,
0x00, 0x82, 0xFE, 0x02, 0x00,
0x3E, 0x20, 0x1C, 0x20, 0x3E,
0x3E, 0x10, 0x20, 0x20, 0x1E,
0x1C, 0x22, 0x22, 0x22, 0x1C,
0x3E, 0x28, 0x28, 0x28, 0x10,
0x10, 0x28, 0x28, 0x28, 0x3E,
0x3E, 0x10, 0x20, 0x20, 0x10,
0x12, 0x2A, 0x2A, 0x2A, 0x24,
0x20, 0x20, 0xFC, 0x22, 0x24,
0x3C, 0x02, 0x02, 0x02, 0x3C,
0x38, 0x04, 0x02, 0x04, 0x38,
0x3C, 0x02, 0x0C, 0x02, 0x3C,
0x22, 0x14, 0x08, 0x14, 0x22,
0x20, 0x12, 0x0C, 0x10, 0x20,
0x22, 0x26, 0x2A, 0x32, 0x22,
0x00, 0x10, 0x6C, 0x82, 0x82,
0x00, 0x00, 0xEE, 0x00, 0x00,
0x82, 0x82, 0x6C, 0x10, 0x00,
0x20, 0x40, 0x40, 0x40, 0x80,
0xA8, 0x68, 0x3E, 0x68, 0xA8,
0xBE, 0x2A, 0x2A, 0x2A, 0xA2,
0x00, 0x20, 0x50, 0xA0, 0x00,
0x04, 0x22, 0x7C, 0xA0, 0x40,
0x84, 0xFC, 0x04, 0x00, 0x20,
0xFE, 0x02, 0x02, 0x12, 0x02,
0x1C, 0x22, 0x14, 0x08, 0x36,
0x4E, 0x3E, 0x60, 0x40, 0x40,
0x0C, 0x12, 0x52, 0xB2, 0x1C,
0x08, 0x1C, 0x2A, 0x2A, 0x2A,
0xF8, 0x40, 0x40, 0x3C, 0x02,
0x7C, 0x92, 0x92, 0x7C, 0x00,
0x42, 0x44, 0x38, 0x04, 0x02,
0x20, 0x3E, 0x20, 0x3E, 0x22,
0x10, 0x20, 0x3C, 0x22, 0x20,
0x18, 0x24, 0x7E, 0x24, 0x18,
0x1C, 0x22, 0x0C, 0x22, 0x1C,
0x82, 0xC6, 0xAA, 0x92, 0x82,
0x3A, 0x46, 0x40, 0x46, 0x3A,
0x54, 0x54, 0x54, 0x54, 0x54,
0x44, 0x28, 0x10, 0x28, 0x44,
0x10, 0x10, 0x54, 0x10, 0x10,
0x00, 0x70, 0x88, 0x88, 0x70,
0x60, 0x90, 0x8A, 0x80, 0x40,
0xFE, 0xFE, 0x92, 0x92, 0x92,
0x0A, 0x1A, 0x2A, 0x4A, 0x8A,
0x8A, 0x4A, 0x2A, 0x1A, 0x0A,
0x28, 0x2C, 0x38, 0x68, 0x28,
0x04, 0xFE, 0x80, 0x80, 0x80,
0x4C, 0x92, 0x92, 0x7C, 0x00,
0x04, 0x02, 0x7C, 0x80, 0x40,
0x38, 0x44, 0x38, 0x44, 0x38,
0xAA, 0x54, 0xAA, 0x54, 0xAA,
0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0xBE, 0x00, 0x00,
0x38, 0x44, 0xFE, 0x44, 0x00,
0x12, 0x7E, 0x92, 0x92, 0x42,
0xBA, 0x44, 0x44, 0x44, 0xBA,
0xA8, 0x68, 0x3E, 0x68, 0xA8,
0x00, 0x00, 0xEE, 0x00, 0x00,
0x50, 0xAA, 0xAA, 0xAA, 0x14,
0x00, 0x80, 0x00, 0x80, 0x00,
0x7C, 0xBA, 0xAA, 0xAA, 0x7C,
0x12, 0xAA, 0xAA, 0xAA, 0x7A,
0x10, 0x28, 0x54, 0xAA, 0x44,
0x80, 0x80, 0x80, 0x80, 0xC0,
0x00, 0x00, 0x00, 0x00, 0x00,
0x7C, 0xAA, 0xBA, 0x82, 0x7C,
0x80, 0x80, 0x80, 0x80, 0x80,
0x00, 0xE0, 0xA0, 0xE0, 0x00,
0x22, 0x22, 0xFA, 0x22, 0x22,
0x00, 0x48, 0x98, 0xA8, 0x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x20, 0x12, 0x4C, 0x90, 0x20,
0xFE, 0x48, 0x48, 0x30, 0x00,
0x20, 0x92, 0x0C, 0x90, 0x20};

int column[] = {
2, 3, 4, 5, 6};
int data = 7;
int clock =8;

void setup(){
Serial.begin(9600);
for (int i = 0; i < 5; i++){
pinMode(column[i], OUTPUT);
}
for (int i = 0; i < 5; i++){
digitalWrite(column[i], LOW);
}
pinMode(data, OUTPUT);
pinMode(clock, OUTPUT);
digitalWrite(data, LOW);
digitalWrite(clock, HIGH);
}

void loop(){
schrijfTekst(" -hallo + ", 15, 2500); // alway precede with 4 spaces of 'garbage'. These will be cut off
}

void schrijfTekst(String tekst, int snelheid, int helderheid){
int tl = tekst.length();
int tekstDat[tl*5];
char tekst_[tl];
for (int vv = 0; vv < tl; vv++){
char tt = tekst.charAt(vv);
for (int i =0; i< 5;i++){
tekstDat[vv*5+i] = ascii_5x7[tt*5+i];
}
}
for (int asc = 4; asc< tl; asc++){ // all available ASCII
for (int tijd = 0; tijd < snelheid; tijd++){ // 'snelheid'-times same display, less is faster

for (int i = 0; i < 5; i++){ // 5 columns
int duur=0;
for (int j = 0; j < 28; j++){ // 4 x 7 row-elements
digitalWrite(clock, HIGH);
digitalWrite(data, tekstDat[(-(j/7)+asc)*5+i] &(2<<(j%7))); // translate
digitalWrite(clock, LOW);
}
digitalWrite(column[i], HIGH);
delayMicroseconds(helderheid);
digitalWrite(column[i], LOW);
}
}
//}
}
}

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>