From f0172b24c86838aef2bce61b2af8b8a18f538a2c Mon Sep 17 00:00:00 2001 From: Pascal <engelerp@phys.ethz.ch> Date: Tue, 13 Jun 2023 14:36:31 +0200 Subject: [PATCH] Added integral error reset setter --- firmware/drivers/communicator/communicator.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/firmware/drivers/communicator/communicator.cpp b/firmware/drivers/communicator/communicator.cpp index 7ff3c51..4241c31 100644 --- a/firmware/drivers/communicator/communicator.cpp +++ b/firmware/drivers/communicator/communicator.cpp @@ -127,7 +127,8 @@ bool Communicator::isSetCommand_(){ cmd_ == 'I' || cmd_ == 'D' || cmd_ == 'N' || - cmd_ == 'S'; + cmd_ == 'S' || + cmd_ == 'E'; } bool Communicator::isGetCommand_(){ @@ -203,6 +204,12 @@ void Communicator::handleSetCommand_(){ sendBuf_(); return; } + else if(cmd_ == 'E'){ + Pid_controller::set_I_reset_errsq(darg); + snprintf(outbuf_, 255, ";"); + sendBuf_(); + return; + } } void Communicator::handleNopCommand_(){ -- GitLab