[i:59f2491aa5][b:59f2491aa5]glcdSSD1306.lib[/b:59f2491aa5][/i:59f2491aa5] not work on Xmega. CPU hangs. In this example even LED flash not work.
[code:1:59f2491aa5]$regfile = "xm256a3budef.dat"
$crystal = 32000000
$hwstack = 100
$swstack = 100
$framesize = 100
Config Osc = Disabled , 32mhzosc = Enabled
Config Sysclock = 32mhz , Prescalea = 1 , Prescalebc = 1_1
Dim Count As Byte
Led Alias Portd.2 : Config Portd.2 = Output
Dim Twi_start As Byte
Config Twic = 400000
I2cinit
$lib "glcdSSD1306.lib"
'************************** Here LED flashes
For Count = 1 To 8
Toggle Led
Waitms 300
Next Count
'************************** After this string CPU hangs
Config Graphlcd = Custom , Cols = 128 , Rows = 64 , Lcdname = "SSD1306"
'************************** Here LED not flashes
Do
Toggle Led
Waitms 100
Loop
End[/code:1:59f2491aa5]
↧