mirror of
https://github.com/g4klx/MMDVMHost
synced 2025-12-24 01:25:41 +08:00
Add I2C device address in startup info
If using an LCD connected via I2C, display the configured I2C device address rather than the pins as the host starts up.
This commit is contained in:
@@ -875,7 +875,12 @@ void CMMDVMHost::createDisplay()
|
||||
if (pins.size() == 6U) {
|
||||
LogInfo(" Rows: %u", rows);
|
||||
LogInfo(" Columns: %u", columns);
|
||||
|
||||
#if defined(ADAFRUIT_DISPLAY) || defined(PCF8574_DISPLAY)
|
||||
LogInfo(" Device Address: %#x", i2cAddress);
|
||||
#else
|
||||
LogInfo(" Pins: %u,%u,%u,%u,%u,%u", pins.at(0U), pins.at(1U), pins.at(2U), pins.at(3U), pins.at(4U), pins.at(5U));
|
||||
#endif
|
||||
|
||||
LogInfo(" PWM Backlight: %s", pwm ? "yes" : "no");
|
||||
if (pwm) {
|
||||
@@ -891,6 +896,7 @@ void CMMDVMHost::createDisplay()
|
||||
m_display = new CHD44780(rows, columns, m_callsign, dmrid, pins, i2cAddress, pwm, pwmPin, pwmBright, pwmDim, displayClock, utc, m_duplex);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined(OLED)
|
||||
} else if (type == "OLED") {
|
||||
unsigned char displayType = m_conf.getOLEDType();
|
||||
|
||||
Reference in New Issue
Block a user