Skip to content

Commit b430631

Browse files
committed
Move terminal font to terminalio from board.
1 parent 5258bc4 commit b430631

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

  • ports/atmel-samd/boards/grandcentral_m4_express
  • shared-bindings/terminalio

ports/atmel-samd/boards/grandcentral_m4_express/pins.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
#include "shared-bindings/board/__init__.h"
22

33
#include "supervisor/shared/board_busses.h"
4-
#include "supervisor/shared/display.h"
54

65
// This mapping only includes functional names because pins broken
76
// out on connectors are labeled with their MCU name available from
@@ -132,7 +131,5 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
132131
{ MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&board_i2c_obj) },
133132
{ MP_ROM_QSTR(MP_QSTR_SPI), MP_ROM_PTR(&board_spi_obj) },
134133
{ MP_ROM_QSTR(MP_QSTR_UART), MP_ROM_PTR(&board_uart_obj) },
135-
136-
{ MP_ROM_QSTR(MP_QSTR_TERMINAL_FONT), MP_ROM_PTR(&supervisor_terminal_font) },
137134
};
138135
MP_DEFINE_CONST_DICT(board_module_globals, board_global_dict_table);

shared-bindings/terminalio/__init__.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131

3232
#include "shared-bindings/terminalio/__init__.h"
3333
#include "shared-bindings/terminalio/Terminal.h"
34+
#include "supervisor/shared/display.h"
3435

3536
#include "py/runtime.h"
3637

@@ -40,7 +41,8 @@
4041
//| .. module:: terminalio
4142
//| :synopsis: Displays text in a TileGrid
4243
//|
43-
//| The `terminalio` module contains classes to display a character stream on a display
44+
//| The `terminalio` module contains classes to display a character stream on a display. The built
45+
//| in font is available as ``terminalio.FONT``.
4446
//|
4547
//| Libraries
4648
//|
@@ -53,6 +55,7 @@
5355
STATIC const mp_rom_map_elem_t terminalio_module_globals_table[] = {
5456
{ MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_terminalio) },
5557
{ MP_ROM_QSTR(MP_QSTR_Terminal), MP_OBJ_FROM_PTR(&terminalio_terminal_type) },
58+
{ MP_ROM_QSTR(MP_QSTR_FONT), MP_ROM_PTR(&supervisor_terminal_font) },
5659
};
5760

5861

0 commit comments

Comments
 (0)