Coder Social home page Coder Social logo

ssd1306's Introduction

SSD1306 OLED Display Driver Support

This library adds support for the Solomon Systech SSD1306 OLED display driver to Mongoose OS.

The default configuration and PIN mapping supports ESP32 boards with the driver hard-wired for I2C communication via GPIO pins 4 and 5. It should work on other platforms, but has not yet been tested.

This driver should support displays of any resolution supported by the SSD1306.

This driver does not yet support SPI operation.

It uses a 64x48 panel with column offset of 32, correct configuration for it is as follows:

config_schema:
  - ["i2c.enable", true]
  - ["i2c.sda_gpio", 4]
  - ["i2c.scl_gpio", 5]
  - ["ssd1306.i2c.enable", false]  # Use system bus.
  - ["ssd1306.enable", true]
  - ["ssd1306.width", 64]
  - ["ssd1306.height", 48]
  - ["ssd1306.col_offset", 32]

MakerHawk I2C OLED Display Module 0.91 Inch 128X32

config_schema:
  - ["ssd1306.width", 128]
  - ["ssd1306.height", 32]
  - ["ssd1306.com_pins", 0x02]

ssd1306's People

Contributors

brandond avatar cmumford avatar cpq avatar dvv avatar mamuesp avatar rojer avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

ssd1306's Issues

It there any plan to support js api?

MongooseOS is wonderful, mjs is very sweet, the only pity is mjs can't use many useful libraries directly.

According to the document, it is possible writing wrapper to use struct argument C functions, but I have to say it too hard for normal users...

Library logs every written character on LL_INFO

When displaying text, there is a log message on loglevel INFO for each single character. If needed this should be done on LL_TRACE or maybe LL_DEBUG. Logging this on LL_INFO
appears to be a bug.

This issue is solved by #3 and #6

SPI support

Hello,
i have board that only has SPI connection to SSD1306 and i cannot change the hardware. Can you please add possibility to use SPI interface as well?

FFI error on drawString function

I get an error when call drawString function.
As far as I understood, the function should return _drawString instead of _drawStringColor.

drawString: function(x, y, txt) {
return this._drawStringColor(this._oled, x, y, txt);
},

COM pins configuration for 128x32 0.91" OLED display

If you are using a 128x32 0.91" OLED display, you have to set the com_pins configuration to be 0x02. With the default value of 0x12, the output on the display is compressed.

config_schema:
- ["ssd1306.com_pins", "i", 0x02, {title: "Screen COM pins configuration, depends on physical attachemnt of the panel to the chip; 0x02, 0x12, 0x22 or 0x32 are valid values"}]

Can you add a note to the README?

Example ?

Hi,
Can you rpovide a simple example on how to use this library ?
I know that you can get it from reading actuall code but would be great to have somethin in repository

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.