Prusa MINI Firmware overview
lcdsim.h File Reference
#include <inttypes.h>
#include "config.h"

Go to the source code of this file.

Functions

void lcdsim_init (void)
 
void lcdsim_invalidate (void)
 
uint8_t lcdsim_char_at (uint8_t col, uint8_t row)
 
uint8_tlcdsim_user_charset_ptr (void)
 
uint16_t lcdsim_grab_text (char *text)
 

Function Documentation

◆ lcdsim_init()

void lcdsim_init ( void  )
71  {
72  int i;
73  for (i = 0; i < LCD_CGRAM_SIZE; i++)
74  lcdsim_cgram[i] = 0x00;
75  lcdsim_expander = 0;
77 }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ lcdsim_invalidate()

void lcdsim_invalidate ( void  )
79  {
80  int i;
81  for (i = 0; i < 4; i++)
82  lcdsim_inval_mask[i] = 0x000fffff;
83 }
Here is the caller graph for this function:

◆ lcdsim_char_at()

uint8_t lcdsim_char_at ( uint8_t  col,
uint8_t  row 
)
85  {
86  return lcdsim_ddram[lcdsim_pos2addr(col, row)];
87 }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ lcdsim_user_charset_ptr()

uint8_t* lcdsim_user_charset_ptr ( void  )
89  {
90  return lcdsim_cgram;
91 }
Here is the caller graph for this function:

◆ lcdsim_grab_text()

uint16_t lcdsim_grab_text ( char *  text)
93  {
94  int row;
95  int col;
96  int i = 0;
97  for (row = 0; row < 4; row++) {
98  for (col = 0; col < 20; col++)
99  text[i + col] = lcdsim_char_at(col, row);
100  for (col = 19; col >= 0; col--)
101  if (text[i + col] != ' ')
102  break;
103  i += col + 1;
104  text[i++] = '\n';
105  }
106  text[i] = 0;
107  return i;
108 }
Here is the call graph for this function:
Here is the caller graph for this function:
lcdsim_char_at
uint8_t lcdsim_char_at(uint8_t col, uint8_t row)
Definition: lcdsim.c:85
i
uint8_t i
Definition: screen_test_graph.c:72
lcdsim_expander
uint8_t lcdsim_expander
Definition: lcdsim.c:34
lcdsim_ddram
uint8_t lcdsim_ddram[LCD_DDRAM_SIZE]
Definition: lcdsim.c:36
lcdsim_inval_mask
uint32_t lcdsim_inval_mask[LCDSIM_ROWS]
Definition: lcdsim.c:40
LCD_CGRAM_SIZE
#define LCD_CGRAM_SIZE
Definition: lcdsim.c:7
lcdsim_cgram
uint8_t lcdsim_cgram[LCD_CGRAM_SIZE]
Definition: lcdsim.c:37
lcdsim_cmd_clearDisplay
void lcdsim_cmd_clearDisplay(void)
Definition: lcdsim.c:153
lcdsim_pos2addr
static uint8_t lcdsim_pos2addr(uint8_t col, uint8_t row)
Definition: lcdsim.c:67