Subversion Repositories Kolibri OS

Rev

Rev 8327 | Blame | Compare with Previous | Last modification | View Log | RSS feed

  1. #ifndef _PXA255_LCD_H_
  2. #define _PXA255_LCD_H_
  3.  
  4. #include "mem.h"
  5. #include "CPU.h"
  6. #include "pxa255_IC.h"
  7.  
  8. #ifndef EMBEDDED
  9.         #define PXA255_LCD_SUPPORTS_PALLETES
  10. #endif
  11.  
  12.  
  13. /*
  14.         PXA255 OS LCD controller
  15.        
  16.         PURRPOSE: it's nice to have a framebuffer
  17.  
  18. */
  19.  
  20. #define PXA255_LCD_BASE         0x44000000UL
  21. #define PXA255_LCD_SIZE         0x00001000UL
  22.  
  23.  
  24.  
  25.  
  26. #define LCD_STATE_IDLE          0
  27. #define LCD_STATE_DMA_0_START   1
  28. #define LCD_STATE_DMA_0_END     2
  29.  
  30. typedef struct{
  31.  
  32.         Pxa255ic* ic;
  33.         ArmMem* mem;
  34.        
  35.         //registers
  36.         UInt32 lccr0, lccr1, lccr2, lccr3, fbr0, fbr1, liicr, trgbr, tcr;
  37.         UInt32 fdadr0, fsadr0, fidr0, ldcmd0;
  38.         UInt32 fdadr1, fsadr1, fidr1, ldcmd1;
  39.         UInt16 lcsr;    //yes, 16-bit :)
  40.        
  41.         //for our use
  42.         UInt16 intMask;
  43.        
  44.         UInt8 state             : 6;
  45.         UInt8 intWasPending     : 1;
  46.         UInt8 enbChanged        : 1;
  47.        
  48. #ifdef PXA255_LCD_SUPPORTS_PALLETES
  49.  
  50.         UInt8 palette[512];
  51.  
  52. #endif
  53.  
  54.         UInt32 frameNum;
  55.        
  56. }Pxa255lcd;
  57.  
  58. Boolean pxa255lcdInit(Pxa255lcd* lcd, ArmMem* physMem, Pxa255ic* ic);
  59. void pxa255lcdFrame(Pxa255lcd* lcd);
  60.  
  61.  
  62. #endif
  63.  
  64.