Files
BloomPatched/src/DebugServer/Gdb/AvrGdb/CommandPackets/FlashWrite.hpp
Nav 6cdbfbe950 Massive refactor to accommodate RISC-V targets
- Refactored entire codebase (excluding the Insight component) to accommodate multiple target architectures (no longer specific to AVR)
- Deleted 'generate SVD' GDB monitor command - I will eventually move this functionality to the Bloom website
- Added unit size property to address spaces
- Many other changes which I couldn't be bothered to describe here
2024-07-23 21:14:22 +01:00

33 lines
1000 B
C++

#pragma once
#include <cstdint>
#include <optional>
#include "src/DebugServer/Gdb/CommandPackets/CommandPacket.hpp"
#include "src/DebugServer/Gdb/TargetDescriptor.hpp"
#include "src/Targets/TargetMemory.hpp"
namespace DebugServer::Gdb::AvrGdb::CommandPackets
{
/**
* The FlashWrite class implements the structure for the "vFlashWrite" packet. Upon receiving this packet, the
* server is expected to write to a particular region of the target's flash memory.
*/
class FlashWrite: public Gdb::CommandPackets::CommandPacket
{
public:
std::uint32_t startAddress = 0;
Targets::TargetMemoryBuffer buffer;
explicit FlashWrite(const RawPacket& rawPacket);
void handle(
Gdb::DebugSession& debugSession,
const Gdb::TargetDescriptor& gdbTargetDescriptor,
const Targets::TargetDescriptor& targetDescriptor,
Services::TargetControllerService& targetControllerService
) override;
};
}