From 91e60b371667763135207e2ac5ea707f7558f8d7 Mon Sep 17 00:00:00 2001 From: pmantoine Date: Fri, 12 Apr 2024 17:25:00 +0800 Subject: [PATCH] HALDisplay bug fix --- IO_HALDisplay.h | 11 +++++++---- version.h | 3 ++- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/IO_HALDisplay.h b/IO_HALDisplay.h index f2ca3af..24ffde7 100644 --- a/IO_HALDisplay.h +++ b/IO_HALDisplay.h @@ -1,7 +1,9 @@ /* - * © 2023, Neil McKechnie. All rights reserved. + * © 2024, Paul Antoine + * © 2023, Neil McKechnie + * All rights reserved. * - * This file is part of DCC++EX API + * This file is part of DCC-EX API * * This is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -112,13 +114,14 @@ protected: // Fill buffer with spaces memset(_buffer, ' ', _numCols*_numRows); - _displayDriver->clearNative(); - // Add device to list of HAL devices (not necessary but allows // status to be displayed using and device to be // reinitialised using ). IODevice::addDevice(this); + // Moved after addDevice() to ensure I2CManager.begin() has been called fisrt + _displayDriver->clearNative(); + // Also add this display to list of display handlers DisplayInterface::addDisplay(displayNo); diff --git a/version.h b/version.h index 3eaf199..e871738 100644 --- a/version.h +++ b/version.h @@ -3,7 +3,8 @@ #include "StringFormatter.h" -#define VERSION "5.2.47" +#define VERSION "5.2.48" +// 5.2.48 - Bugfix: HALDisplay was generating I2C traffic prior to I2C being initialised // 5.2.47 - EXRAIL additions: // STEALTH_GLOBAL // BLINK