Newhaven Products > OLEDs

NHD-0216CW-AB3 and an Arduino Micro

<< < (2/2)

The Fat Bastid:
The change is to the data and command fucntions:

--- Code: ---void command(unsigned char c){  //To send commands
  PORTB = c;                   //command on port
  digitalWrite(DC, LOW);

void data(unsigned char d){    //To send data
  PORTB = d;                  //data on port
  digitalWrite(DC, HIGH);
--- End code ---

in my original code you can see that it was all port manipulation, now it is a combination of ports and digitalwrites


[0] Message Index

[*] Previous page

Go to full version