/* Handle the "qSupported" command used by gdb to communicate state to debug monitor and vice versa. Reponse Format: qXfer:memory-map:read+;PacketSize==SSSSSSSS Where SSSSSSSS is the hexadecimal representation of the maximum packet size support by this stub. */ static uint32_t handleQuerySupportedCommand(void) { static const char querySupportResponse[] = "qXfer:memory-map:read+;qXfer:features:read+;PacketSize="; uint32_t PacketSize = Platform_GetPacketBufferSize(); Buffer* pBuffer = GetInitializedBuffer(); Buffer_WriteString(pBuffer, querySupportResponse); Buffer_WriteUIntegerAsHex(pBuffer, PacketSize); return 0; }
void InitBuffer(void) { Buffer_Init(&g_mri.buffer, Platform_GetPacketBuffer(), Platform_GetPacketBufferSize()); }