Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Duet3D/RepRapFirmware.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Crocker <dcrocker@eschertech.com>2021-10-18 22:59:48 +0300
committerDavid Crocker <dcrocker@eschertech.com>2021-10-18 22:59:48 +0300
commit329865b3b09495a95255ab108d7cdc14c2348c37 (patch)
treec6db73d9d129be009ce39b6898cc65186e605252 /src/Platform
parentc0f47d671496f5ada26fc3094441ec2ff80a48ae (diff)
Refactored AppendDriverStatus and its calling code
Diffstat (limited to 'src/Platform')
-rw-r--r--src/Platform/Platform.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/Platform/Platform.cpp b/src/Platform/Platform.cpp
index e7bf7910..5c378df2 100644
--- a/src/Platform/Platform.cpp
+++ b/src/Platform/Platform.cpp
@@ -1814,8 +1814,13 @@ void Platform::Diagnostics(MessageType mtype) noexcept
#if HAS_SMART_DRIVERS
if (drive < numSmartDrivers)
{
- driverStatus.cat(',');
- SmartDrivers::AppendDriverStatus(drive, driverStatus.GetRef());
+ driverStatus.cat(", ");
+ const StandardDriverStatus status = SmartDrivers::GetStandardDriverStatus(drive);
+ status.AppendText(driverStatus.GetRef(), 0);
+ if (!status.notPresent)
+ {
+ SmartDrivers::AppendDriverStatus(drive, driverStatus.GetRef());
+ }
}
#endif
driverStatus.cat('\n');