Updated with scheduler

This commit is contained in:
Martino Ferrari
2026-02-21 20:20:08 +01:00
parent 7cc4b81f05
commit 955eb02924
15 changed files with 664 additions and 102 deletions

View File

@@ -72,7 +72,7 @@ public:
StreamString signalName;
if (!dataSourceIn.GetSignalName(dsIdx, signalName)) signalName = "Unknown";
// 1. Register canonical DataSource name (Absolute)
// 1. Register canonical DataSource name (Absolute, No Root prefix)
StreamString dsFullName;
dsFullName.Printf("%s.%s", dsPath.Buffer(), signalName.Buffer());
service->RegisterSignal(addr, type, dsFullName.Buffer());
@@ -87,7 +87,7 @@ public:
DebugService::GetFullObjectName(*(gamRef.operator->()), absGamPath);
gamFullName.Printf("%s.%s.%s", absGamPath.Buffer(), dirStr, signalName.Buffer());
} else {
gamFullName.Printf("Root.%s.%s.%s", functionName, dirStr, signalName.Buffer());
gamFullName.Printf("%s.%s.%s", functionName, dirStr, signalName.Buffer());
}
signalInfoPointers[i] = service->RegisterSignal(addr, type, gamFullName.Buffer());
} else {

View File

@@ -0,0 +1,33 @@
#ifndef DEBUGFASTSCHEDULER_H
#define DEBUGFASTSCHEDULER_H
#include "FastScheduler.h"
#include "DebugService.h"
#include "ObjectRegistryDatabase.h"
namespace MARTe {
class DebugFastScheduler : public FastScheduler {
public:
CLASS_REGISTER_DECLARATION()
DebugFastScheduler();
virtual ~DebugFastScheduler();
virtual bool Initialise(StructuredDataI & data);
ErrorManagement::ErrorType Execute(ExecutionInfo &information);
protected:
virtual void CustomPrepareNextState();
private:
ErrorManagement::ErrorType DebugSetupThreadMap();
EmbeddedServiceMethodBinderT<DebugFastScheduler> debugBinder;
DebugService *debugService;
};
}
#endif

View File

@@ -55,14 +55,17 @@ public:
static bool GetFullObjectName(const Object &obj, StreamString &fullPath);
private:
void HandleCommand(StreamString cmd, BasicTCPSocket *client);
// Made public for integration tests and debug access
uint32 ForceSignal(const char8* name, const char8* valueStr);
uint32 UnforceSignal(const char8* name);
uint32 TraceSignal(const char8* name, bool enable, uint32 decimation = 1);
void Discover(BasicTCPSocket *client);
void ListNodes(const char8* path, BasicTCPSocket *client);
void InfoNode(const char8* path, BasicTCPSocket *client);
private:
void HandleCommand(StreamString cmd, BasicTCPSocket *client);
uint32 ExportTree(ReferenceContainer *container, StreamString &json);
void PatchRegistry();