| 1 | /* |
| 2 | |
| 3 | u8x8.h |
| 4 | |
| 5 | Universal 8bit Graphics Library (https://github.com/olikraus/u8g2/) |
| 6 | |
| 7 | Copyright (c) 2016, olikraus@gmail. |
| 8 | All rights reserved. |
| 9 | |
| 10 | Redistribution and use in source and binary forms, with or without modification, |
| 11 | are permitted provided that the following conditions are met: |
| 12 | |
| 13 | * Redistributions of source code must retain the above copyright notice, this list |
| 14 | of conditions and the following disclaimer. |
| 15 | |
| 16 | * Redistributions in binary form must reproduce the above copyright notice, this |
| 17 | list of conditions and the following disclaimer in the documentation and/or other |
| 18 | materials provided with the distribution. |
| 19 | |
| 20 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND |
| 21 | CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, |
| 22 | INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
| 23 | MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
| 24 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR |
| 25 | CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
| 26 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT |
| 27 | NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; |
| 28 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
| 29 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, |
| 30 | STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) |
| 31 | ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF |
| 32 | ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 33 | |
| 34 | |
| 35 | |
| 36 | U8glib has several layers. Each layer is implemented with a callback function. |
| 37 | This callback function handles the messages for the layer. |
| 38 | |
| 39 | The topmost level is the display layer. It includes the following messages: |
| 40 | |
| 41 | U8X8_MSG_DISPLAY_SETUP_MEMORY no communication with the display, setup memory only |
| 42 | U8X8_MSG_DISPLAY_INIT |
| 43 | U8X8_MSG_DISPLAY_SET_FLIP_MODE |
| 44 | U8X8_MSG_DISPLAY_SET_POWER_SAVE |
| 45 | U8X8_MSG_DISPLAY_SET_CONTRAST |
| 46 | U8X8_MSG_DISPLAY_DRAW_TILE |
| 47 | |
| 48 | A display driver may decided to breakdown these messages to a lower level interface or |
| 49 | implement this functionality directly. |
| 50 | |
| 51 | |
| 52 | One layer is the Command/Arg/Data interface. It can be used by the display layer |
| 53 | to communicate with the display hardware. |
| 54 | This layer only deals with data, commands and arguments. D/C line is unknown. |
| 55 | U8X8_MSG_CAD_INIT |
| 56 | U8X8_MSG_CAD_SET_I2C_ADR (obsolete) |
| 57 | U8X8_MSG_CAD_SET_DEVICE (obsolete) |
| 58 | U8X8_MSG_CAD_START_TRANSFER |
| 59 | U8X8_MSG_CAD_SEND_CMD |
| 60 | U8X8_MSG_CAD_SEND_ARG |
| 61 | U8X8_MSG_CAD_SEND_DATA |
| 62 | U8X8_MSG_CAD_END_TRANSFER |
| 63 | |
| 64 | The byte interface is there to send 1 byte (8 bits) to the display hardware. |
| 65 | This layer depends on the hardware of a microcontroller, if a specific hardware |
| 66 | should be used (I2C or SPI). |
| 67 | If this interface is implemented via software, it may use the GPIO level for sending |
| 68 | bytes. |
| 69 | U8X8_MSG_BYTE_INIT |
| 70 | U8X8_MSG_BYTE_SEND 30 |
| 71 | U8X8_MSG_BYTE_SET_DC 31 |
| 72 | U8X8_MSG_BYTE_START_TRANSFER |
| 73 | U8X8_MSG_BYTE_END_TRANSFER |
| 74 | U8X8_MSG_BYTE_SET_I2C_ADR (obsolete) |
| 75 | U8X8_MSG_BYTE_SET_DEVICE (obsolete) |
| 76 | |
| 77 | GPIO and Delay |
| 78 | U8X8_MSG_GPIO_INIT |
| 79 | U8X8_MSG_DELAY_MILLI |
| 80 | U8X8_MSG_DELAY_10MICRO |
| 81 | U8X8_MSG_DELAY_100NANO |
| 82 | U8X8_MSG_DELAY_NANO |
| 83 | */ |
| 84 | |
| 85 | #ifndef U8X8_H |
| 86 | #define U8X8_H |
| 87 | |
| 88 | /*==========================================*/ |
| 89 | /* Global Defines */ |
| 90 | |
| 91 | /* Undefine this to remove u8x8_SetContrast function */ |
| 92 | #ifndef U8X8_WITHOUT_SET_CONTRAST |
| 93 | #define U8X8_WITH_SET_CONTRAST |
| 94 | #endif |
| 95 | |
| 96 | /* Define this for an additional user pointer inside the u8x8 data struct */ |
| 97 | //#define U8X8_WITH_USER_PTR |
| 98 | |
| 99 | |
| 100 | /* Undefine this to remove u8x8_SetFlipMode function */ |
| 101 | /* 26 May 2016: Obsolete */ |
| 102 | //#define U8X8_WITH_SET_FLIP_MODE |
| 103 | |
| 104 | /* Select 0 or 1 for the default flip mode. This is not affected by U8X8_WITH_FLIP_MODE */ |
| 105 | /* Note: Not all display types support a mirror function for the frame buffer */ |
| 106 | /* 26 May 2016: Obsolete */ |
| 107 | //#define U8X8_DEFAULT_FLIP_MODE 0 |
| 108 | |
| 109 | /*==========================================*/ |
| 110 | /* Includes */ |
| 111 | |
| 112 | |
| 113 | #include <stdint.h> |
| 114 | #include <stdarg.h> |
| 115 | #include <stddef.h> |
| 116 | #include <limits.h> |
| 117 | |
| 118 | #if defined(__GNUC__) && defined(__AVR__) |
| 119 | #include <avr/pgmspace.h> |
| 120 | #endif |
| 121 | |
| 122 | /*==========================================*/ |
| 123 | /* C++ compatible */ |
| 124 | |
| 125 | #ifdef __cplusplus |
| 126 | extern "C" { |
| 127 | #endif |
| 128 | |
| 129 | |
| 130 | /*==========================================*/ |
| 131 | /* U8G2 internal defines */ |
| 132 | |
| 133 | /* the following macro returns the first value for the normal mode */ |
| 134 | /* or the second argument for the flip mode */ |
| 135 | |
| 136 | /* 26 May 2016: Obsolete |
| 137 | #if U8X8_DEFAULT_FLIP_MODE == 0 |
| 138 | #define U8X8_IF_DEFAULT_NORMAL_OR_FLIP(normal, flipmode) (normal) |
| 139 | #else |
| 140 | #define U8X8_IF_DEFAULT_NORMAL_OR_FLIP(normal, flipmode) (flipmode) |
| 141 | #endif |
| 142 | */ |
| 143 | |
| 144 | #ifdef __GNUC__ |
| 145 | # define U8X8_NOINLINE __attribute__((noinline)) |
| 146 | # define U8X8_SECTION(name) __attribute__ ((section (name))) |
| 147 | # define U8X8_UNUSED __attribute__((unused)) |
| 148 | #else |
| 149 | # define U8X8_SECTION(name) |
| 150 | # define U8X8_NOINLINE |
| 151 | # define U8X8_UNUSED |
| 152 | #endif |
| 153 | |
| 154 | #if defined(__GNUC__) && defined(__AVR__) |
| 155 | # define U8X8_FONT_SECTION(name) U8X8_SECTION(".progmem." name) |
| 156 | # define u8x8_pgm_read(adr) pgm_read_byte_near(adr) |
| 157 | # define U8X8_PROGMEM PROGMEM |
| 158 | #endif |
| 159 | |
| 160 | #if defined(ESP8266) |
| 161 | uint8_t u8x8_pgm_read_esp(const uint8_t * addr); /* u8x8_8x8.c */ |
| 162 | # define U8X8_FONT_SECTION(name) __attribute__((section(".text." name))) |
| 163 | # define u8x8_pgm_read(adr) u8x8_pgm_read_esp(adr) |
| 164 | # define U8X8_PROGMEM |
| 165 | #endif |
| 166 | |
| 167 | |
| 168 | |
| 169 | #ifndef U8X8_FONT_SECTION |
| 170 | # define U8X8_FONT_SECTION(name) |
| 171 | #endif |
| 172 | |
| 173 | #ifndef u8x8_pgm_read |
| 174 | # ifndef CHAR_BIT |
| 175 | # define u8x8_pgm_read(adr) (*(const uint8_t *)(adr)) |
| 176 | # else |
| 177 | # if CHAR_BIT > 8 |
| 178 | # define u8x8_pgm_read(adr) ((*(const uint8_t *)(adr)) & 0x0ff) |
| 179 | # else |
| 180 | # define u8x8_pgm_read(adr) (*(const uint8_t *)(adr)) |
| 181 | # endif |
| 182 | # endif |
| 183 | #endif |
| 184 | |
| 185 | #ifndef U8X8_PROGMEM |
| 186 | # define U8X8_PROGMEM |
| 187 | #endif |
| 188 | |
| 189 | #ifdef ARDUINO |
| 190 | #define U8X8_USE_PINS |
| 191 | #endif |
| 192 | |
| 193 | #ifdef __RTTHREAD__ |
| 194 | #define U8X8_USE_PINS |
| 195 | #endif |
| 196 | |
| 197 | #ifdef __LUATOS__ |
| 198 | #define U8X8_USE_PINS |
| 199 | #endif |
| 200 | |
| 201 | #if defined(__ARM_LINUX__) || defined(unix) || defined(__unix__) || defined(__unix) |
| 202 | /* https://github.com/olikraus/u8g2/pull/1666 */ |
| 203 | #define U8X8_USE_PINS |
| 204 | #define U8X8_WITH_USER_PTR |
| 205 | #endif |
| 206 | |
| 207 | /*==========================================*/ |
| 208 | /* U8X8 typedefs and data structures */ |
| 209 | |
| 210 | |
| 211 | typedef struct u8x8_struct u8x8_t; |
| 212 | typedef struct u8x8_display_info_struct u8x8_display_info_t; |
| 213 | typedef struct u8x8_tile_struct u8x8_tile_t; |
| 214 | |
| 215 | typedef uint8_t (*u8x8_msg_cb)(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 216 | typedef uint16_t (*u8x8_char_cb)(u8x8_t *u8x8, uint8_t b); |
| 217 | |
| 218 | |
| 219 | |
| 220 | |
| 221 | //struct u8x8_mcd_struct |
| 222 | //{ |
| 223 | // u8x8_msg_cb cb; /* current callback function */ |
| 224 | // u8x8_t *u8g2; /* pointer to the u8g2 parent to minimize the number of args */ |
| 225 | // u8x8_mcd_t *next; |
| 226 | //}; |
| 227 | |
| 228 | struct u8x8_tile_struct |
| 229 | { |
| 230 | uint8_t *tile_ptr; /* pointer to one or more tiles... should be "const" */ |
| 231 | uint8_t cnt; /* number of tiles */ |
| 232 | uint8_t x_pos; /* tile x position */ |
| 233 | uint8_t y_pos; /* tile y position */ |
| 234 | }; |
| 235 | |
| 236 | |
| 237 | struct u8x8_display_info_struct |
| 238 | { |
| 239 | /* == general == */ |
| 240 | |
| 241 | uint8_t chip_enable_level; /* UC1601: 0 */ |
| 242 | uint8_t chip_disable_level; /* opposite of chip_enable_level */ |
| 243 | |
| 244 | uint8_t post_chip_enable_wait_ns; /* UC1601: 5ns */ |
| 245 | uint8_t pre_chip_disable_wait_ns; /* UC1601: 5ns */ |
| 246 | uint8_t reset_pulse_width_ms; /* UC1601: 0.003ms --> 1ms */ |
| 247 | uint8_t post_reset_wait_ms; /* UC1601: 6ms */ |
| 248 | |
| 249 | |
| 250 | /* == SPI interface == */ |
| 251 | |
| 252 | /* after SDA has been applied, wait this much time for the SCK data takeover edge */ |
| 253 | /* if this is smaller than sck_pulse_width_ns, then use the value from sck_pulse_width_ns */ |
| 254 | uint8_t sda_setup_time_ns; /* UC1601: 12ns */ |
| 255 | /* the pulse width of the the clock signal, cycle time is twice this value */ |
| 256 | /* max freq is 1/(2*sck_pulse_width_ns) */ |
| 257 | /* AVR: below 70: DIV2, 8 MHz, >= 70 --> 4MHz clock (DIV4) */ |
| 258 | uint8_t sck_pulse_width_ns; /* UC1701: 50ns */ |
| 259 | |
| 260 | /* until here we have 8 bytes (uint8_t). Newly introduced for SPI.beginTransaction */ |
| 261 | uint32_t sck_clock_hz; |
| 262 | |
| 263 | /* previous name "sck_takeover_edge" renamed to "spi_mode" */ |
| 264 | /* bit 0 of spi_mode is equal to the value of the previous variable sck_takeover_edge, 20 Aug 16: This is wrong the bit is actually inverted */ |
| 265 | /* SPI has four clock modes: */ |
| 266 | /* 0: clock active high, data out on falling edge, clock default value is zero, takover on rising edge */ |
| 267 | /* 1: clock active high, data out on rising edge, clock default value is zero, takover on falling edge */ |
| 268 | /* 2: clock active low, data out on rising edge */ |
| 269 | /* 3: clock active low, data out on falling edge */ |
| 270 | /* most displays have clock mode 1 */ |
| 271 | uint8_t spi_mode; |
| 272 | |
| 273 | /* == I2C == */ |
| 274 | uint8_t i2c_bus_clock_100kHz; /* UC1601: 1000000000/275 = 37 *100k */ |
| 275 | |
| 276 | |
| 277 | /* == 8 bit interface == */ |
| 278 | |
| 279 | /* how long to wait after all data line are set */ |
| 280 | uint8_t data_setup_time_ns; /* UC1601: 30ns */ |
| 281 | /* write enable pulse width */ |
| 282 | uint8_t write_pulse_width_ns; /* UC1601: 40ns */ |
| 283 | |
| 284 | /* == layout == */ |
| 285 | uint8_t tile_width; |
| 286 | uint8_t tile_height; |
| 287 | |
| 288 | uint8_t default_x_offset; /* default x offset for the display */ |
| 289 | uint8_t flipmode_x_offset; /* x offset, if flip mode is enabled */ |
| 290 | |
| 291 | /* pixel width is not used by the u8x8 procedures */ |
| 292 | /* instead it will be used by the u8g2 procedures, because the pixel dimension can */ |
| 293 | /* not always be calculated from the tile_width/_height */ |
| 294 | /* the following conditions must be true: */ |
| 295 | /* pixel_width <= tile_width*8 */ |
| 296 | /* pixel_height <= tile_height*8 */ |
| 297 | uint16_t pixel_width; |
| 298 | uint16_t pixel_height; |
| 299 | }; |
| 300 | |
| 301 | |
| 302 | |
| 303 | /* list of U8x8 pins */ |
| 304 | #define U8X8_PIN_D0 0 |
| 305 | #define U8X8_PIN_SPI_CLOCK 0 |
| 306 | #define U8X8_PIN_D1 1 |
| 307 | #define U8X8_PIN_SPI_DATA 1 |
| 308 | #define U8X8_PIN_D2 2 |
| 309 | #define U8X8_PIN_D3 3 |
| 310 | #define U8X8_PIN_D4 4 |
| 311 | #define U8X8_PIN_D5 5 |
| 312 | #define U8X8_PIN_D6 6 |
| 313 | #define U8X8_PIN_D7 7 |
| 314 | |
| 315 | #define U8X8_PIN_E 8 |
| 316 | #define U8X8_PIN_CS 9 /* parallel, SPI */ |
| 317 | #define U8X8_PIN_DC 10 /* parallel, SPI */ |
| 318 | #define U8X8_PIN_RESET 11 /* parallel, SPI, I2C */ |
| 319 | |
| 320 | #define U8X8_PIN_I2C_CLOCK 12 /* 1 = Input/high impedance, 0 = drive low */ |
| 321 | #define U8X8_PIN_I2C_DATA 13 /* 1 = Input/high impedance, 0 = drive low */ |
| 322 | |
| 323 | #define U8X8_PIN_CS1 14 /* KS0108 extra chip select */ |
| 324 | #define U8X8_PIN_CS2 15 /* KS0108 extra chip select */ |
| 325 | |
| 326 | #define U8X8_PIN_OUTPUT_CNT 16 |
| 327 | |
| 328 | #define U8X8_PIN_MENU_SELECT 16 |
| 329 | #define U8X8_PIN_MENU_NEXT 17 |
| 330 | #define U8X8_PIN_MENU_PREV 18 |
| 331 | #define U8X8_PIN_MENU_HOME 19 |
| 332 | #define U8X8_PIN_MENU_UP 20 |
| 333 | #define U8X8_PIN_MENU_DOWN 21 |
| 334 | |
| 335 | #define U8X8_PIN_INPUT_CNT 6 |
| 336 | |
| 337 | #ifdef U8X8_USE_PINS |
| 338 | #define U8X8_PIN_CNT (U8X8_PIN_OUTPUT_CNT+U8X8_PIN_INPUT_CNT) |
| 339 | #define U8X8_PIN_NONE 255 |
| 340 | #endif |
| 341 | |
| 342 | struct u8x8_struct |
| 343 | { |
| 344 | const u8x8_display_info_t *display_info; |
| 345 | u8x8_char_cb next_cb; /* procedure, which will be used to get the next char from the string */ |
| 346 | u8x8_msg_cb display_cb; |
| 347 | u8x8_msg_cb cad_cb; |
| 348 | u8x8_msg_cb byte_cb; |
| 349 | u8x8_msg_cb gpio_and_delay_cb; |
| 350 | uint32_t bus_clock; /* can be used by the byte function to store the clock speed of the bus */ |
| 351 | const uint8_t *font; |
| 352 | uint16_t encoding; /* encoding result for utf8 decoder in next_cb */ |
| 353 | uint8_t x_offset; /* copied from info struct, can be modified in flip mode */ |
| 354 | uint8_t is_font_inverse_mode; /* 0: normal, 1: font glyphs are inverted */ |
| 355 | uint8_t i2c_address; /* a valid i2c adr. Initially this is 255, but this is set to something useful during DISPLAY_INIT */ |
| 356 | /* i2c_address is the address for writing data to the display */ |
| 357 | /* usually, the lowest bit must be zero for a valid address */ |
| 358 | uint8_t i2c_started; /* for i2c interface */ |
| 359 | //uint8_t device_address; /* OBSOLETE???? - this is the device address, replacement for U8X8_MSG_CAD_SET_DEVICE */ |
| 360 | uint8_t utf8_state; /* number of chars which are still to scan */ |
| 361 | uint8_t gpio_result; /* return value from the gpio call (only for MENU keys at the moment) */ |
| 362 | uint8_t debounce_default_pin_state; |
| 363 | uint8_t debounce_last_pin_state; |
| 364 | uint8_t debounce_state; |
| 365 | uint8_t debounce_result_msg; /* result msg or event after debounce */ |
| 366 | #ifdef U8X8_WITH_USER_PTR |
| 367 | void *user_ptr; |
| 368 | #endif |
| 369 | #ifdef U8X8_USE_PINS |
| 370 | uint8_t pins[U8X8_PIN_CNT]; /* defines a pinlist: Mainly a list of pins for the Arduino Environment, use U8X8_PIN_xxx to access */ |
| 371 | #endif |
| 372 | }; |
| 373 | |
| 374 | #ifdef U8X8_WITH_USER_PTR |
| 375 | #define u8x8_GetUserPtr(u8x8) ((u8x8)->user_ptr) |
| 376 | #define u8x8_SetUserPtr(u8x8, p) ((u8x8)->user_ptr = (p)) |
| 377 | #endif |
| 378 | |
| 379 | |
| 380 | #define u8x8_GetCols(u8x8) ((u8x8)->display_info->tile_width) |
| 381 | #define u8x8_GetRows(u8x8) ((u8x8)->display_info->tile_height) |
| 382 | #define u8x8_GetI2CAddress(u8x8) ((u8x8)->i2c_address) |
| 383 | #define u8x8_SetI2CAddress(u8x8, address) ((u8x8)->i2c_address = (address)) |
| 384 | |
| 385 | #define u8x8_SetGPIOResult(u8x8, val) ((u8x8)->gpio_result = (val)) |
| 386 | #define u8x8_GetSPIClockPhase(u8x8) ((u8x8)->display_info->spi_mode & 0x01) /* 0 means rising edge */ |
| 387 | #define u8x8_GetSPIClockPolarity(u8x8) (((u8x8)->display_info->spi_mode & 0x02) >> 1) |
| 388 | #define u8x8_GetSPIClockDefaultLevel(u8x8) (((u8x8)->display_info->spi_mode & 0x02) >> 1) |
| 389 | |
| 390 | #define u8x8_GetFontCharWidth(u8x8) u8x8_pgm_read( (u8x8)->font + 2 ) |
| 391 | #define u8x8_GetFontCharHeight(u8x8) u8x8_pgm_read( (u8x8)->font + 3 ) |
| 392 | |
| 393 | #ifdef U8X8_USE_PINS |
| 394 | #define u8x8_SetPin(u8x8,pin,val) (u8x8)->pins[pin] = (val) |
| 395 | #define u8x8_SetMenuSelectPin(u8x8, val) u8x8_SetPin((u8x8),U8X8_PIN_MENU_SELECT,(val)) |
| 396 | #define u8x8_SetMenuNextPin(u8x8, val) u8x8_SetPin((u8x8),U8X8_PIN_MENU_NEXT,(val)) |
| 397 | #define u8x8_SetMenuPrevPin(u8x8, val) u8x8_SetPin((u8x8),U8X8_PIN_MENU_PREV,(val)) |
| 398 | #define u8x8_SetMenuHomePin(u8x8, val) u8x8_SetPin((u8x8),U8X8_PIN_MENU_HOME,(val)) |
| 399 | #define u8x8_SetMenuUpPin(u8x8, val) u8x8_SetPin((u8x8),U8X8_PIN_MENU_UP,(val)) |
| 400 | #define u8x8_SetMenuDownPin(u8x8, val) u8x8_SetPin((u8x8),U8X8_PIN_MENU_DOWN,(val)) |
| 401 | #endif |
| 402 | |
| 403 | |
| 404 | /*==========================================*/ |
| 405 | /* u8log extension for u8x8 and u8g2 */ |
| 406 | |
| 407 | typedef struct u8log_struct u8log_t; |
| 408 | |
| 409 | |
| 410 | /* redraw the specified line. */ |
| 411 | typedef void (*u8log_cb)(u8log_t * u8log); |
| 412 | |
| 413 | struct u8log_struct |
| 414 | { |
| 415 | /* configuration */ |
| 416 | void *aux_data; /* pointer to u8x8 or u8g2 */ |
| 417 | uint8_t width, height; /* size of the terminal */ |
| 418 | u8log_cb cb; /* callback redraw function */ |
| 419 | uint8_t *screen_buffer; /* size must be width*height bytes */ |
| 420 | uint8_t is_redraw_line_for_each_char; |
| 421 | int8_t line_height_offset; /* extra offset for the line height (u8g2 only) */ |
| 422 | |
| 423 | /* internal data */ |
| 424 | //uint8_t last_x, last_y; /* position of the last printed char */ |
| 425 | uint8_t cursor_x, cursor_y; /* position of the cursor, might be off screen */ |
| 426 | uint8_t redraw_line; /* redraw specific line if is_redraw_line is not 0 */ |
| 427 | uint8_t is_redraw_line; |
| 428 | uint8_t is_redraw_all; |
| 429 | uint8_t is_redraw_all_required_for_next_nl; /* in nl mode, redraw all instead of current line */ |
| 430 | }; |
| 431 | |
| 432 | |
| 433 | /*==========================================*/ |
| 434 | |
| 435 | /* helper functions */ |
| 436 | void u8x8_d_helper_display_setup_memory(u8x8_t *u8x8, const u8x8_display_info_t *display_info); |
| 437 | void u8x8_d_helper_display_init(u8x8_t *u8g2); |
| 438 | |
| 439 | /* Display Interface */ |
| 440 | |
| 441 | /* |
| 442 | Name: U8X8_MSG_DISPLAY_SETUP_MEMORY |
| 443 | Args: None |
| 444 | Tasks: |
| 445 | 1) setup u8g2->display_info |
| 446 | copy u8g2->display_info->default_x_offset to u8g2->x_offset |
| 447 | |
| 448 | usually calls u8x8_d_helper_display_setup_memory() |
| 449 | */ |
| 450 | #define U8X8_MSG_DISPLAY_SETUP_MEMORY 9 |
| 451 | |
| 452 | /* |
| 453 | Name: U8X8_MSG_DISPLAY_INIT |
| 454 | Args: None |
| 455 | Tasks: |
| 456 | |
| 457 | 2) put interface into default state: |
| 458 | execute u8x8_gpio_Init for port directions |
| 459 | execute u8x8_cad_Init for default port levels |
| 460 | 3) set CS status (not clear, may be done in cad/byte interface |
| 461 | 4) execute display reset (gpio interface) |
| 462 | 5) send setup sequence to display, do not activate display, disable "power save" will follow |
| 463 | */ |
| 464 | #define U8X8_MSG_DISPLAY_INIT 10 |
| 465 | |
| 466 | /* |
| 467 | Name: U8X8_MSG_DISPLAY_SET_POWER_SAVE |
| 468 | Args: arg_int: 0: normal mode (RAM is visible on the display), 1: nothing is shown |
| 469 | Tasks: |
| 470 | Depending on arg_int, put the display into normal or power save mode. |
| 471 | Send the corresponding sequence to the display. |
| 472 | In power save mode, it must be possible to modify the RAM content. |
| 473 | */ |
| 474 | #define U8X8_MSG_DISPLAY_SET_POWER_SAVE 11 |
| 475 | |
| 476 | /* |
| 477 | Name: U8X8_MSG_DISPLAY_SET_FLIP_MODE |
| 478 | Args: arg_int: 0: normal mode, 1: flipped HW screen (180 degree) |
| 479 | Tasks: |
| 480 | Reprograms the display controller to rotate the display by |
| 481 | 180 degree (arg_int = 1) or not (arg_int = 0) |
| 482 | This may change u8g2->x_offset if the display is smaller than the controller ram |
| 483 | This message should only be supported if U8X8_WITH_FLIP_MODE is defined. |
| 484 | */ |
| 485 | #define U8X8_MSG_DISPLAY_SET_FLIP_MODE 13 |
| 486 | |
| 487 | /* arg_int: 0..255 contrast value */ |
| 488 | #define U8X8_MSG_DISPLAY_SET_CONTRAST 14 |
| 489 | |
| 490 | /* |
| 491 | Name: U8X8_MSG_DISPLAY_DRAW_TILE |
| 492 | Args: |
| 493 | arg_int: How often to repeat this tile pattern |
| 494 | arg_ptr: pointer to u8x8_tile_t |
| 495 | uint8_t *tile_ptr; pointer to one or more tiles (number is "cnt") |
| 496 | uint8_t cnt; number of tiles |
| 497 | uint8_t x_pos; first tile x position |
| 498 | uint8_t y_pos; first tile y position |
| 499 | Tasks: |
| 500 | One tile has exactly 8 bytes (8x8 pixel monochrome bitmap). |
| 501 | The lowest bit of the first byte is the upper left corner |
| 502 | The highest bit of the first byte is the lower left corner |
| 503 | The lowest bit of the last byte is the upper right corner |
| 504 | The highest bit of the last byte is the lower left corner |
| 505 | "tile_ptr" is the address of a memory area, which contains |
| 506 | one or more tiles. "cnt" will contain the exact number of |
| 507 | tiles in the memory areay. The size of the memory area is 8*cnt; |
| 508 | Multiple tiles in the memory area form a horizontal sequence, this |
| 509 | means the first tile is drawn at x_pos/y_pos, the second tile is drawn |
| 510 | at x_pos+1/y_pos, third at x_pos+2/y_pos. |
| 511 | "arg_int" tells how often the tile sequence should be repeated: |
| 512 | For example if "cnt" is two and tile_ptr points to tiles A and B, |
| 513 | then for arg_int = 3, the following tile sequence will be drawn: |
| 514 | ABABAB. Totally, cnt*arg_int tiles will be drawn. |
| 515 | |
| 516 | */ |
| 517 | #define U8X8_MSG_DISPLAY_DRAW_TILE 15 |
| 518 | |
| 519 | |
| 520 | /* |
| 521 | Name: U8X8_MSG_DISPLAY_REFRESH |
| 522 | Args: |
| 523 | arg_int: - |
| 524 | arg_ptr: - |
| 525 | |
| 526 | This was introduced for the SSD1606 eInk display. |
| 527 | The problem is, that all RAM access will not appear on the screen |
| 528 | unless a special command is executed. With this message, this command |
| 529 | sequence is executed. |
| 530 | Use |
| 531 | void u8x8_RefreshDisplay(u8x8_t *u8x8) |
| 532 | to send the message to the display handler. |
| 533 | */ |
| 534 | #define U8X8_MSG_DISPLAY_REFRESH 16 |
| 535 | |
| 536 | /*==========================================*/ |
| 537 | /* u8x8_setup.c */ |
| 538 | |
| 539 | uint8_t u8x8_dummy_cb(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 540 | |
| 541 | /* |
| 542 | Setup u8x8 object itself. This should be the very first function |
| 543 | called on the new u8x8 object. After this call, assign the callback |
| 544 | functions. Optional: Set the pins |
| 545 | */ |
| 546 | |
| 547 | void u8x8_SetupDefaults(u8x8_t *u8x8); /* do not use this, use u8x8_Setup() instead */ |
| 548 | |
| 549 | void u8x8_Setup(u8x8_t *u8x8, u8x8_msg_cb display_cb, u8x8_msg_cb cad_cb, u8x8_msg_cb byte_cb, u8x8_msg_cb gpio_and_delay_cb); |
| 550 | |
| 551 | /*==========================================*/ |
| 552 | /* u8x8_display.c */ |
| 553 | uint8_t u8x8_DrawTile(u8x8_t *u8x8, uint8_t x, uint8_t y, uint8_t cnt, uint8_t *tile_ptr); |
| 554 | |
| 555 | /* |
| 556 | After a call to u8x8_SetupDefaults, |
| 557 | setup u8x8 memory structures & inform callbacks |
| 558 | This function is also called from u8x8_Setup(), so do not call u8x8_SetupMemory() |
| 559 | directly, but use u8x8_Setup() instead. |
| 560 | */ |
| 561 | void u8x8_SetupMemory(u8x8_t *u8x8); |
| 562 | |
| 563 | /* |
| 564 | Init the interface to the display, but not the display itself. |
| 565 | This might be useful, if the display is already running. |
| 566 | |
| 567 | InitInterface is called from InitDisplay, do not call both functions. |
| 568 | */ |
| 569 | void u8x8_InitInterface(u8x8_t *u8x8); |
| 570 | |
| 571 | /* |
| 572 | After calling u8x8_SetupMemory()/u8x8_Setup(), init the display hardware itself. |
| 573 | This will will the first time, u8x8 talks to the display. |
| 574 | It will init the display, but keep display in power save mode. |
| 575 | Usually this command must be followed by u8x8_SetPowerSave() |
| 576 | */ |
| 577 | void u8x8_InitDisplay(u8x8_t *u8x8); |
| 578 | /* wake up display from power save mode */ |
| 579 | void u8x8_SetPowerSave(u8x8_t *u8x8, uint8_t is_enable); |
| 580 | void u8x8_SetFlipMode(u8x8_t *u8x8, uint8_t mode); |
| 581 | void u8x8_SetContrast(u8x8_t *u8x8, uint8_t value); |
| 582 | void u8x8_ClearDisplayWithTile(u8x8_t *u8x8, const uint8_t *buf) U8X8_NOINLINE; |
| 583 | void u8x8_ClearDisplay(u8x8_t *u8x8); // this does not work for u8g2 in some cases |
| 584 | void u8x8_FillDisplay(u8x8_t *u8x8); |
| 585 | void u8x8_RefreshDisplay(u8x8_t *u8x8); // make RAM content visible on the display (Dec 16: SSD1606 only) |
| 586 | void u8x8_ClearLine(u8x8_t *u8x8, uint8_t line); |
| 587 | |
| 588 | |
| 589 | |
| 590 | /*==========================================*/ |
| 591 | /* Command Arg Data (CAD) Interface */ |
| 592 | |
| 593 | /* |
| 594 | U8X8_MSG_CAD_INIT |
| 595 | no args |
| 596 | call U8X8_MSG_BYTE_INIT |
| 597 | setup default values for the I/O lines |
| 598 | */ |
| 599 | #define U8X8_MSG_CAD_INIT 20 |
| 600 | |
| 601 | |
| 602 | #define U8X8_MSG_CAD_SEND_CMD 21 |
| 603 | /* arg_int: cmd byte */ |
| 604 | #define U8X8_MSG_CAD_SEND_ARG 22 |
| 605 | /* arg_int: arg byte */ |
| 606 | #define U8X8_MSG_CAD_SEND_DATA 23 |
| 607 | /* arg_int: expected cs level after processing this msg */ |
| 608 | #define U8X8_MSG_CAD_START_TRANSFER 24 |
| 609 | /* arg_int: expected cs level after processing this msg */ |
| 610 | #define U8X8_MSG_CAD_END_TRANSFER 25 |
| 611 | /* arg_int = 0: disable chip, arg_int = 1: enable chip */ |
| 612 | //#define U8X8_MSG_CAD_SET_I2C_ADR 26 |
| 613 | //#define U8X8_MSG_CAD_SET_DEVICE 27 |
| 614 | |
| 615 | |
| 616 | |
| 617 | /* u8g_cad.c */ |
| 618 | |
| 619 | #define u8x8_cad_Init(u8x8) ((u8x8)->cad_cb((u8x8), U8X8_MSG_CAD_INIT, 0, NULL )) |
| 620 | |
| 621 | uint8_t u8x8_cad_SendCmd(u8x8_t *u8x8, uint8_t cmd) U8X8_NOINLINE; |
| 622 | uint8_t u8x8_cad_SendArg(u8x8_t *u8x8, uint8_t arg) U8X8_NOINLINE; |
| 623 | uint8_t u8x8_cad_SendMultipleArg(u8x8_t *u8x8, uint8_t cnt, uint8_t arg) U8X8_NOINLINE; |
| 624 | uint8_t u8x8_cad_SendData(u8x8_t *u8x8, uint8_t cnt, uint8_t *data) U8X8_NOINLINE; |
| 625 | uint8_t u8x8_cad_StartTransfer(u8x8_t *u8x8) U8X8_NOINLINE; |
| 626 | uint8_t u8x8_cad_EndTransfer(u8x8_t *u8x8) U8X8_NOINLINE; |
| 627 | void u8x8_cad_vsendf(u8x8_t * u8x8, const char *fmt, va_list va); |
| 628 | void u8x8_SendF(u8x8_t * u8x8, const char *fmt, ...); |
| 629 | |
| 630 | /* |
| 631 | #define U8X8_C(c0) (0x04), (c0) |
| 632 | #define U8X8_CA(c0,a0) (0x05), (c0), (a0) |
| 633 | #define U8X8_CAA(c0,a0,a1) (0x06), (c0), (a0), (a1) |
| 634 | #define U8X8_DATA() (0x10) |
| 635 | #define U8X8_D1(d0) (0x11), (d0) |
| 636 | */ |
| 637 | |
| 638 | #define U8X8_C(c0) (U8X8_MSG_CAD_SEND_CMD), (c0) |
| 639 | #define U8X8_A(a0) (U8X8_MSG_CAD_SEND_ARG), (a0) |
| 640 | #define U8X8_CA(c0,a0) (U8X8_MSG_CAD_SEND_CMD), (c0), (U8X8_MSG_CAD_SEND_ARG), (a0) |
| 641 | #define U8X8_CAA(c0,a0,a1) (U8X8_MSG_CAD_SEND_CMD), (c0), (U8X8_MSG_CAD_SEND_ARG), (a0), (U8X8_MSG_CAD_SEND_ARG), (a1) |
| 642 | #define U8X8_CCAA(c0,c1,a0, a1) (U8X8_MSG_CAD_SEND_CMD), (c0), (U8X8_MSG_CAD_SEND_CMD), (c1), (U8X8_MSG_CAD_SEND_ARG), (a0), (U8X8_MSG_CAD_SEND_ARG), (a1) |
| 643 | #define U8X8_CAAA(c0,a0,a1, a2) (U8X8_MSG_CAD_SEND_CMD), (c0), (U8X8_MSG_CAD_SEND_ARG), (a0), (U8X8_MSG_CAD_SEND_ARG), (a1), (U8X8_MSG_CAD_SEND_ARG), (a2) |
| 644 | #define U8X8_CAAAA(c0,a0,a1,a2,a3) (U8X8_MSG_CAD_SEND_CMD), (c0), (U8X8_MSG_CAD_SEND_ARG), (a0), (U8X8_MSG_CAD_SEND_ARG), (a1), (U8X8_MSG_CAD_SEND_ARG), (a2), (U8X8_MSG_CAD_SEND_ARG), (a3) |
| 645 | #define U8X8_AAC(a0,a1,c0) (U8X8_MSG_CAD_SEND_ARG), (a0), (U8X8_MSG_CAD_SEND_ARG), (a1), (U8X8_MSG_CAD_SEND_CMD), (c0) |
| 646 | #define U8X8_D1(d0) (U8X8_MSG_CAD_SEND_DATA), (d0) |
| 647 | |
| 648 | #define U8X8_A4(a0,a1,a2,a3) U8X8_A(a0), U8X8_A(a1), U8X8_A(a2), U8X8_A(a3) |
| 649 | #define U8X8_A6(a0,a1,a2,a3,a4,a5) U8X8_A(a0), U8X8_A(a1), U8X8_A(a2), U8X8_A(a3), U8X8_A(a4), U8X8_A(a5) |
| 650 | #define U8X8_A8(a0,a1,a2,a3,a4,a5,a6,a7) U8X8_A4((a0), (a1), (a2), (a3)), U8X8_A4((a4), (a5), (a6), (a7)) |
| 651 | |
| 652 | |
| 653 | #define U8X8_START_TRANSFER() (U8X8_MSG_CAD_START_TRANSFER) |
| 654 | #define U8X8_END_TRANSFER() (U8X8_MSG_CAD_END_TRANSFER) |
| 655 | #define U8X8_DLY(m) (0xfe),(m) /* delay in milli seconds */ |
| 656 | #define U8X8_END() (0xff) |
| 657 | |
| 658 | void u8x8_cad_SendSequence(u8x8_t *u8x8, uint8_t const *data); |
| 659 | uint8_t u8x8_cad_empty(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 660 | uint8_t u8x8_cad_110(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 661 | uint8_t u8x8_gu800_cad_110(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 662 | uint8_t u8x8_cad_001(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 663 | uint8_t u8x8_cad_011(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 664 | uint8_t u8x8_cad_100(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 665 | uint8_t u8x8_cad_st7920_spi(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 666 | uint8_t u8x8_cad_ssd13xx_i2c(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* CAD=001 */ |
| 667 | uint8_t u8x8_cad_011_ssd13xx_i2c(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* CAD=011 */ |
| 668 | uint8_t u8x8_cad_ssd13xx_fast_i2c(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* CAD=001 */ |
| 669 | uint8_t u8x8_cad_st75256_i2c(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 670 | uint8_t u8x8_cad_ld7032_i2c(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 671 | uint8_t u8x8_cad_uc16xx_i2c(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* CAD=001 */ |
| 672 | uint8_t u8x8_cad_uc1638_i2c(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* CAD=011 */ |
| 673 | |
| 674 | |
| 675 | /*==========================================*/ |
| 676 | /* Byte Interface */ |
| 677 | |
| 678 | #define U8X8_MSG_BYTE_INIT U8X8_MSG_CAD_INIT |
| 679 | #define U8X8_MSG_BYTE_SET_DC 32 |
| 680 | |
| 681 | #define U8X8_MSG_BYTE_SEND U8X8_MSG_CAD_SEND_DATA |
| 682 | |
| 683 | #define U8X8_MSG_BYTE_START_TRANSFER U8X8_MSG_CAD_START_TRANSFER |
| 684 | #define U8X8_MSG_BYTE_END_TRANSFER U8X8_MSG_CAD_END_TRANSFER |
| 685 | |
| 686 | //#define U8X8_MSG_BYTE_SET_I2C_ADR U8X8_MSG_CAD_SET_I2C_ADR |
| 687 | //#define U8X8_MSG_BYTE_SET_DEVICE U8X8_MSG_CAD_SET_DEVICE |
| 688 | |
| 689 | |
| 690 | uint8_t u8x8_byte_SetDC(u8x8_t *u8x8, uint8_t dc) U8X8_NOINLINE; |
| 691 | uint8_t u8x8_byte_SendByte(u8x8_t *u8x8, uint8_t byte) U8X8_NOINLINE; |
| 692 | uint8_t u8x8_byte_SendBytes(u8x8_t *u8x8, uint8_t cnt, uint8_t *data) U8X8_NOINLINE; |
| 693 | uint8_t u8x8_byte_StartTransfer(u8x8_t *u8x8); |
| 694 | uint8_t u8x8_byte_EndTransfer(u8x8_t *u8x8); |
| 695 | |
| 696 | uint8_t u8x8_byte_empty(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 697 | uint8_t u8x8_byte_4wire_sw_spi(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 698 | uint8_t u8x8_byte_8bit_6800mode(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 699 | uint8_t u8x8_byte_8bit_8080mode(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 700 | uint8_t u8x8_byte_3wire_sw_spi(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 701 | /* uint8_t u8x8_byte_st7920_sw_spi(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); */ |
| 702 | void u8x8_byte_set_ks0108_cs(u8x8_t *u8x8, uint8_t arg) U8X8_NOINLINE; |
| 703 | uint8_t u8x8_byte_ks0108(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 704 | uint8_t u8x8_byte_ssd13xx_sw_i2c(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* OBSOLETE! */ |
| 705 | uint8_t u8x8_byte_sw_i2c(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 706 | uint8_t u8x8_byte_sed1520(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 707 | |
| 708 | |
| 709 | /*==========================================*/ |
| 710 | /* GPIO Interface */ |
| 711 | |
| 712 | |
| 713 | /* |
| 714 | U8X8_MSG_GPIO_AND_DELAY_INIT |
| 715 | no args |
| 716 | setup port directions, do not set IO levels, this is done with BYTE/CAD_INIT |
| 717 | */ |
| 718 | #define U8X8_MSG_GPIO_AND_DELAY_INIT 40 |
| 719 | |
| 720 | /* arg_int: milliseconds */ |
| 721 | #define U8X8_MSG_DELAY_MILLI 41 |
| 722 | |
| 723 | /* 10MICRO and 100NANO are not used at the moment */ |
| 724 | #define U8X8_MSG_DELAY_10MICRO 42 |
| 725 | #define U8X8_MSG_DELAY_100NANO 43 |
| 726 | |
| 727 | |
| 728 | #define U8X8_MSG_DELAY_NANO 44 |
| 729 | /* delay of one i2c unit, should be 5us for 100K, and 1.25us for 400K */ |
| 730 | #define U8X8_MSG_DELAY_I2C 45 |
| 731 | |
| 732 | #define U8X8_MSG_GPIO(x) (64+(x)) |
| 733 | #ifdef U8X8_USE_PINS |
| 734 | #define u8x8_GetPinIndex(u8x8, msg) ((msg)&0x3f) |
| 735 | #define u8x8_GetPinValue(u8x8, msg) ((u8x8)->pins[(msg)&0x3f]) |
| 736 | #endif |
| 737 | |
| 738 | #define U8X8_MSG_GPIO_D0 U8X8_MSG_GPIO(U8X8_PIN_D0) |
| 739 | #define U8X8_MSG_GPIO_SPI_CLOCK U8X8_MSG_GPIO(U8X8_PIN_SPI_CLOCK) |
| 740 | #define U8X8_MSG_GPIO_D1 U8X8_MSG_GPIO(U8X8_PIN_D1) |
| 741 | #define U8X8_MSG_GPIO_SPI_DATA U8X8_MSG_GPIO(U8X8_PIN_SPI_DATA) |
| 742 | #define U8X8_MSG_GPIO_D2 U8X8_MSG_GPIO(U8X8_PIN_D2) |
| 743 | #define U8X8_MSG_GPIO_D3 U8X8_MSG_GPIO(U8X8_PIN_D3) |
| 744 | #define U8X8_MSG_GPIO_D4 U8X8_MSG_GPIO(U8X8_PIN_D4) |
| 745 | #define U8X8_MSG_GPIO_D5 U8X8_MSG_GPIO(U8X8_PIN_D5) |
| 746 | #define U8X8_MSG_GPIO_D6 U8X8_MSG_GPIO(U8X8_PIN_D6) |
| 747 | #define U8X8_MSG_GPIO_D7 U8X8_MSG_GPIO(U8X8_PIN_D7) |
| 748 | #define U8X8_MSG_GPIO_E U8X8_MSG_GPIO(U8X8_PIN_E) // used as E1 for the SED1520 |
| 749 | #define U8X8_MSG_GPIO_CS U8X8_MSG_GPIO(U8X8_PIN_CS) // used as E2 for the SED1520 |
| 750 | #define U8X8_MSG_GPIO_DC U8X8_MSG_GPIO(U8X8_PIN_DC) |
| 751 | #define U8X8_MSG_GPIO_RESET U8X8_MSG_GPIO(U8X8_PIN_RESET) |
| 752 | #define U8X8_MSG_GPIO_I2C_CLOCK U8X8_MSG_GPIO(U8X8_PIN_I2C_CLOCK) |
| 753 | #define U8X8_MSG_GPIO_I2C_DATA U8X8_MSG_GPIO(U8X8_PIN_I2C_DATA) |
| 754 | |
| 755 | |
| 756 | #define U8X8_MSG_GPIO_CS1 U8X8_MSG_GPIO(U8X8_PIN_CS1) /* KS0108 extra chip select */ |
| 757 | #define U8X8_MSG_GPIO_CS2 U8X8_MSG_GPIO(U8X8_PIN_CS2) /* KS0108 extra chip select */ |
| 758 | |
| 759 | |
| 760 | /* these message expect the return value in u8x8->gpio_result */ |
| 761 | #define U8X8_MSG_GPIO_MENU_SELECT U8X8_MSG_GPIO(U8X8_PIN_MENU_SELECT) |
| 762 | #define U8X8_MSG_GPIO_MENU_NEXT U8X8_MSG_GPIO(U8X8_PIN_MENU_NEXT) |
| 763 | #define U8X8_MSG_GPIO_MENU_PREV U8X8_MSG_GPIO(U8X8_PIN_MENU_PREV) |
| 764 | #define U8X8_MSG_GPIO_MENU_HOME U8X8_MSG_GPIO(U8X8_PIN_MENU_HOME) |
| 765 | #define U8X8_MSG_GPIO_MENU_UP U8X8_MSG_GPIO(U8X8_PIN_MENU_UP) |
| 766 | #define U8X8_MSG_GPIO_MENU_DOWN U8X8_MSG_GPIO(U8X8_PIN_MENU_DOWN) |
| 767 | |
| 768 | |
| 769 | #define u8x8_gpio_Init(u8x8) ((u8x8)->gpio_and_delay_cb((u8x8), U8X8_MSG_GPIO_AND_DELAY_INIT, 0, NULL )) |
| 770 | |
| 771 | |
| 772 | /* |
| 773 | #define u8x8_gpio_SetDC(u8x8, v) ((u8x8)->gpio_and_delay_cb((u8x8), U8X8_MSG_GPIO_DC, (v), NULL )) |
| 774 | #define u8x8_gpio_SetCS(u8x8, v) ((u8x8)->gpio_and_delay_cb((u8x8), U8X8_MSG_GPIO_CS, (v), NULL )) |
| 775 | #define u8x8_gpio_SetReset(u8x8, v) ((u8x8)->gpio_and_delay_cb((u8x8), U8X8_MSG_GPIO_RESET, (v), NULL )) |
| 776 | */ |
| 777 | |
| 778 | #define u8x8_gpio_SetDC(u8x8, v) u8x8_gpio_call(u8x8, U8X8_MSG_GPIO_DC, (v)) |
| 779 | #define u8x8_gpio_SetCS(u8x8, v) u8x8_gpio_call(u8x8, U8X8_MSG_GPIO_CS, (v)) |
| 780 | #define u8x8_gpio_SetReset(u8x8, v) u8x8_gpio_call(u8x8, U8X8_MSG_GPIO_RESET, (v)) |
| 781 | #define u8x8_gpio_SetSPIClock(u8x8, v) u8x8_gpio_call(u8x8, U8X8_MSG_GPIO_SPI_CLOCK, (v)) |
| 782 | #define u8x8_gpio_SetSPIData(u8x8, v) u8x8_gpio_call(u8x8, U8X8_MSG_GPIO_SPI_DATA, (v)) |
| 783 | #define u8x8_gpio_SetI2CClock(u8x8, v) u8x8_gpio_call(u8x8, U8X8_MSG_GPIO_I2C_CLOCK, (v)) |
| 784 | #define u8x8_gpio_SetI2CData(u8x8, v) u8x8_gpio_call(u8x8, U8X8_MSG_GPIO_I2C_DATA, (v)) |
| 785 | |
| 786 | void u8x8_gpio_call(u8x8_t *u8x8, uint8_t msg, uint8_t arg) U8X8_NOINLINE; |
| 787 | |
| 788 | #define u8x8_gpio_Delay(u8x8, msg, dly) u8x8_gpio_call((u8x8), (msg), (dly)) |
| 789 | //void u8x8_gpio_Delay(u8x8_t *u8x8, uint8_t msg, uint8_t dly) U8X8_NOINLINE; |
| 790 | |
| 791 | |
| 792 | /*==========================================*/ |
| 793 | /* u8x8_debounce.c */ |
| 794 | /* return U8X8_MSG_GPIO_MENU_xxxxx messages */ |
| 795 | uint8_t u8x8_GetMenuEvent(u8x8_t *u8x8); |
| 796 | |
| 797 | /*==========================================*/ |
| 798 | /* u8x8_d_stdio.c */ |
| 799 | void u8x8_SetupStdio(u8x8_t *u8x8); |
| 800 | |
| 801 | /*==========================================*/ |
| 802 | /* u8x8_d_sdl_128x64.c */ |
| 803 | void u8x8_Setup_SDL_128x64(u8x8_t *u8x8); |
| 804 | void u8x8_Setup_SDL_240x160(u8x8_t *u8x8); |
| 805 | void u8x8_Setup_SDL_256x128(u8x8_t *u8x8); |
| 806 | int u8g_sdl_get_key(void); |
| 807 | |
| 808 | /*==========================================*/ |
| 809 | /* u8x8_d_tga.c */ |
| 810 | void u8x8_Setup_TGA_DESC(u8x8_t *u8x8); |
| 811 | void u8x8_Setup_TGA_LCD(u8x8_t *u8x8); |
| 812 | void tga_save(const char *name); |
| 813 | |
| 814 | /*==========================================*/ |
| 815 | /* u8x8_d_bitmap.c */ |
| 816 | uint8_t u8x8_GetBitmapPixel(u8x8_t *u8x8, uint16_t x, uint16_t y); |
| 817 | void u8x8_SaveBitmapTGA(u8x8_t *u8x8, const char *filename); |
| 818 | void u8x8_SetupBitmap(u8x8_t *u8x8, uint16_t pixel_width, uint16_t pixel_height); |
| 819 | uint8_t u8x8_ConnectBitmapToU8x8(u8x8_t *u8x8); |
| 820 | |
| 821 | /*==========================================*/ |
| 822 | /* u8x8_d_framebuffer.c */ |
| 823 | void u8x8_SetupLinuxFb(u8x8_t *u8x8, int fbfd); |
| 824 | void u8x8_LinuxFbSetActiveColor(uint32_t color); |
| 825 | |
| 826 | /*==========================================*/ |
| 827 | /* u8x8_d_utf8.c */ |
| 828 | void u8x8_Setup_Utf8(u8x8_t *u8x8); /* stdout UTF-8 display */ |
| 829 | void utf8_show(void); /* show content of UTF-8 frame buffer */ |
| 830 | |
| 831 | |
| 832 | /*==========================================*/ |
| 833 | |
| 834 | /* u8x8_setup.c */ |
| 835 | uint8_t u8x8_d_null_cb(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 836 | |
| 837 | /* u8x8_d_XXX.c */ |
| 838 | uint8_t u8x8_d_uc1701_ea_dogs102(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 839 | uint8_t u8x8_d_uc1701_mini12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 840 | uint8_t u8x8_d_ssd1305_128x32_noname(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 841 | uint8_t u8x8_d_ssd1305_128x32_adafruit(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 842 | /*uint8_t u8x8_d_ssd1305_128x32_waveshare(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr);*/ |
| 843 | uint8_t u8x8_d_ssd1305_128x64_adafruit(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 844 | uint8_t u8x8_d_ssd1305_128x64_raystar(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 845 | uint8_t u8x8_d_ssd1306_128x64_noname(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 846 | uint8_t u8x8_d_ssd1306_128x64_vcomh0(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 847 | uint8_t u8x8_d_ssd1306_128x64_alt0(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 848 | uint8_t u8x8_d_ssd1309_128x64_noname0(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 849 | /* CSC ==> */ |
| 850 | uint8_t u8x8_d_ssd1309_128x128_noname0(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 851 | /* <== CSC */ |
| 852 | uint8_t u8x8_d_ssd1309_128x64_noname2(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 853 | |
| 854 | uint8_t u8x8_d_ssd1312_128x64_noname(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 855 | uint8_t u8x8_d_ssd1312_128x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 856 | uint8_t u8x8_d_ssd1312_120x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 857 | uint8_t u8x8_d_ssd1312_120x28(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 858 | |
| 859 | uint8_t u8x8_d_ssd1306_2040x16(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 860 | uint8_t u8x8_d_ssd1306_128x32_univision(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 861 | uint8_t u8x8_d_ssd1306_128x32_winstar(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 862 | uint8_t u8x8_d_ssd1306_102x64_ea_oleds102(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* u8x8_ssd1309.c */ |
| 863 | uint8_t u8x8_d_ssd1306_64x48_er(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 864 | uint8_t u8x8_d_ssd1306_48x64_winstar(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 865 | uint8_t u8x8_d_ssd1306_64x32_noname(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 866 | uint8_t u8x8_d_ssd1306_64x32_1f(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 867 | uint8_t u8x8_d_ssd1306_96x16_er(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 868 | uint8_t u8x8_d_ssd1306_96x40(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 869 | uint8_t u8x8_d_ssd1306_96x39(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 870 | uint8_t u8x8_d_ssd1306_72x40_er(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 871 | uint8_t u8x8_d_sh1106_128x64_noname(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 872 | uint8_t u8x8_d_sh1106_128x64_vcomh0(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 873 | uint8_t u8x8_d_sh1106_128x64_winstar(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 874 | uint8_t u8x8_d_sh1106_128x32_visionox(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); // located in ssd1306_128x32 |
| 875 | uint8_t u8x8_d_sh1106_72x40_wise(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 876 | uint8_t u8x8_d_sh1106_64x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 877 | uint8_t u8x8_d_sh1107_64x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 878 | uint8_t u8x8_d_sh1107_seeed_96x96(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 879 | uint8_t u8x8_d_sh1107_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 880 | uint8_t u8x8_d_sh1107_128x80(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 881 | uint8_t u8x8_d_sh1107_pimoroni_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 882 | uint8_t u8x8_d_sh1107_seeed_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 883 | uint8_t u8x8_d_sh1107_hjr_oel1m0201_96x96(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 884 | uint8_t u8x8_d_sh1107_tk078f288_80x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 885 | uint8_t u8x8_d_sh1108_128x160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 886 | uint8_t u8x8_d_sh1108_160x160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 887 | uint8_t u8x8_d_ch1120_128x160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 888 | uint8_t u8x8_d_sh1122_256x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 889 | uint8_t u8x8_d_st7920_128x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 890 | uint8_t u8x8_d_st7920_144x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 891 | uint8_t u8x8_d_st7920_160x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 892 | uint8_t u8x8_d_st7920_192x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 893 | uint8_t u8x8_d_st7920_256x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 894 | uint8_t u8x8_d_st7920_128x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 895 | uint8_t u8x8_d_ls013b7dh03_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 896 | uint8_t u8x8_d_ls027b7dh01_400x240(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 897 | uint8_t u8x8_d_ls027b7dh01_m0_400x240(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 898 | uint8_t u8x8_d_ls013b7dh05_144x168(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 899 | uint8_t u8x8_d_ls011b7dh03_160x68(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 900 | uint8_t u8x8_d_st7511_avd_320x240(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 901 | uint8_t u8x8_d_st7511_640x320(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 902 | uint8_t u8x8_d_st7528_nhd_c160100(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 903 | uint8_t u8x8_d_st7528_erc16064(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 904 | uint8_t u8x8_d_st7539_192x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 905 | uint8_t u8x8_d_st7565_ea_dogm128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 906 | uint8_t u8x8_d_st7565_lm6063(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 907 | uint8_t u8x8_d_st7565_64128n(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 908 | uint8_t u8x8_d_st7565_ea_dogm132(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 909 | uint8_t u8x8_d_st7565_zolen_128x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 910 | uint8_t u8x8_d_st7565_nhd_c12832(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 911 | uint8_t u8x8_d_st7565_nhd_c12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 912 | uint8_t u8x8_d_st7565_jlx12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 913 | uint8_t u8x8_d_st7565_lm6059(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 914 | uint8_t u8x8_d_st7565_ks0713(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 915 | uint8_t u8x8_d_st7565_lx12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 916 | uint8_t u8x8_d_st7565_erc12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 917 | uint8_t u8x8_d_st7565_erc12864_alt(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* issue #790 */ |
| 918 | uint8_t u8x8_d_st7567_pi_132x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 919 | uint8_t u8x8_d_st7567_jlx12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 920 | uint8_t u8x8_d_st7567_122x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 921 | uint8_t u8x8_d_st7567_enh_dg128064(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 922 | uint8_t u8x8_d_st7567_enh_dg128064i(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 923 | uint8_t u8x8_d_st7567_64x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 924 | uint8_t u8x8_d_st7567_hem6432(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 925 | uint8_t u8x8_d_st7567_os12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 926 | uint8_t u8x8_d_st7567_erc13232(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 927 | uint8_t u8x8_d_st7567_erc12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 928 | uint8_t u8x8_d_st7567_lw12832(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 929 | uint8_t u8x8_d_st7567_yxd12832(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 930 | uint8_t u8x8_d_st7567_96x65(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 931 | uint8_t u8x8_d_st7571_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 932 | uint8_t u8x8_d_st7571_128x96(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 933 | uint8_t u8x8_d_st7571_g12896(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 934 | uint8_t u8x8_d_st7302_122x250(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 935 | uint8_t u8x8_d_st7305_122x250(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 936 | uint8_t u8x8_d_st7305_200x200(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 937 | uint8_t u8x8_d_st7305_168x384(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* https://github.com/olikraus/u8g2/issues/2661 */ |
| 938 | uint8_t u8x8_d_st7305_300x400(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* https://github.com/olikraus/u8g2/issues/2661 */ |
| 939 | uint8_t u8x8_d_st7586s_s028hn118a(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 940 | uint8_t u8x8_d_st7586s_jlx384160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 941 | uint8_t u8x8_d_st7586s_erc240160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 942 | uint8_t u8x8_d_st7586s_ymc240160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 943 | uint8_t u8x8_d_st7586s_jlx320160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 944 | uint8_t u8x8_d_st7586s_md240128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 945 | uint8_t u8x8_d_st7588_jlx12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 946 | uint8_t u8x8_d_st75160_jm16096(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 947 | uint8_t u8x8_d_st75161_jlx160160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 948 | uint8_t u8x8_d_st75256_jlx256128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 949 | uint8_t u8x8_d_st75256_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* https://github.com/olikraus/u8g2/issues/2702 */ |
| 950 | uint8_t u8x8_d_st75256_wo256x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 951 | uint8_t u8x8_d_st75256_jlx256160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 952 | uint8_t u8x8_d_st75256_jlx256160m(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 953 | uint8_t u8x8_d_st75256_jlx256160_alt(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 954 | uint8_t u8x8_d_st75256_jlx240160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 955 | uint8_t u8x8_d_st75256_jlx25664(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 956 | uint8_t u8x8_d_st75256_jlx172104(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 957 | uint8_t u8x8_d_st75256_jlx19296(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 958 | uint8_t u8x8_d_st75256_jlx16080(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 959 | uint8_t u8x8_d_st75320_jlx320240(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* https://github.com/olikraus/u8g2/issues/921 */ |
| 960 | uint8_t u8x8_d_nt7534_tg12864r(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* u8x8_d_st7565.c */ |
| 961 | uint8_t u8x8_d_ld7032_60x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 962 | uint8_t u8x8_d_ld7032_60x32_alt(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 963 | uint8_t u8x8_d_ld7032_128x36(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 964 | uint8_t u8x8_d_t6963_240x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 965 | uint8_t u8x8_d_t6963_240x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 966 | uint8_t u8x8_d_t6963_128x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 967 | uint8_t u8x8_d_t6963_128x64_alt(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 968 | uint8_t u8x8_d_t6963_160x80(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 969 | uint8_t u8x8_d_t6963_256x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 970 | uint8_t u8x8_d_t6963_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 971 | uint8_t u8x8_d_t6963_128x160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 972 | uint8_t u8x8_d_ssd1316_128x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 973 | uint8_t u8x8_d_ssd1316_96x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 974 | uint8_t u8x8_d_ssd1317_96x96(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 975 | uint8_t u8x8_d_ssd1318_128x96(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 976 | uint8_t u8x8_d_ssd1318_128x96_xcp(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 977 | uint8_t u8x8_d_ssd1320_160x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 978 | uint8_t u8x8_d_ssd1320_160x132(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 979 | uint8_t u8x8_d_ssd1320_160x80(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 980 | uint8_t u8x8_d_ssd1320_128x72(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 981 | uint8_t u8x8_d_ssd1322_240x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 982 | uint8_t u8x8_d_ssd1322_topwin_240x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 983 | uint8_t u8x8_d_ssd1322_nhd_256x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 984 | uint8_t u8x8_d_ssd1322_zjy_256x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 985 | uint8_t u8x8_d_ssd1322_nhd_128x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 986 | uint8_t u8x8_d_ssd1362z_256x64_oel1m0033we(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 987 | uint8_t u8x8_d_ssd1362_256x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 988 | uint8_t u8x8_d_ssd1362_206x36(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 989 | uint8_t u8x8_d_ssd1363_256x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 990 | uint8_t u8x8_d_a2printer_384x240(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 991 | uint8_t u8x8_d_sed1330_240x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 992 | uint8_t u8x8_d_sed1330_240x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 993 | uint8_t u8x8_d_sed1330_256x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 994 | uint8_t u8x8_d_sed1330_320x200(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 995 | uint8_t u8x8_d_ra8835_nhd_240x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 996 | uint8_t u8x8_d_ra8835_320x240(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 997 | uint8_t u8x8_d_ssd1325_nhd_128x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 998 | uint8_t u8x8_d_ssd0323_os128064(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 999 | uint8_t u8x8_d_ssd1327_ws_96x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1000 | uint8_t u8x8_d_ssd1327_seeed_96x96(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1001 | uint8_t u8x8_d_ssd1327_ea_w128128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1002 | uint8_t u8x8_d_ssd1327_midas_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1003 | uint8_t u8x8_d_ssd1327_zjy_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1004 | uint8_t u8x8_d_ssd1327_ws_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1005 | uint8_t u8x8_d_ssd1327_visionox_128x96(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1006 | uint8_t u8x8_d_ssd1326_er_256x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1007 | uint8_t u8x8_d_ssd1329_128x96_noname(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1008 | uint8_t u8x8_d_ssd1329_96x96_noname(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1009 | uint8_t u8x8_d_uc1601_128x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1010 | uint8_t u8x8_d_uc1601_128x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1011 | uint8_t u8x8_d_uc1604_jlx12864(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1012 | uint8_t u8x8_d_uc1604_jlx19264(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1013 | uint8_t u8x8_d_uc1608_erc24064(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1014 | uint8_t u8x8_d_uc1608_dem240064(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1015 | uint8_t u8x8_d_uc1608_erc240120(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1016 | uint8_t u8x8_d_uc1608_240x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1017 | uint8_t u8x8_d_uc1609_slg19264(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1018 | uint8_t u8x8_d_uc1610_ea_dogxl160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1019 | uint8_t u8x8_d_uc1611_ea_dogm240(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1020 | uint8_t u8x8_d_uc1611_ea_dogxl240(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1021 | uint8_t u8x8_d_uc1611_ew50850(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* 240x160 */ |
| 1022 | uint8_t u8x8_d_uc1611_cg160160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* 160x160 */ |
| 1023 | uint8_t u8x8_d_uc1617_jlx128128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1024 | uint8_t u8x8_d_uc1611_ids4073(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* 256x128 */ |
| 1025 | uint8_t u8x8_d_uc1628_128x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1026 | uint8_t u8x8_d_uc1628_256x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1027 | uint8_t u8x8_d_uc1628_256x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1028 | uint8_t u8x8_d_uc1638_160x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1029 | uint8_t u8x8_d_uc1638_192x96(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1030 | uint8_t u8x8_d_uc1638_240x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1031 | uint8_t u8x8_d_uc1698_160x160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1032 | uint8_t u8x8_d_ks0108_128x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1033 | uint8_t u8x8_d_ks0108_erm19264(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1034 | uint8_t u8x8_d_t7932_150x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* t7932 and hd44102 are compatible */ |
| 1035 | uint8_t u8x8_d_hd44102_100x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* t7932 and hd44102 are compatible */ |
| 1036 | uint8_t u8x8_d_sbn1661_122x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1037 | uint8_t u8x8_d_sed1520_122x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1038 | uint8_t u8x8_d_pcd8544_84x48(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1039 | uint8_t u8x8_d_pcf8812_96x65(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1040 | uint8_t u8x8_d_pcf8812_101x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1041 | uint8_t u8x8_d_hx1230_96x68(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1042 | uint8_t u8x8_d_ssd1606_172x72(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1043 | uint8_t u8x8_d_ssd1607_200x200(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1044 | uint8_t u8x8_d_ssd1607_v2_200x200(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1045 | uint8_t u8x8_d_ssd1607_gd_200x200(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1046 | uint8_t u8x8_d_ssd1607_ws_200x200(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); /* issue 637 */ |
| 1047 | uint8_t u8x8_d_il3820_296x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1048 | uint8_t u8x8_d_il3820_v2_296x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1049 | uint8_t u8x8_d_lc7981_160x80(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1050 | uint8_t u8x8_d_lc7981_160x160(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1051 | uint8_t u8x8_d_lc7981_240x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1052 | uint8_t u8x8_d_lc7981_240x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1053 | uint8_t u8x8_d_lc7981_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1054 | uint8_t u8x8_d_ist3020_erc19264(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1055 | uint8_t u8x8_d_ist3088_320x240(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1056 | uint8_t u8x8_d_ist7920_128x128(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1057 | uint8_t u8x8_d_max7219_64x8(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1058 | uint8_t u8x8_d_max7219_32x8(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1059 | uint8_t u8x8_d_max7219_16x16(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1060 | uint8_t u8x8_d_max7219_8x8(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1061 | uint8_t u8x8_d_s1d15e06_160100(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1062 | uint8_t u8x8_d_s1d15300_lm6023(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1063 | uint8_t u8x8_d_s1d15300_97x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1064 | uint8_t u8x8_d_s1d15300_100x32(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1065 | uint8_t u8x8_d_s1d15300_100x32i(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1066 | uint8_t u8x8_d_s1d15721_240x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1067 | uint8_t u8x8_d_gu800_128x64(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1068 | uint8_t u8x8_d_gu800_160x16(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1069 | uint8_t u8x8_d_gp1287ai_256x50(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1070 | uint8_t u8x8_d_gp1247ai_253x63(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1071 | uint8_t u8x8_d_gp1294ai_256x48(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1072 | uint8_t u8x8_d_ssd1315_128x64_noname(u8x8_t *u8x8, uint8_t msg, uint8_t arg_int, void *arg_ptr); |
| 1073 | |
| 1074 | |
| 1075 | /*==========================================*/ |
| 1076 | /* u8x8_8x8.c */ |
| 1077 | |
| 1078 | uint16_t u8x8_upscale_byte(uint8_t x) U8X8_NOINLINE; |
| 1079 | |
| 1080 | void u8x8_get_glyph_data(u8x8_t *u8x8, uint8_t encoding, uint8_t *buf, uint8_t tile_offset) U8X8_NOINLINE; |
| 1081 | |
| 1082 | void u8x8_utf8_init(u8x8_t *u8x8); |
| 1083 | uint16_t u8x8_ascii_next(u8x8_t *u8x8, uint8_t b); |
| 1084 | uint16_t u8x8_utf8_next(u8x8_t *u8x8, uint8_t b); |
| 1085 | // the following two functions are replaced by the init/next functions |
| 1086 | //uint16_t u8x8_get_encoding_from_utf8_string(const char **str); |
| 1087 | //uint16_t u8x8_get_char_from_string(const char **str); |
| 1088 | |
| 1089 | void u8x8_SetFont(u8x8_t *u8x8, const uint8_t *font_8x8); |
| 1090 | void u8x8_DrawGlyph(u8x8_t *u8x8, uint8_t x, uint8_t y, uint8_t encoding); |
| 1091 | void u8x8_Draw2x2Glyph(u8x8_t *u8x8, uint8_t x, uint8_t y, uint8_t encoding); |
| 1092 | void u8x8_Draw1x2Glyph(u8x8_t *u8x8, uint8_t x, uint8_t y, uint8_t encoding); |
| 1093 | uint8_t u8x8_DrawString(u8x8_t *u8x8, uint8_t x, uint8_t y, const char *s); |
| 1094 | uint8_t u8x8_DrawUTF8(u8x8_t *u8x8, uint8_t x, uint8_t y, const char *s); /* return number of glyps */ |
| 1095 | uint8_t u8x8_Draw2x2String(u8x8_t *u8x8, uint8_t x, uint8_t y, const char *s); |
| 1096 | uint8_t u8x8_Draw2x2UTF8(u8x8_t *u8x8, uint8_t x, uint8_t y, const char *s); |
| 1097 | uint8_t u8x8_Draw1x2String(u8x8_t *u8x8, uint8_t x, uint8_t y, const char *s); |
| 1098 | uint8_t u8x8_Draw1x2UTF8(u8x8_t *u8x8, uint8_t x, uint8_t y, const char *s); |
| 1099 | uint8_t u8x8_GetUTF8Len(u8x8_t *u8x8, const char *s); |
| 1100 | #define u8x8_SetInverseFont(u8x8, b) (u8x8)->is_font_inverse_mode = (b) |
| 1101 | |
| 1102 | /*==========================================*/ |
| 1103 | /* itoa procedures */ |
| 1104 | const char *u8x8_u8toa(uint8_t v, uint8_t d); |
| 1105 | const char *u8x8_s8toa(int8_t v, uint8_t d); |
| 1106 | const char *u8x8_u8tox(uint8_t v, uint8_t d); |
| 1107 | const char *u8x8_u16toa(uint16_t v, uint8_t d); |
| 1108 | const char *u8x8_utoa(uint16_t v); |
| 1109 | |
| 1110 | |
| 1111 | /*==========================================*/ |
| 1112 | /* u8x8_string.c */ |
| 1113 | |
| 1114 | uint8_t u8x8_GetStringLineCnt(const char *str); /* return 0 for str==NULL */ |
| 1115 | const char *u8x8_GetStringLineStart(uint8_t line_idx, const char *str ); |
| 1116 | void u8x8_CopyStringLine(char *dest, uint8_t line_idx, const char *str); |
| 1117 | /* draw one line, consider \t for center */ |
| 1118 | uint8_t u8x8_DrawUTF8Line(u8x8_t *u8x8, uint8_t x, uint8_t y, uint8_t w, const char *s); |
| 1119 | /* draw multiple lines, handle \t */ |
| 1120 | uint8_t u8x8_DrawUTF8Lines(u8x8_t *u8x8, uint8_t x, uint8_t y, uint8_t w, const char *s); |
| 1121 | |
| 1122 | /*==========================================*/ |
| 1123 | |
| 1124 | /* u8x8_selection_list.c */ |
| 1125 | struct _u8sl_struct |
| 1126 | { |
| 1127 | uint8_t visible; /* number of visible elements in the menu */ |
| 1128 | uint8_t total; /* total number of elements in the menu */ |
| 1129 | uint8_t first_pos; /* position of the first visible line */ |
| 1130 | uint8_t current_pos; /* current cursor position, starts at 0 */ |
| 1131 | |
| 1132 | uint8_t x; /* u8x8 only, not used in u8g2 */ |
| 1133 | uint8_t y; /* u8x8 only, not used in u8g2 */ |
| 1134 | }; |
| 1135 | typedef struct _u8sl_struct u8sl_t; |
| 1136 | |
| 1137 | typedef void (*u8x8_sl_cb)(u8x8_t *u8x8, u8sl_t *u8sl, uint8_t idx, const void *aux); |
| 1138 | |
| 1139 | void u8sl_Next(u8sl_t *u8sl); |
| 1140 | void u8sl_Prev(u8sl_t *u8sl); |
| 1141 | |
| 1142 | uint8_t u8x8_UserInterfaceSelectionList(u8x8_t *u8x8, const char *title, uint8_t start_pos, const char *sl); |
| 1143 | |
| 1144 | /*==========================================*/ |
| 1145 | |
| 1146 | /* u8x8_message.c */ |
| 1147 | uint8_t u8x8_UserInterfaceMessage(u8x8_t *u8x8, const char *title1, const char *title2, const char *title3, const char *buttons); |
| 1148 | |
| 1149 | /*==========================================*/ |
| 1150 | /* u8x8_capture.c */ |
| 1151 | |
| 1152 | /* vertical_top memory architecture */ |
| 1153 | uint8_t u8x8_capture_get_pixel_1(uint16_t x, uint16_t y, uint8_t *dest_ptr, uint8_t tile_width); |
| 1154 | |
| 1155 | /* horizontal right memory architecture */ |
| 1156 | /* SH1122, LD7032, ST7920, ST7986, LC7981, T6963, SED1330, RA8835, MAX7219, LS0 */ |
| 1157 | uint8_t u8x8_capture_get_pixel_2(uint16_t x, uint16_t y, uint8_t *dest_ptr, uint8_t tile_width); |
| 1158 | |
| 1159 | |
| 1160 | |
| 1161 | void u8x8_capture_write_pbm_pre(uint8_t tile_width, uint8_t tile_height, void (*out)(const char *s)); |
| 1162 | void u8x8_capture_write_pbm_buffer(uint8_t *buffer, uint8_t tile_width, uint8_t tile_height, uint8_t (*get_pixel)(uint16_t x, uint16_t y, uint8_t *dest_ptr, uint8_t tile_width), void (*out)(const char *s)); |
| 1163 | |
| 1164 | void u8x8_capture_write_xbm_pre(uint8_t tile_width, uint8_t tile_height, void (*out)(const char *s)); |
| 1165 | void u8x8_capture_write_xbm_buffer(uint8_t *buffer, uint8_t tile_width, uint8_t tile_height, uint8_t (*get_pixel)(uint16_t x, uint16_t y, uint8_t *dest_ptr, uint8_t tile_width), void (*out)(const char *s)); |
| 1166 | |
| 1167 | |
| 1168 | |
| 1169 | /*==========================================*/ |
| 1170 | |
| 1171 | /* u8x8_input_value.c */ |
| 1172 | |
| 1173 | uint8_t u8x8_UserInterfaceInputValue(u8x8_t *u8x8, const char *title, const char *pre, uint8_t *value, uint8_t lo, uint8_t hi, uint8_t digits, const char *post); |
| 1174 | |
| 1175 | /*==========================================*/ |
| 1176 | /* u8log.c */ |
| 1177 | void u8log_Init(u8log_t *u8log, uint8_t width, uint8_t height, uint8_t *buf); |
| 1178 | void u8log_SetCallback(u8log_t *u8log, u8log_cb cb, void *aux_data); |
| 1179 | void u8log_SetRedrawMode(u8log_t *u8log, uint8_t is_redraw_line_for_each_char); |
| 1180 | void u8log_SetLineHeightOffset(u8log_t *u8log, int8_t line_height_offset); |
| 1181 | void u8log_WriteString(u8log_t *u8log, const char *s) U8X8_NOINLINE; |
| 1182 | void u8log_WriteChar(u8log_t *u8log, uint8_t c) U8X8_NOINLINE; |
| 1183 | void u8log_WriteHex8(u8log_t *u8log, uint8_t b) U8X8_NOINLINE; |
| 1184 | void u8log_WriteHex16(u8log_t *u8log, uint16_t v); |
| 1185 | void u8log_WriteHex32(u8log_t *u8log, uint32_t v); |
| 1186 | void u8log_WriteDec8(u8log_t *u8log, uint8_t v, uint8_t d); |
| 1187 | void u8log_WriteDec16(u8log_t *u8log, uint16_t v, uint8_t d); |
| 1188 | |
| 1189 | /*==========================================*/ |
| 1190 | /* u8log_u8x8.c */ |
| 1191 | void u8x8_DrawLog(u8x8_t *u8x8, uint8_t x, uint8_t y, u8log_t *u8log); |
| 1192 | void u8log_u8x8_cb(u8log_t * u8log); |
| 1193 | |
| 1194 | |
| 1195 | /*==========================================*/ |
| 1196 | /* start font list */ |
| 1197 | extern const uint8_t u8x8_font_amstrad_cpc_extended_f[] U8X8_FONT_SECTION("u8x8_font_amstrad_cpc_extended_f"); |
| 1198 | extern const uint8_t u8x8_font_amstrad_cpc_extended_r[] U8X8_FONT_SECTION("u8x8_font_amstrad_cpc_extended_r"); |
| 1199 | extern const uint8_t u8x8_font_amstrad_cpc_extended_n[] U8X8_FONT_SECTION("u8x8_font_amstrad_cpc_extended_n"); |
| 1200 | extern const uint8_t u8x8_font_amstrad_cpc_extended_u[] U8X8_FONT_SECTION("u8x8_font_amstrad_cpc_extended_u"); |
| 1201 | extern const uint8_t u8x8_font_5x7_f[] U8X8_FONT_SECTION("u8x8_font_5x7_f"); |
| 1202 | extern const uint8_t u8x8_font_5x7_r[] U8X8_FONT_SECTION("u8x8_font_5x7_r"); |
| 1203 | extern const uint8_t u8x8_font_5x7_n[] U8X8_FONT_SECTION("u8x8_font_5x7_n"); |
| 1204 | extern const uint8_t u8x8_font_5x8_f[] U8X8_FONT_SECTION("u8x8_font_5x8_f"); |
| 1205 | extern const uint8_t u8x8_font_5x8_r[] U8X8_FONT_SECTION("u8x8_font_5x8_r"); |
| 1206 | extern const uint8_t u8x8_font_5x8_n[] U8X8_FONT_SECTION("u8x8_font_5x8_n"); |
| 1207 | extern const uint8_t u8x8_font_8x13_1x2_f[] U8X8_FONT_SECTION("u8x8_font_8x13_1x2_f"); |
| 1208 | extern const uint8_t u8x8_font_8x13_1x2_r[] U8X8_FONT_SECTION("u8x8_font_8x13_1x2_r"); |
| 1209 | extern const uint8_t u8x8_font_8x13_1x2_n[] U8X8_FONT_SECTION("u8x8_font_8x13_1x2_n"); |
| 1210 | extern const uint8_t u8x8_font_8x13B_1x2_f[] U8X8_FONT_SECTION("u8x8_font_8x13B_1x2_f"); |
| 1211 | extern const uint8_t u8x8_font_8x13B_1x2_r[] U8X8_FONT_SECTION("u8x8_font_8x13B_1x2_r"); |
| 1212 | extern const uint8_t u8x8_font_8x13B_1x2_n[] U8X8_FONT_SECTION("u8x8_font_8x13B_1x2_n"); |
| 1213 | extern const uint8_t u8x8_font_7x14_1x2_f[] U8X8_FONT_SECTION("u8x8_font_7x14_1x2_f"); |
| 1214 | extern const uint8_t u8x8_font_7x14_1x2_r[] U8X8_FONT_SECTION("u8x8_font_7x14_1x2_r"); |
| 1215 | extern const uint8_t u8x8_font_7x14_1x2_n[] U8X8_FONT_SECTION("u8x8_font_7x14_1x2_n"); |
| 1216 | extern const uint8_t u8x8_font_7x14B_1x2_f[] U8X8_FONT_SECTION("u8x8_font_7x14B_1x2_f"); |
| 1217 | extern const uint8_t u8x8_font_7x14B_1x2_r[] U8X8_FONT_SECTION("u8x8_font_7x14B_1x2_r"); |
| 1218 | extern const uint8_t u8x8_font_7x14B_1x2_n[] U8X8_FONT_SECTION("u8x8_font_7x14B_1x2_n"); |
| 1219 | extern const uint8_t u8x8_font_open_iconic_arrow_1x1[] U8X8_FONT_SECTION("u8x8_font_open_iconic_arrow_1x1"); |
| 1220 | extern const uint8_t u8x8_font_open_iconic_check_1x1[] U8X8_FONT_SECTION("u8x8_font_open_iconic_check_1x1"); |
| 1221 | extern const uint8_t u8x8_font_open_iconic_embedded_1x1[] U8X8_FONT_SECTION("u8x8_font_open_iconic_embedded_1x1"); |
| 1222 | extern const uint8_t u8x8_font_open_iconic_play_1x1[] U8X8_FONT_SECTION("u8x8_font_open_iconic_play_1x1"); |
| 1223 | extern const uint8_t u8x8_font_open_iconic_thing_1x1[] U8X8_FONT_SECTION("u8x8_font_open_iconic_thing_1x1"); |
| 1224 | extern const uint8_t u8x8_font_open_iconic_weather_1x1[] U8X8_FONT_SECTION("u8x8_font_open_iconic_weather_1x1"); |
| 1225 | extern const uint8_t u8x8_font_open_iconic_arrow_2x2[] U8X8_FONT_SECTION("u8x8_font_open_iconic_arrow_2x2"); |
| 1226 | extern const uint8_t u8x8_font_open_iconic_check_2x2[] U8X8_FONT_SECTION("u8x8_font_open_iconic_check_2x2"); |
| 1227 | extern const uint8_t u8x8_font_open_iconic_embedded_2x2[] U8X8_FONT_SECTION("u8x8_font_open_iconic_embedded_2x2"); |
| 1228 | extern const uint8_t u8x8_font_open_iconic_play_2x2[] U8X8_FONT_SECTION("u8x8_font_open_iconic_play_2x2"); |
| 1229 | extern const uint8_t u8x8_font_open_iconic_thing_2x2[] U8X8_FONT_SECTION("u8x8_font_open_iconic_thing_2x2"); |
| 1230 | extern const uint8_t u8x8_font_open_iconic_weather_2x2[] U8X8_FONT_SECTION("u8x8_font_open_iconic_weather_2x2"); |
| 1231 | extern const uint8_t u8x8_font_open_iconic_arrow_4x4[] U8X8_FONT_SECTION("u8x8_font_open_iconic_arrow_4x4"); |
| 1232 | extern const uint8_t u8x8_font_open_iconic_check_4x4[] U8X8_FONT_SECTION("u8x8_font_open_iconic_check_4x4"); |
| 1233 | extern const uint8_t u8x8_font_open_iconic_embedded_4x4[] U8X8_FONT_SECTION("u8x8_font_open_iconic_embedded_4x4"); |
| 1234 | extern const uint8_t u8x8_font_open_iconic_play_4x4[] U8X8_FONT_SECTION("u8x8_font_open_iconic_play_4x4"); |
| 1235 | extern const uint8_t u8x8_font_open_iconic_thing_4x4[] U8X8_FONT_SECTION("u8x8_font_open_iconic_thing_4x4"); |
| 1236 | extern const uint8_t u8x8_font_open_iconic_weather_4x4[] U8X8_FONT_SECTION("u8x8_font_open_iconic_weather_4x4"); |
| 1237 | extern const uint8_t u8x8_font_open_iconic_arrow_8x8[] U8X8_FONT_SECTION("u8x8_font_open_iconic_arrow_8x8"); |
| 1238 | extern const uint8_t u8x8_font_open_iconic_check_8x8[] U8X8_FONT_SECTION("u8x8_font_open_iconic_check_8x8"); |
| 1239 | extern const uint8_t u8x8_font_open_iconic_embedded_8x8[] U8X8_FONT_SECTION("u8x8_font_open_iconic_embedded_8x8"); |
| 1240 | extern const uint8_t u8x8_font_open_iconic_play_8x8[] U8X8_FONT_SECTION("u8x8_font_open_iconic_play_8x8"); |
| 1241 | extern const uint8_t u8x8_font_open_iconic_thing_8x8[] U8X8_FONT_SECTION("u8x8_font_open_iconic_thing_8x8"); |
| 1242 | extern const uint8_t u8x8_font_open_iconic_weather_8x8[] U8X8_FONT_SECTION("u8x8_font_open_iconic_weather_8x8"); |
| 1243 | extern const uint8_t u8x8_font_profont29_2x3_f[] U8X8_FONT_SECTION("u8x8_font_profont29_2x3_f"); |
| 1244 | extern const uint8_t u8x8_font_profont29_2x3_r[] U8X8_FONT_SECTION("u8x8_font_profont29_2x3_r"); |
| 1245 | extern const uint8_t u8x8_font_profont29_2x3_n[] U8X8_FONT_SECTION("u8x8_font_profont29_2x3_n"); |
| 1246 | extern const uint8_t u8x8_font_artossans8_r[] U8X8_FONT_SECTION("u8x8_font_artossans8_r"); |
| 1247 | extern const uint8_t u8x8_font_artossans8_n[] U8X8_FONT_SECTION("u8x8_font_artossans8_n"); |
| 1248 | extern const uint8_t u8x8_font_artossans8_u[] U8X8_FONT_SECTION("u8x8_font_artossans8_u"); |
| 1249 | extern const uint8_t u8x8_font_artosserif8_r[] U8X8_FONT_SECTION("u8x8_font_artosserif8_r"); |
| 1250 | extern const uint8_t u8x8_font_artosserif8_n[] U8X8_FONT_SECTION("u8x8_font_artosserif8_n"); |
| 1251 | extern const uint8_t u8x8_font_artosserif8_u[] U8X8_FONT_SECTION("u8x8_font_artosserif8_u"); |
| 1252 | extern const uint8_t u8x8_font_chroma48medium8_r[] U8X8_FONT_SECTION("u8x8_font_chroma48medium8_r"); |
| 1253 | extern const uint8_t u8x8_font_chroma48medium8_n[] U8X8_FONT_SECTION("u8x8_font_chroma48medium8_n"); |
| 1254 | extern const uint8_t u8x8_font_chroma48medium8_u[] U8X8_FONT_SECTION("u8x8_font_chroma48medium8_u"); |
| 1255 | extern const uint8_t u8x8_font_saikyosansbold8_n[] U8X8_FONT_SECTION("u8x8_font_saikyosansbold8_n"); |
| 1256 | extern const uint8_t u8x8_font_saikyosansbold8_u[] U8X8_FONT_SECTION("u8x8_font_saikyosansbold8_u"); |
| 1257 | extern const uint8_t u8x8_font_torussansbold8_r[] U8X8_FONT_SECTION("u8x8_font_torussansbold8_r"); |
| 1258 | extern const uint8_t u8x8_font_torussansbold8_n[] U8X8_FONT_SECTION("u8x8_font_torussansbold8_n"); |
| 1259 | extern const uint8_t u8x8_font_torussansbold8_u[] U8X8_FONT_SECTION("u8x8_font_torussansbold8_u"); |
| 1260 | extern const uint8_t u8x8_font_victoriabold8_r[] U8X8_FONT_SECTION("u8x8_font_victoriabold8_r"); |
| 1261 | extern const uint8_t u8x8_font_victoriabold8_n[] U8X8_FONT_SECTION("u8x8_font_victoriabold8_n"); |
| 1262 | extern const uint8_t u8x8_font_victoriabold8_u[] U8X8_FONT_SECTION("u8x8_font_victoriabold8_u"); |
| 1263 | extern const uint8_t u8x8_font_victoriamedium8_r[] U8X8_FONT_SECTION("u8x8_font_victoriamedium8_r"); |
| 1264 | extern const uint8_t u8x8_font_victoriamedium8_n[] U8X8_FONT_SECTION("u8x8_font_victoriamedium8_n"); |
| 1265 | extern const uint8_t u8x8_font_victoriamedium8_u[] U8X8_FONT_SECTION("u8x8_font_victoriamedium8_u"); |
| 1266 | extern const uint8_t u8x8_font_courB18_2x3_f[] U8X8_FONT_SECTION("u8x8_font_courB18_2x3_f"); |
| 1267 | extern const uint8_t u8x8_font_courB18_2x3_r[] U8X8_FONT_SECTION("u8x8_font_courB18_2x3_r"); |
| 1268 | extern const uint8_t u8x8_font_courB18_2x3_n[] U8X8_FONT_SECTION("u8x8_font_courB18_2x3_n"); |
| 1269 | extern const uint8_t u8x8_font_courR18_2x3_f[] U8X8_FONT_SECTION("u8x8_font_courR18_2x3_f"); |
| 1270 | extern const uint8_t u8x8_font_courR18_2x3_r[] U8X8_FONT_SECTION("u8x8_font_courR18_2x3_r"); |
| 1271 | extern const uint8_t u8x8_font_courR18_2x3_n[] U8X8_FONT_SECTION("u8x8_font_courR18_2x3_n"); |
| 1272 | extern const uint8_t u8x8_font_courB24_3x4_f[] U8X8_FONT_SECTION("u8x8_font_courB24_3x4_f"); |
| 1273 | extern const uint8_t u8x8_font_courB24_3x4_r[] U8X8_FONT_SECTION("u8x8_font_courB24_3x4_r"); |
| 1274 | extern const uint8_t u8x8_font_courB24_3x4_n[] U8X8_FONT_SECTION("u8x8_font_courB24_3x4_n"); |
| 1275 | extern const uint8_t u8x8_font_courR24_3x4_f[] U8X8_FONT_SECTION("u8x8_font_courR24_3x4_f"); |
| 1276 | extern const uint8_t u8x8_font_courR24_3x4_r[] U8X8_FONT_SECTION("u8x8_font_courR24_3x4_r"); |
| 1277 | extern const uint8_t u8x8_font_courR24_3x4_n[] U8X8_FONT_SECTION("u8x8_font_courR24_3x4_n"); |
| 1278 | extern const uint8_t u8x8_font_lucasarts_scumm_subtitle_o_2x2_f[] U8X8_FONT_SECTION("u8x8_font_lucasarts_scumm_subtitle_o_2x2_f"); |
| 1279 | extern const uint8_t u8x8_font_lucasarts_scumm_subtitle_o_2x2_r[] U8X8_FONT_SECTION("u8x8_font_lucasarts_scumm_subtitle_o_2x2_r"); |
| 1280 | extern const uint8_t u8x8_font_lucasarts_scumm_subtitle_o_2x2_n[] U8X8_FONT_SECTION("u8x8_font_lucasarts_scumm_subtitle_o_2x2_n"); |
| 1281 | extern const uint8_t u8x8_font_lucasarts_scumm_subtitle_r_2x2_f[] U8X8_FONT_SECTION("u8x8_font_lucasarts_scumm_subtitle_r_2x2_f"); |
| 1282 | extern const uint8_t u8x8_font_lucasarts_scumm_subtitle_r_2x2_r[] U8X8_FONT_SECTION("u8x8_font_lucasarts_scumm_subtitle_r_2x2_r"); |
| 1283 | extern const uint8_t u8x8_font_lucasarts_scumm_subtitle_r_2x2_n[] U8X8_FONT_SECTION("u8x8_font_lucasarts_scumm_subtitle_r_2x2_n"); |
| 1284 | extern const uint8_t u8x8_font_inr21_2x4_f[] U8X8_FONT_SECTION("u8x8_font_inr21_2x4_f"); |
| 1285 | extern const uint8_t u8x8_font_inr21_2x4_r[] U8X8_FONT_SECTION("u8x8_font_inr21_2x4_r"); |
| 1286 | extern const uint8_t u8x8_font_inr21_2x4_n[] U8X8_FONT_SECTION("u8x8_font_inr21_2x4_n"); |
| 1287 | extern const uint8_t u8x8_font_inr33_3x6_f[] U8X8_FONT_SECTION("u8x8_font_inr33_3x6_f"); |
| 1288 | extern const uint8_t u8x8_font_inr33_3x6_r[] U8X8_FONT_SECTION("u8x8_font_inr33_3x6_r"); |
| 1289 | extern const uint8_t u8x8_font_inr33_3x6_n[] U8X8_FONT_SECTION("u8x8_font_inr33_3x6_n"); |
| 1290 | extern const uint8_t u8x8_font_inr46_4x8_f[] U8X8_FONT_SECTION("u8x8_font_inr46_4x8_f"); |
| 1291 | extern const uint8_t u8x8_font_inr46_4x8_r[] U8X8_FONT_SECTION("u8x8_font_inr46_4x8_r"); |
| 1292 | extern const uint8_t u8x8_font_inr46_4x8_n[] U8X8_FONT_SECTION("u8x8_font_inr46_4x8_n"); |
| 1293 | extern const uint8_t u8x8_font_inb21_2x4_f[] U8X8_FONT_SECTION("u8x8_font_inb21_2x4_f"); |
| 1294 | extern const uint8_t u8x8_font_inb21_2x4_r[] U8X8_FONT_SECTION("u8x8_font_inb21_2x4_r"); |
| 1295 | extern const uint8_t u8x8_font_inb21_2x4_n[] U8X8_FONT_SECTION("u8x8_font_inb21_2x4_n"); |
| 1296 | extern const uint8_t u8x8_font_inb33_3x6_f[] U8X8_FONT_SECTION("u8x8_font_inb33_3x6_f"); |
| 1297 | extern const uint8_t u8x8_font_inb33_3x6_r[] U8X8_FONT_SECTION("u8x8_font_inb33_3x6_r"); |
| 1298 | extern const uint8_t u8x8_font_inb33_3x6_n[] U8X8_FONT_SECTION("u8x8_font_inb33_3x6_n"); |
| 1299 | extern const uint8_t u8x8_font_inb46_4x8_f[] U8X8_FONT_SECTION("u8x8_font_inb46_4x8_f"); |
| 1300 | extern const uint8_t u8x8_font_inb46_4x8_r[] U8X8_FONT_SECTION("u8x8_font_inb46_4x8_r"); |
| 1301 | extern const uint8_t u8x8_font_inb46_4x8_n[] U8X8_FONT_SECTION("u8x8_font_inb46_4x8_n"); |
| 1302 | extern const uint8_t u8x8_font_pressstart2p_f[] U8X8_FONT_SECTION("u8x8_font_pressstart2p_f"); |
| 1303 | extern const uint8_t u8x8_font_pressstart2p_r[] U8X8_FONT_SECTION("u8x8_font_pressstart2p_r"); |
| 1304 | extern const uint8_t u8x8_font_pressstart2p_n[] U8X8_FONT_SECTION("u8x8_font_pressstart2p_n"); |
| 1305 | extern const uint8_t u8x8_font_pressstart2p_u[] U8X8_FONT_SECTION("u8x8_font_pressstart2p_u"); |
| 1306 | extern const uint8_t u8x8_font_pcsenior_f[] U8X8_FONT_SECTION("u8x8_font_pcsenior_f"); |
| 1307 | extern const uint8_t u8x8_font_pcsenior_r[] U8X8_FONT_SECTION("u8x8_font_pcsenior_r"); |
| 1308 | extern const uint8_t u8x8_font_pcsenior_n[] U8X8_FONT_SECTION("u8x8_font_pcsenior_n"); |
| 1309 | extern const uint8_t u8x8_font_pcsenior_u[] U8X8_FONT_SECTION("u8x8_font_pcsenior_u"); |
| 1310 | extern const uint8_t u8x8_font_pxplusibmcgathin_f[] U8X8_FONT_SECTION("u8x8_font_pxplusibmcgathin_f"); |
| 1311 | extern const uint8_t u8x8_font_pxplusibmcgathin_r[] U8X8_FONT_SECTION("u8x8_font_pxplusibmcgathin_r"); |
| 1312 | extern const uint8_t u8x8_font_pxplusibmcgathin_n[] U8X8_FONT_SECTION("u8x8_font_pxplusibmcgathin_n"); |
| 1313 | extern const uint8_t u8x8_font_pxplusibmcgathin_u[] U8X8_FONT_SECTION("u8x8_font_pxplusibmcgathin_u"); |
| 1314 | extern const uint8_t u8x8_font_pxplusibmcga_f[] U8X8_FONT_SECTION("u8x8_font_pxplusibmcga_f"); |
| 1315 | extern const uint8_t u8x8_font_pxplusibmcga_r[] U8X8_FONT_SECTION("u8x8_font_pxplusibmcga_r"); |
| 1316 | extern const uint8_t u8x8_font_pxplusibmcga_n[] U8X8_FONT_SECTION("u8x8_font_pxplusibmcga_n"); |
| 1317 | extern const uint8_t u8x8_font_pxplusibmcga_u[] U8X8_FONT_SECTION("u8x8_font_pxplusibmcga_u"); |
| 1318 | extern const uint8_t u8x8_font_pxplustandynewtv_f[] U8X8_FONT_SECTION("u8x8_font_pxplustandynewtv_f"); |
| 1319 | extern const uint8_t u8x8_font_pxplustandynewtv_r[] U8X8_FONT_SECTION("u8x8_font_pxplustandynewtv_r"); |
| 1320 | extern const uint8_t u8x8_font_pxplustandynewtv_n[] U8X8_FONT_SECTION("u8x8_font_pxplustandynewtv_n"); |
| 1321 | extern const uint8_t u8x8_font_pxplustandynewtv_u[] U8X8_FONT_SECTION("u8x8_font_pxplustandynewtv_u"); |
| 1322 | extern const uint8_t u8x8_font_px437wyse700a_2x2_f[] U8X8_FONT_SECTION("u8x8_font_px437wyse700a_2x2_f"); |
| 1323 | extern const uint8_t u8x8_font_px437wyse700a_2x2_r[] U8X8_FONT_SECTION("u8x8_font_px437wyse700a_2x2_r"); |
| 1324 | extern const uint8_t u8x8_font_px437wyse700a_2x2_n[] U8X8_FONT_SECTION("u8x8_font_px437wyse700a_2x2_n"); |
| 1325 | extern const uint8_t u8x8_font_px437wyse700b_2x2_f[] U8X8_FONT_SECTION("u8x8_font_px437wyse700b_2x2_f"); |
| 1326 | extern const uint8_t u8x8_font_px437wyse700b_2x2_r[] U8X8_FONT_SECTION("u8x8_font_px437wyse700b_2x2_r"); |
| 1327 | extern const uint8_t u8x8_font_px437wyse700b_2x2_n[] U8X8_FONT_SECTION("u8x8_font_px437wyse700b_2x2_n"); |
| 1328 | |
| 1329 | /* end font list */ |
| 1330 | |
| 1331 | |
| 1332 | #ifdef __cplusplus |
| 1333 | } |
| 1334 | #endif |
| 1335 | |
| 1336 | |
| 1337 | #endif /* _U8X8_H */ |
| 1338 | |