128x32 SPI SSD1306 compatible Display only works if GND is removed


hello,

i have got strange issue, hope can me.

short description:

after "reset" of arduino dispaly stops working until remove gnd, reset arduino , after 1 sec plug in gnd gnd pin.

first data:
display:
http://m.ebay.com/itm/spi-0-91-quot-128x32-white-oled-lcd-display-module-avr-pic-for-arduino-dc-3-3-5v-/201493774341?txnid=1334271167010

and arduino nano.

the library sample , modified test working:

my modified hardware spi test code:
code: [select]


#include <spi.h>
#include <wire.h>
#include <adafruit_gfx.h>
#include <adafruit_ssd1306.h>


/*
// if using software spi (the default case):
#define oled_mosi   9
#define oled_clk   10
#define oled_dc    11
#define oled_cs    12
#define oled_reset 13
adafruit_ssd1306 display(oled_mosi, oled_clk, oled_dc, oled_reset, oled_cs);
*/

// uncomment block use hardware spi
#define oled_dc     6
#define oled_cs     7
#define oled_reset  8
adafruit_ssd1306 display(oled_dc, oled_reset, oled_cs);

#define xpos 0
#define ypos 1
#define deltay 2

#define logo16_glcd_height 16
#define logo16_glcd_width  16
static const unsigned char progmem logo16_glcd_bmp[] =
{ b00000000, b11000000,
  b00000001, b11000000,
  b00000001, b11000000,
  b00000011, b11100000,
  b11110011, b11100000,
  b11111110, b11111000,
  b01111110, b11111111,
  b00110011, b10011111,
  b00011111, b11111100,
  b00001101, b01110000,
  b00011011, b10100000,
  b00111111, b11100000,
  b00111111, b11110000,
  b01111100, b11110000,
  b01110000, b01110000,
  b00000000, b00110000 };

#if (ssd1306_lcdheight != 32)
#error("height incorrect, please fix adafruit_ssd1306.h!");
#endif


void setup() {
  serial.begin(9600);
 
  // default, we'll generate high voltage 3.3v line internally! (neat!)
  display.begin(ssd1306_switchcapvcc);
  // init done
 
  // show image buffer on display hardware.
  // since buffer intialized adafruit splashscreen
  // internally, display splashscreen.
  display.display();
  delay(2000);

  // clear buffer.
  display.cleardisplay();

  // draw single pixel
  display.drawpixel(10, 10, white);
  // show display buffer on hardware.
  // note: _must_ call display after making drawing commands
  // make them visible on display hardware!
  display.display();
  delay(2000);
  display.cleardisplay();


 

}

void loop() {
  // put main code here, run repeatedly:
  display.cleardisplay();

  display.settextsize(1);
  display.settextcolor(white);
  display.setcursor(0,0);
  display.println("hello, hardwareworld!");
  display.display();
  delay(2000);
  display.cleardisplay();

}




i have got issue hardware , software spi don't think code related.

my display not have got rst pin, can related this? there solution this?

thanks in advance!

the display needs driven 3.3v logic levels. use logic level converter or resistors drop voltage. alternatively run nano off 3.3v


Arduino Forum > Using Arduino > Displays > 128x32 SPI SSD1306 compatible Display only works if GND is removed


arduino

Comments

Popular posts from this blog

Error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode - Raspberry Pi Forums

class MPU6050 has no member named begin

missing filename after '-o'