adafruit OLED-Display do not want showing my data.

avoid

New Member
i try to get an "SSD1306 0.96" 128x64 OLED" display from adafruit works with an PICAXE.

the thread (http://www.picaxeforum.co.uk/showthread.php?23134-Aggravating-OLED-display)
was an help to get the right i2c adress and initialize to see anything on it.

but it seems that only the commands work.
it reacts not to data.

what can i do?

that's my example code.
Code:
#PICAXE 20M2
setfreq M32
dirsC=%11111101           ;make C.1 input(C.1 is decay mode)
outpinsC=%00001000        ;disable the stepper driver and stay here
pause 1000

symbol DispCommand 	= 0x80
symbol DispData		= 0x40 ; is this right?

;from adafruit header file
symbol CLOCKDIV 		= 0xB3
symbol CONTRASTA 		= 0x81
symbol CONTRASTB 		= 0x82
symbol CONTRASTC		= 0x83
symbol DISPLAYALLON  	= 0xA5
symbol DISPLAYOFF   	= 0xAE
symbol DISPLAYON     	= 0xAF
symbol DRAWLINE 		= 0x21
symbol DRAWRECT 		= 0x22
symbol FILL       		= 0x26
symbol INVERTDISPLAY 	= 0xA7
symbol MASTERCURRENT 	= 0x87
symbol POWERMODE 		= 0xB0
symbol PRECHARGE 		= 0xB1
symbol PRECHARGEA  	= 0x8A
symbol PRECHARGEB  	= 0x8B
symbol PRECHARGEC  	= 0x8C
symbol PRECHARGELEVEL 	= 0xBB
symbol SETCOLUMN	 	= 0x15
symbol SETMASTER 		= 0xAD
symbol SETMULTIPLEX  	= 0xA8
symbol SETREMAP 		= 0xA0
symbol SETROW    		= 0x75

;from datasheet
symbol DISPLAYOFFSET      	= 0xD3 ;0xA2 ?
symbol SETOSZILLATOR     	= 0xD5
symbol SETSTARTLINE        	= 0xA1 ;0x40 ?
symbol SETCHARGEPUMP    	= 0x8D
symbol SETCOMSCANOUTPUT	= 0xC8
symbol SETCOMPINS  		= 0xDA
symbol SETCHARGEPERIOD 	= 0xD9
symbol VCOMH           		= 0xDB ;0xBE ?
symbol NORMALDISPLAY     	= 0xA6
symbol ENTIREDISPLAYON  	= 0xA4
symbol SETCLEAR      	 	= 0x25

init:
hi2csetup i2cmaster,%01111000,i2cfast_32,i2cbyte ; init the i2c mode with display adress

hi2cout DispCommand,(DISPLAYOFF,SETCOLUMN,0x00,SETROW,0x00,POWERMODE,SETOSZILLATOR,0x80,SETMULTIPLEX,0x3F, _
DISPLAYOFFSET,0x00,SETSTARTLINE,SETCHARGEPUMP,0x14,SETREMAP,0x00,SETCOMSCANOUTPUT,SETCOMPINS,0x02, _
CONTRASTA,0xCF,SETCHARGEPERIOD,0xF1,VCOMH,0x30,ENTIREDISPLAYON,NORMALDISPLAY,SETCLEAR,0x00,0xFF,DISPLAYON)

#rem
hi2cout DispCommand,(DISPLAYOFF)		;turn off display(RESET=OFF)
hi2cout DispCommand,(SETCOLUMN,0x00)	;low column nibble(RESET=0),high column nibble(RESET=0)
hi2cout DispCommand,(SETROW,0x00)		;set row ?
hi2cout DispCommand,(POWERMODE)		;power saveing ?
hi2cout DispCommand,(SETOSZILLATOR,0x80)	;oscillator frequency and divider(RESET=80)00
hi2cout DispCommand,(SETMULTIPLEX,0x3F)	;mux ratio(RESET=3F [64 lines])
hi2cout DispCommand,(DISPLAYOFFSET,0x00)	;display offset,COM vertical shift(RESET=0)
hi2cout DispCommand,(SETSTARTLINE)		;Set Display Startline
hi2cout DispCommand,(SETCHARGEPUMP,0x14)	;enable charge pump(RESET=10 [OFF])
hi2cout DispCommand,(SETREMAP,0x00)		;segment remap(RESET=SEG0, COL0) 00 mirror image
hi2cout DispCommand,(SETCOMSCANOUTPUT)	;COM output scan(RESET=C0, C8 flips display)
hi2cout DispCommand,(SETCOMPINS,0x02)	;COM pins hardware config(RESET=12[alternate])
hi2cout DispCommand,(CONTRASTA,0xCF)	;contrast CF(RESET=7F)
hi2cout DispCommand,(SETCHARGEPERIOD,0xF1);pre-charge period F1(RESET=22)
hi2cout DispCommand,(VCOMH,0x30)		;Vcom deselect(RESET=20)
hi2cout DispCommand,(ENTIREDISPLAYON)	;turn all on ignore RAM A5/RAM A4(RESET=A4)
hi2cout DispCommand,(NORMALDISPLAY)		;normal display A6/inverted A7(RESET=A6)
hi2cout DispCommand,(SETCLEAR,0x00,0xFF)	;clear data RAM ????
hi2cout DispCommand,(DISPLAYON)		;turn on display
#endrem

main:
hi2cout DispData,( _
0xFF, 0xFF, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, _
0x03, 0x03, 0xFB, 0xFB, 0x03, 0x03, 0x03, 0x03, 0xFB, 0xFB, 0x03, 0x03, 0x03, 0x03, 0xFB, 0xFB, _
0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, _
0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0xFF, _
0xFF, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, _
0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, _
0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, _
0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0xFF, 0xFF, _
0xFF, 0xFF, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, _
0x80, 0x80, 0xBF, 0xBF, 0xB0, 0xB0, 0xB0, 0xB0, 0xBF, 0xBF, 0x80, 0x80, 0x80, 0x80, 0xBF, 0xBF, _
0xB0, 0xB0, 0xB0, 0xB0, 0xB0, 0xB0, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, _
0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0xFF, _
0xFF, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, _
0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, _
0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, _
0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0xFF, 0xFF, _
0xFF, 0xFF, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, _
0x01, 0x01, 0xFD, 0xFD, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0xFD, 0xFD, _
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, _
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0xFF, _
0xFF, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, _
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, _
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, _
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0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