欧美极品高清xxxxhd,国产日产欧美最新,无码AV国产东京热AV无码,国产精品人与动性XXX,国产传媒亚洲综合一区二区,四库影院永久国产精品,毛片免费免费高清视频,福利所导航夜趣136

標題: TFT字母顯示反了 [打印本頁]

作者: 冷月楓    時間: 2019-12-8 18:00
標題: TFT字母顯示反了
我的TFT顯示的字母都是反的,漢字都是左右顛倒,不知道哪里的問題位置

void TFT_Set_Pos(uint x1,uint y1,uint x2,uint y2)//240x320
{  
   TFT_Write_Reg(0x2a);
   TFT_Write_8Data(x1>>8);
   TFT_Write_8Data(x1);
   TFT_Write_8Data(x2>>8);
   TFT_Write_8Data(x2);

   TFT_Write_Reg(0x2b);
   TFT_Write_8Data(y1>>8);
   TFT_Write_8Data(y1);
   TFT_Write_8Data(y2>>8);
   TFT_Write_8Data(y2);

   TFT_Write_Reg(0x2C);
}

漢字
void TFT_Show_Hanzi16x16(uint x,uint y,uchar index)       
{  
        uchar i,j;
    uchar *temp=hanzi16x16;    //Ö¸Ïò′æ·Åoo×ÖμÄêy×é
    TFT_Set_Pos(x,y,x+15,y+15); //éèÖÃÇøóò      
        temp+=index*32;        //1¸öoo×Ö32×Ö½ú,
        for(j=0;j<32;j++)
        {
                for(i=0;i<8;i++)
                {                      
                         if((*temp&(1<<i))!=0)
                        {
                                TFT_Write_16Data(POINT_COLOR);
                        }
                        else
                        {
                                TFT_Write_16Data(BACK_COLOR);
                        }   
                }
                temp++;//ÏÂò»¸ö×Ö½ú
         }
}





作者: xuyaqi    時間: 2019-12-9 09:40
漢字的取模方向與液晶的顯示方向是反的,要改其中一個。
作者: 冷月楓    時間: 2019-12-9 10:53
已解決,是一個寄存器設置的值不對
作者: 冷月楓    時間: 2019-12-9 10:53
感謝各位




歡迎光臨 (http://www.raoushi.com/bbs/) Powered by Discuz! X3.1