From 887bbf391e9433d3bb271cf71f9af07266a07727 Mon Sep 17 00:00:00 2001 From: Christos Choutouridis Date: Mon, 25 Oct 2021 15:57:25 +0300 Subject: [PATCH] DEV: a liquid crystal display driver added --- include/drv/liquid_crystal.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/include/drv/liquid_crystal.h b/include/drv/liquid_crystal.h index f724b9b..f1f5777 100644 --- a/include/drv/liquid_crystal.h +++ b/include/drv/liquid_crystal.h @@ -58,6 +58,7 @@ namespace tbx { * \tparam Impl_t The derived class * \tparam Lines The lines of the LCD * \tparam Columns The coluns of the LCD + * \tparam BusSize The LCD bus size (4 or 8 bits) */ template class liquid_crystal : public Print, char>{ @@ -66,7 +67,8 @@ namespace tbx { static_assert((BusSize == 4) || (BusSize == 8), "BusSize must be either 4 or 8."); public: - + constexpr static size_t lines = Lines; + constexpr static size_t columns = Columns; /*! * Public enumerator to be used as argument to the init() function. * Selects the font size and thus the number of active lines @@ -475,7 +477,7 @@ namespace tbx { home (); break; case '\f': - set_cursor (1, 1); + clear(); break; case '\b': --cursor_;