summaryrefslogtreecommitdiff
path: root/firmware/drivers/lcd-h100-remote.c
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/drivers/lcd-h100-remote.c')
-rw-r--r--firmware/drivers/lcd-h100-remote.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/firmware/drivers/lcd-h100-remote.c b/firmware/drivers/lcd-h100-remote.c
index fe1c82dd3d..3edb27c155 100644
--- a/firmware/drivers/lcd-h100-remote.c
+++ b/firmware/drivers/lcd-h100-remote.c
@@ -421,14 +421,12 @@ void lcd_remote_update_rect(int x, int y, int width, int height)
421 if(ymax >= LCD_REMOTE_HEIGHT/8) 421 if(ymax >= LCD_REMOTE_HEIGHT/8)
422 ymax = LCD_REMOTE_HEIGHT/8-1; 422 ymax = LCD_REMOTE_HEIGHT/8-1;
423 423
424 x += xoffset;
425
426 /* Copy specified rectange bitmap to hardware */ 424 /* Copy specified rectange bitmap to hardware */
427 for (; y <= ymax; y++) 425 for (; y <= ymax; y++)
428 { 426 {
429 lcd_remote_write_command(LCD_REMOTE_CNTL_SET_PAGE_ADDRESS | y); 427 lcd_remote_write_command(LCD_REMOTE_CNTL_SET_PAGE_ADDRESS | y);
430 lcd_remote_write_command(LCD_REMOTE_CNTL_HIGHCOL | ((x >> 4) & 0xf)); 428 lcd_remote_write_command(LCD_REMOTE_CNTL_HIGHCOL | (((x+xoffset) >> 4) & 0xf));
431 lcd_remote_write_command(LCD_REMOTE_CNTL_LOWCOL | (x & 0xf)); 429 lcd_remote_write_command(LCD_REMOTE_CNTL_LOWCOL | ((x+xoffset) & 0xf));
432 lcd_remote_write_data(&lcd_remote_framebuffer[y][x], width); 430 lcd_remote_write_data(&lcd_remote_framebuffer[y][x], width);
433 } 431 }
434} 432}