본문 바로가기

[AVR]/AT90USB

[AT90USB1287-EX] AT90USB1287 TFT-LCD 출력 속도 테스트

[AT90USB1287-EX] AT90USB1287 TFT-LCD 출력 속도 테스트



16bit 240x400 한프레임 출력 시간은 140ms 정도 걸린다. 8비트 IO 제어 방식이라 빠른 속도를 기대하기는 힘들것 같다.


[AT90USB-EX] TFT LCD출력 속도 테스트 동영상






확장 포트는 표준 8bit 모드 TFT-LCD 모듈제어 포트를 연결할 수 있다.





[AT90USB-EX] TFT LCD Driver 코드
//-----------------------------------------------------------------------------
//TFT LCD Driver
#define TFT_DRV_HD66791                 0
#define TFT_DRV_COM44                   1
#define TFT_DRV_ST7735                    0

#define LCD_LAT_BIT      BIT4
#define LCD_LAT_PORT     PORTB
#define LCD_LAT_ON()     Sbi(LCD_LAT_PORT, LCD_LAT_BIT)
#define LCD_LAT_OFF()     Cbi(LCD_LAT_PORT, LCD_LAT_BIT)
#define LCD_DATA_LATCH()    LCD_LAT_ON();LCD_LAT_OFF();

#define LCD_EN_BIT      BIT6
#define LCD_EN_PORT      PORTB
#define LCD_ENABLE()     Cbi(LCD_EN_PORT, LCD_EN_BIT)
#define LCD_DISABLE()     Sbi(LCD_EN_PORT, LCD_EN_BIT)

#define LCD_RST_BIT      //BIT8
#define LCD_RST_PORT     //PORTB
#define LCD_RST_ON()     //Sbi(LCD_RST_PORT, LCD_RST_BIT)
#define LCD_RST_OFF()     //Cbi(LCD_RST_PORT, LCD_RST_BIT)

#define LCD_RS_BIT      BIT7
#define LCD_RS_PORT      PORTB
#define LCD_RS_OFF()     Cbi(LCD_RS_PORT, LCD_RS_BIT)
#define LCD_RS_ON()      Sbi(LCD_RS_PORT, LCD_RS_BIT)

#define LCD_WR_BIT      BIT0
#define LCD_WR_PORT      PORTE
#define LCD_WR_OFF()     Cbi(LCD_WR_PORT, LCD_WR_BIT)
#define LCD_WR_ON()      Sbi(LCD_WR_PORT, LCD_WR_BIT)

#define LCD_RD_BIT      BIT9
#define LCD_RD_PORT      PORTB
#define LCD_RD_OFF()     //Cbi(LCD_RD_PORT, LCD_RD_BIT)
#define LCD_RD_ON()      //Sbi(LCD_RD_PORT, LCD_RD_BIT)

#define LCD_BL_BIT      BIT5
#define LCD_BL_PORT      PORTB
#define LCD_BL_OFF()     Cbi(LCD_BL_PORT, LCD_BL_BIT)
#define LCD_BL_ON()      Sbi(LCD_BL_PORT, LCD_BL_BIT)

#define _LCD_DAT_OUT(Data)    PORTA = (Data>>8);\
                                     LCD_DATA_LATCH();\
                                     PORTA = (Data&0xFF);

#define TFTGpioInit()     Sbi(DDRB, BIT4|BIT5|BIT6|BIT7); Sbi(DDRA, 0xFF); Sbi(DDRE, BIT0);
//-----------------------------------------------------------------------------

반응형