]> git.karo-electronics.de Git - oswald.git/blobdiff - metawatch/mw_lcd.c
Add invert option
[oswald.git] / metawatch / mw_lcd.c
index 0eb75507029c1504aef2ea379e17481052ead136..2082a6d5e4c3f55334aebac8533d2bff170d28af 100644 (file)
@@ -197,12 +197,21 @@ __interrupt void DMA_ISR (void)
 /* writes the complete internal framebuffer to the LCD */
 void mw_lcd_update_screen(void)
 {
-#ifndef LCD_DMA
+//#ifndef LCD_DMA
        unsigned int i,j;
-#endif
+//#endif
 
 //     debug_uart_tx("uscr1\n");
 
+       // invert the buffer
+       if (0) {
+               for (i=0; i<96; i++) {
+                       for ( j = 0; j < 12; j++ ) {
+                               lcd_buf[i].Data[j] = ~lcd_buf[i].Data[j];
+                       }
+               }
+       }
+
        LCD_CS_ASSERT();
 
        /* send WRITE command */
@@ -267,7 +276,7 @@ void mw_lcd_update_screen(void)
        mw_lcd_static_mode();
 }
 
-void mw_lcd_draw_pixel(unsigned char x, unsigned char y, unsigned char color)
+void mw_lcd_draw_pixel(const uint8_t x, const uint8_t y, const uint8_t color)
 {
        switch (color) {
                case 1: