Comments (2)
You are correct in that sending 0x20
will put the display in horizontal addressing mode and 0x22
in vertical mode. 0x20
is the function set register and 0x02
is the bit that switches to vertical mode.
When switching mode, it does not affect what is currently on the display. It only affects where the next byte will be drawn.
The pcd8544_buffer
in the library is storing the image in horizontal mode and display()
loops over the 6 pages (each 8 rows tall) and writes up to 84 bytes (one per column) before moving to the next page. Each byte represents 8 vertical pixels. Partial updates is why they don't just set the x,y address to 0,0 and spi write the entire buffer.
I don't believe there are any cheap clones of the display. I've seen the same LCD wrapped in the same metal case on various coloured PCBs from various vendors. They have subtle differences in their backlight LEDs but are otherwise seemingly identical.
If you want to see the horizontal / vertical addressing in action, try setting the x,y position to 0,0 then spi writing a single byte 0xff
, pause and repeat. In both modes, each write will draw 8 vertical pixels. It's not possible to draw a row of 8 horizontal pixels from a single byte. They are always drawn vertical.
from adafruit-pcd8544-nokia-5110-lcd-library.
closing cause it seems to work?
from adafruit-pcd8544-nokia-5110-lcd-library.
Related Issues (20)
- Using with "Hardware" SPI pins and SD/EthernetShield is not possible HOT 3
- missing #ifndef in header can cause compilation trouble HOT 1
- ESP8266 support HOT 24
- Print HOT 4
- Enhancement - move whole display HOT 1
- PCBD8544 Nokia 5110 library not working in SAMD21 architecture (Arduino Zero) HOT 7
- Display only 13 characters instead of 14 on 1 line HOT 2
- SPI transaction switching required HOT 1
- Issue using library with Arduino 101 HOT 2
- Where to get font sign size in pixels to locate the sign in the middle of the screen? HOT 1
- Is there a list of the display classes for this library? HOT 1
- Lattepanda with leonardo arduino. HOT 2
- Pin 11 and 13 Changes? HOT 1
- Is this library is not maintained anymore? HOT 2
- Temperature Coefficient
- Teensy 3.0 and above support is needed HOT 5
- Garbage on screen when drawing circles that are partially outside display HOT 7
- Compile error: HOT 1
- Rotated screen only displays 6 rows, not 12? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from adafruit-pcd8544-nokia-5110-lcd-library.