2023-05-21 21:08:25 +01:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include <optional>
|
|
|
|
|
|
2024-10-25 22:22:25 +01:00
|
|
|
#include "CommandPacket.hpp"
|
2023-05-21 21:08:25 +01:00
|
|
|
|
|
|
|
|
#include "src/DebugServer/Gdb/RegisterDescriptor.hpp"
|
|
|
|
|
|
2023-08-13 15:47:51 +01:00
|
|
|
namespace DebugServer::Gdb::AvrGdb::CommandPackets
|
2023-05-21 21:08:25 +01:00
|
|
|
{
|
|
|
|
|
/**
|
|
|
|
|
* The ReadRegisters class implements a structure for the "g" command packet. In response to this packet, the
|
|
|
|
|
* server is expected to send register values for all registers.
|
|
|
|
|
*/
|
2024-10-25 22:22:25 +01:00
|
|
|
class ReadRegisters: public CommandPackets::CommandPacket
|
2023-05-21 21:08:25 +01:00
|
|
|
{
|
|
|
|
|
public:
|
2024-10-25 22:22:25 +01:00
|
|
|
explicit ReadRegisters(const RawPacket& rawPacket);
|
2023-05-21 21:08:25 +01:00
|
|
|
|
|
|
|
|
void handle(
|
2024-10-25 22:22:25 +01:00
|
|
|
DebugSession& debugSession,
|
|
|
|
|
const AvrGdbTargetDescriptor& gdbTargetDescriptor,
|
2024-07-23 21:14:22 +01:00
|
|
|
const Targets::TargetDescriptor& targetDescriptor,
|
2023-05-21 21:08:25 +01:00
|
|
|
Services::TargetControllerService& targetControllerService
|
|
|
|
|
) override;
|
|
|
|
|
};
|
|
|
|
|
}
|