From b020d4cf62f20bffa4ce3c262c9c9c85802abe68 Mon Sep 17 00:00:00 2001 From: Florent Kermarrec Date: Thu, 12 May 2022 16:08:42 +0200 Subject: [PATCH] cores/video/VideoTerminal: Avoid downloading font is present locally. --- litex/soc/cores/video.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/litex/soc/cores/video.py b/litex/soc/cores/video.py index 613906546..7c21c50f3 100644 --- a/litex/soc/cores/video.py +++ b/litex/soc/cores/video.py @@ -439,8 +439,10 @@ class VideoTerminal(Module): # Font Mem. # --------- - os.system("wget https://github.com/enjoy-digital/litex/files/6076336/ter-u16b.txt") # FIXME: Store Font in LiteX? - os.system("mv ter-u16b.txt ter-u16b.bdf") + # FIXME: Store Font in LiteX? + if not os.path.exists("ter-u16b.bdf"): + os.system("wget https://github.com/enjoy-digital/litex/files/6076336/ter-u16b.txt") + os.system("mv ter-u16b.txt ter-u16b.bdf") font = import_bdf_font("ter-u16b.bdf") font_width = 8 font_heigth = 16