diff options
author | David Crocker <dcrocker@eschertech.com> | 2019-09-18 20:38:12 +0300 |
---|---|---|
committer | David Crocker <dcrocker@eschertech.com> | 2019-09-18 20:38:12 +0300 |
commit | 5a3a7ba4c1e195c56b9a7930c0a2cfc2fb206781 (patch) | |
tree | b50cda19f4fc9ce2019c6950b8622d559b77ecda /src/Endstops/RemoteZProbe.cpp | |
parent | 0b77c939f61cbd63d48b04696445c3869b521da6 (diff) |
Bug fixes
Bug fix: M950 for heaters and fans didn't strip '-' or '_' from names
Added missing newline to some CAN-related error messages
Reduced the amount of information sent when configuring a remote Z probe
SoftTimer now uses a regular CallbackParameter
Diffstat (limited to 'src/Endstops/RemoteZProbe.cpp')
-rw-r--r-- | src/Endstops/RemoteZProbe.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/Endstops/RemoteZProbe.cpp b/src/Endstops/RemoteZProbe.cpp index 203a8cca..ae4ea36c 100644 --- a/src/Endstops/RemoteZProbe.cpp +++ b/src/Endstops/RemoteZProbe.cpp @@ -27,7 +27,8 @@ RemoteZProbe::~RemoteZProbe() String<StringLength50> reply; if (CanInterface::SendRequestAndGetStandardReply(buf, rid, reply.GetRef()) != GCodeResult::ok) { - reprap.GetPlatform().Message(ErrorMessage, reply.c_str()); + reply.cat('\n'); + reprap.GetPlatform().MessageF(ErrorMessage, reply.c_str()); } } } @@ -62,16 +63,18 @@ void RemoteZProbe::SetProbing(bool isProbing) const CanMessageBuffer * const buf = CanMessageBuffer::Allocate(); if (buf == nullptr) { - reprap.GetPlatform().Message(ErrorMessage, "No CAN buffer"); + reprap.GetPlatform().Message(ErrorMessage, "No CAN buffer\n"); } else { const CanRequestId rid = CanInterface::AllocateRequestId(boardAddress); auto msg = buf->SetupRequestMessage<CanMessageSetProbing>(rid, CanId::MasterAddress, boardAddress); msg->number = number; + msg->isProbing = (isProbing) ? 1 : 0; String<StringLength50> reply; if (CanInterface::SendRequestAndGetStandardReply(buf, rid, reply.GetRef()) != GCodeResult::ok) { + reply.cat('\n'); reprap.GetPlatform().Message(ErrorMessage, reply.c_str()); } } @@ -116,12 +119,8 @@ GCodeResult RemoteZProbe::Configure(GCodeBuffer& gb, const StringRef &reply, boo msg->number = number; msg->type = (uint8_t)type; - msg->triggerHeight = triggerHeight; - msg->calibTemperature = calibTemperature; - msg->temperatureCoefficient = temperatureCoefficient; msg->adcValue = adcValue; - msg->misc = misc.all; - msg->sensor = sensor; + msg->invertReading = misc.parts.invertReading; rslt = CanInterface::SendRequestAndGetStandardReply(buf, rid, reply); } |