Revient a la config OLED d'origine (20MHz, delais 10ms)
Le probleme d'affichage etait une panne materielle du module OLED (probablement du a l'alimentation en 5V testee au debut, hors specs VDDIO du SSD1322), confirmee par le remplacement du module. Les contournements logiciels ajoutes pendant le debug n'etaient pas necessaires. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01StKu9rqrsdz8CAVt1XMxon
This commit is contained in:
@ -177,19 +177,14 @@ void er_oled_begin() {
|
|||||||
|
|
||||||
// Broches SPI personnalisees : sck, miso (non cable), mosi, ss
|
// Broches SPI personnalisees : sck, miso (non cable), mosi, ss
|
||||||
SPI.begin(PIN_OLED_CLK, -1, PIN_OLED_MOSI, PIN_OLED_CS);
|
SPI.begin(PIN_OLED_CLK, -1, PIN_OLED_MOSI, PIN_OLED_CS);
|
||||||
// 400kHz : vitesse max demandee pour fiabiliser le signal sur cable ruban IDC.
|
SPI.beginTransaction(SPISettings(20000000, MSBFIRST, SPI_MODE0));
|
||||||
SPI.beginTransaction(SPISettings(400000, MSBFIRST, SPI_MODE0));
|
|
||||||
|
|
||||||
// Comme dans le firmware MSP430 fonctionnel de reference : /CS n'est PAS
|
digitalWrite(PIN_OLED_CS, LOW);
|
||||||
// force a LOW avant l'impulsion de reset (seul oled_command/oled_data le
|
|
||||||
// pilotent, par octet).
|
|
||||||
digitalWrite(PIN_OLED_RST, HIGH);
|
digitalWrite(PIN_OLED_RST, HIGH);
|
||||||
|
delay(10);
|
||||||
delay(100);
|
|
||||||
digitalWrite(PIN_OLED_RST, LOW);
|
digitalWrite(PIN_OLED_RST, LOW);
|
||||||
delay(100);
|
delay(10);
|
||||||
digitalWrite(PIN_OLED_RST, HIGH);
|
digitalWrite(PIN_OLED_RST, HIGH);
|
||||||
delay(100);
|
|
||||||
|
|
||||||
oled_command(0xFD); // set command lock
|
oled_command(0xFD); // set command lock
|
||||||
oled_data(0x12); // unlock
|
oled_data(0x12); // unlock
|
||||||
|
|||||||
Reference in New Issue
Block a user