0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

STM32G071とSSD1306に豆腐を召喚する(スペルは、「40-FF」...)

Last updated at Posted at 2022-09-18

x OLED096UNO-Aです。
x NUCLEO-G071RB

目的
OLEDのテスト

o_con777.jpg

o_con778.jpg

これでアカデミーは、強制卒業です。
僕の考えた最強のなになにを作ってください。




//ssd1306_int_071_1

#include <Arduino.h>
#include <Wire.h>

void write_s(uint8_t *str1, uint8_t len1) {

  Wire.beginTransmission(   0x3c  );

  for (int ii = 0; ii < len1; ii++) {

    //一文字出力
    Wire.write(*str1 ++);

  }//for

  Wire.endTransmission();

}//eeprom_write_s

//初期化
void setup() {

  //I2Cの初期化
  Wire.begin(); //071
  delay(200);

  //0x80,0x8d,0x80,0x14,0x80,0xAF
  write_s( (uint8_t*) "\200\215\200\024\200\257", 6);
  delay(100);

#define DATA_MODE                  0x40

    uint8_t databytes[2] = {DATA_MODE,0xFF};
    for (int icount = 0; icount < 8; icount++) {
        write_s(databytes, 2);
    }//for


}//setup

//無限ループ
void loop() {
}//loop





0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?