关于SSD1327Z 驱动

2019-07-21 05:57发布

请问有谁用过SSD1327Z这款驱动IC的OLED吗?
我这边使用厂商的初始化源码没有点亮。有什么要注意的吗?
使用STM32103C8的模拟SPI驱动

_Write_CommandCmd(0xAE);

_Write_CommandCmd(0x15); // Set column address
_Write_CommandCmd(0x00); // Start column 0
_Write_CommandCmd(0x3f); // End column 127
_Write_CommandCmd(0x75); // Set row address
_Write_CommandCmd(0x00); // Start row 0
_Write_CommandCmd(0x7f); // End row 127

_Write_CommandCmd(0x81); // Set contrast control
_Write_CommandCmd(0x80);
_Write_CommandCmd(0xa0); // Segment remap
_Write_CommandCmd(0x51);
_Write_CommandCmd(0xa1); // Start line
_Write_CommandCmd(0x00);
_Write_CommandCmd(0xa2); // Display offset
_Write_CommandCmd(0x00);
_Write_CommandCmd(0xa4); // Normal display
_Write_CommandCmd(0xa8); // Set multiplex ratio
_Write_CommandCmd(0x7f);
_Write_CommandCmd(0xb1); // Set phase length
_Write_CommandCmd(0xf1);
_Write_CommandCmd(0xb3); // Set dclk
_Write_CommandCmd(0x00); // 80Hz:0xc1 90Hz:0xe1 100Hz:0x00 110Hz:0x30
// 120Hz:0x50 130Hz:0x70
_Write_CommandCmd(0xab);
_Write_CommandCmd(0x01);
_Write_CommandCmd(0xb6); // Set phase length
_Write_CommandCmd(0x0f);
_Write_CommandCmd(0xbe);
_Write_CommandCmd(0x0f);
_Write_CommandCmd(0xbc);
_Write_CommandCmd(0x08);
_Write_CommandCmd(0xd5);
_Write_CommandCmd(0x62);
_Write_CommandCmd(0xfd);
_Write_CommandCmd(0x12);
_Write_CommandCmd(0xae);
友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。
7条回答
木東魚
2019-07-22 05:02
[mw_shl_code=c,true]for(j=0;j<128;j++)
{
for(i=0;i<16;i++)  
{
for(k = 0;k<4;k++)
{
if(k == 0)
{
Transfer_Char = (OLED_RAM[j]&0xC0)>>3;
}
else if(k == 1)
{
Transfer_Char = (OLED_RAM[j]&0x30)>>1;
}
else if(k == 2)
{
Transfer_Char = (OLED_RAM[j]&0x0C)<<1;
}
else if(k == 3)
{
Transfer_Char = (OLED_RAM[j]&0x03)<<3;
}
if((Transfer_Char&0xF0) != 0x00)
{
Transfer_Char |= 0xF0;
}
if((Transfer_Char&0x0F) != 0x00)
{
Transfer_Char |= 0x0F;
}
_Write_DataCmd(Transfer_Char);
}
}
}


一周热门 更多>