Renamed GDB & TargetConrollerConsole read & write register functions/classes to a more generic name.

This commit is contained in:
Nav
2021-08-07 17:07:04 +01:00
parent 3be850fbbf
commit fd719f1cda
11 changed files with 96 additions and 96 deletions

View File

@@ -0,0 +1,15 @@
#include "ReadRegisters.hpp"
#include "src/DebugServers/GdbRsp/GdbRspDebugServer.hpp"
using namespace Bloom::DebugServers::Gdb::CommandPackets;
void ReadRegisters::init() {
if (this->data.size() >= 2 && this->data.front() == 'p') {
// This command packet is requesting a specific register
this->registerNumber = static_cast<size_t>(std::stoi(std::string(this->data.begin() + 1, this->data.end())));
}
}
void ReadRegisters::dispatchToHandler(Gdb::GdbRspDebugServer& gdbRspDebugServer) {
gdbRspDebugServer.handleGdbPacket(*this);
}