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

How to add more types of screens ? #97

Closed
markbirss opened this issue Dec 26, 2019 · 7 comments
Closed

How to add more types of screens ? #97

markbirss opened this issue Dec 26, 2019 · 7 comments
Labels

Comments

@markbirss
Copy link

How do i add for example the ST7920 oled screen ?

@thijstriemstra
Copy link
Collaborator

Very generic question, can you be more specific?

@markbirss
Copy link
Author

sure, currently the ST7920 oled screen is unsupported, what changes are required to add support for this screen

@rm-hull
Copy link
Owner

rm-hull commented Dec 26, 2019

ST7920 is an LCD screen rather than OLED.

You would need to find the datasheet for the device, read it and understand how to send data to the display (whether that is via I2C, SPI or parallel bIt-banging). Then use one of the other implementations as a guide, implement a class that extends device (see https://luma-oled.readthedocs.io/en/latest/api-documentation.html) where its display() method takes a pillow image and converts the pixels to the correct commands and data for device

@rm-hull rm-hull transferred this issue from rm-hull/luma.examples Dec 26, 2019
@rm-hull
Copy link
Owner

rm-hull commented Dec 26, 2019

Moving to luma.lcd ....

@markbirss
Copy link
Author

Ok, understood, thank you for your feedback

I will close the issue but leave these notes below

I have found much of that information but, I dont have the depth of understanding at the moment to put it into a implementation.

Will leave it here if anyone else interested.

Datasheet
https://www.lcd-module.de/eng/pdf/zubehoer/st7920_chinese.pdf

Enable SPI mode is simply done by connecting PSB to GND
Enable Parallel mode by connecting PSB to 5V

How th screen works
https://www.instructables.com/id/The-Secrets-of-an-Inexpensive-Ubiquitous-Chinese-L/

U8G2 ports
https://github.com/ribasco/u8g2-rpi-demo

https://github.com/olikraus/u8g2

@rm-hull
Copy link
Owner

rm-hull commented Dec 26, 2019

Related issue: #46
Related PR: #98

@rm-hull
Copy link
Owner

rm-hull commented Dec 26, 2019

I think the PR for this stalled because driving it via parallel bit-banging was going to be awkward.
If this is true:

Enable SPI mode is simply done by connecting PSB to GND

then it might be straightforward to getting it working

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

No branches or pull requests

3 participants