Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The library stop working after 5-7 min #6

Open
konsmac opened this issue Jan 14, 2025 · 1 comment
Open

The library stop working after 5-7 min #6

konsmac opened this issue Jan 14, 2025 · 1 comment

Comments

@konsmac
Copy link

konsmac commented Jan 14, 2025

Hi!
I'm trying to use this library on Arduino nano.
I started with the text example that comes with the SH1106Lib library.
The only thing I changed, I created a variable char foo[] = {"375 Hello World"}; , and I'm printing this variable
Everything works fine for 5-7 min, and then the text gets partly printed on the display and the display stops updating.

The complete code is:
`/*

// config for softwareI2Cmaster lib
#define I2C_HARDWARE 1
#define I2C_TIMEOUT 10
#define I2C_MAXWAIT 10
#define I2C_PULLUP 1
#define I2C_FASTMODE 1
#define SDA_PORT PORTC
#define SDA_PIN 4 // = A4
#define SCL_PORT PORTC
#define SCL_PIN 5 // = A5

// config for tinyprint lib
#define TP_PRINTLINES 0
#define TP_FLASHSTRINGHELPER 1
#define TP_NUMBERS 0
#define TP_FLOAT 0
#define TP_WINDOWSLINEENDS 0

#include <SH1106Lib.h>
#include "glcdfont.h"

SH1106Lib display;

int notst = "345";

char foo[] = {"375 Hello World"};

void setup() {
display.initialize();
display.clearDisplay();

display.setFont(font, 5, 7);
display.setTextWrap(true);
display.setTextColor(WHITE, BLACK);

}

void loop() {
display.setCursor(0, 0);
display.print((foo));

delay(1000);
display.clearDisplay();

}`

@konsmac
Copy link
Author

konsmac commented Jan 14, 2025

p.s. obviously, the display is SH1106 and it works correctly for the first 5 min, or slightly more time

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant