Hardware scrolling, X-Axis

On my Journey for undocumented features of the ssd1306 i examined the scolling commands, and because i was asked if i found something:

what i found:
you wanted to scroll on the x axis:

it is documented in the ssd1306b datasheet

this scrolls the screen by one pixel left, unfortunatly it takes 2 frames until the scroll happens (this seems to be quick with mux=1):
void GfxApiSetDisplayScroll (u8 brightness)
const u8 init1306={
os_i2c_write(init1306, sizeof(init1306));

changing the reserved “1” to 0 makes the scroll continous, keeping it at 1 makes it scroll out.

it is documented in the SSD1306B datasheet.
SSD1306B_1.1_(To Winstar) (midasdisplays.com)

also the normal scrolling commands have two undocumented parameters, the two last one, these define the xstart and xend of the scroll window, so it is possible to scroll a central area, or keep a central area out of the scroll. this works on all my displays.

also this datasheet documents two more valid settings for the charge pump, the voltage can be increase further, this seems to compensate for dark images because of mux tricks.


Great stuff! Hope I can get a chance to play with this! :smiley:

Could you give some more detail?

they are documented in the ssd1306B datasheet, but work on all my displays:

parameter E is Start of window, F is end of window

these parameters are undocumented in the ssd1306 datasheet, but documented in ssd1306b, ssd1306 states E must be smaller than F, but it works with E bigger than f:

the dummy byte A also does something but i do not know yet,if somebody finds out i would be happy to know

and the single pixel scroll commands:

if you set the second dummy byte to 0 the scrolled in pixels will wrap arround instead of beeing cleared to black

setting the first dummy byte also seems to do something but i have not found out yet what it does.

1 Like

and the single pixel commands, these scroll 1 pixel left or right, somewhere they “happen” after the second retrace, but the datasheet is inconclusive, so it might be they happen within the frame…if you find out please tell me… i tested it and it happens very fast with mux=1 (not yet tested with mux=0)

the datasheet specifies a usage procedure scrolling over a large image:

and there is one more undocumented command on my “normal” ssd1306 (the one without “new”, which does not understand the grayscale mode command but can (both can) do grayscale by mux:0 zoom:1 mux 63 every frame) : 0xd8, it causes a slight brighness variation, so i guess it is not intresting. i also examinded the blink command but could not find anything, and well it looks shitty anyway.

1 Like

That command and fade looked really interesting…

it stays on pretty long fading a bit, then goes out very fast, and on very fast then slowly goes to max and repeat…
the brightness range of contrast 0x81 can be enhanced: by 0xd9, [brightness 0-15], and 0xdb [brightness 0-7], this gives a huge range for fading.

I am doing more tests:

this is the content scroll command and the driver code (the esp32 version works again):

At mux = 1 i can scroll the screen at enormous speeds, i guess it should be possible to move all screen rows where one wants them to be by scrolling them in the “retrace” = while at mux=1 .on my display it does not scroll at mux=0, my both displays seem to handle mux=0 differently, but the behaviour for mux=1 is identical.

void GfxApiSetDisplayScroll (u8 brightness)
const u8 init1306[]={
os_i2c_write(init1306, sizeof(init1306));

(vsync flag is set by irq at 60hz)

and the first dummy byte has no effect on my “old” (and probably “normal” ssd1306)…

the scroll supports more modes (in this test i draw the image then scroll it 8 right every time…)

at least one can select the incoming pixel to loop, repeat, or to be black, white