-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding telemetry and event automatic processing for GenericHub #2078
Conversation
|
||
} | ||
|
||
void GenericHubComponentImpl ::TlmRecv_handler(const NATIVE_INT_TYPE portNum, |
Check notice
Code scanning / CodeQL
Use of basic integral type
} | ||
} | ||
|
||
void GenericHubComponentImpl ::LogRecv_handler(const NATIVE_INT_TYPE portNum, |
Check notice
Code scanning / CodeQL
Use of basic integral type
@@ -62,8 +61,7 @@ | |||
bufferDeallocate_out(0, fwBuffer); | |||
} | |||
|
|||
void GenericHubComponentImpl ::dataIn_handler(const NATIVE_INT_TYPE portNum, | |||
Fw::Buffer& fwBuffer) { | |||
void GenericHubComponentImpl ::dataIn_handler(const NATIVE_INT_TYPE portNum, Fw::Buffer& fwBuffer) { |
Check notice
Code scanning / CodeQL
Use of basic integral type
} | ||
} | ||
|
||
void GenericHubComponentImpl ::LogRecv_handler(const NATIVE_INT_TYPE portNum, |
Check notice
Code scanning / CodeQL
Long function without assertion
|
||
} | ||
|
||
void GenericHubComponentImpl ::TlmRecv_handler(const NATIVE_INT_TYPE portNum, |
Check notice
Code scanning / CodeQL
Long function without assertion
@@ -62,8 +61,7 @@ | |||
bufferDeallocate_out(0, fwBuffer); | |||
} | |||
|
|||
void GenericHubComponentImpl ::dataIn_handler(const NATIVE_INT_TYPE portNum, | |||
Fw::Buffer& fwBuffer) { | |||
void GenericHubComponentImpl ::dataIn_handler(const NATIVE_INT_TYPE portNum, Fw::Buffer& fwBuffer) { |
Check notice
Code scanning / CodeQL
Long function without assertion
@@ -62,8 +61,7 @@ | |||
bufferDeallocate_out(0, fwBuffer); | |||
} | |||
|
|||
void GenericHubComponentImpl ::dataIn_handler(const NATIVE_INT_TYPE portNum, | |||
Fw::Buffer& fwBuffer) { | |||
void GenericHubComponentImpl ::dataIn_handler(const NATIVE_INT_TYPE portNum, Fw::Buffer& fwBuffer) { |
Check notice
Code scanning / CodeQL
Function too long
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CodeQL found more than 10 potential problems in the proposed changes. Check the Files changed tab for more details.
U8 buffer[sizeof(FwEventIdType) + Fw::Time::SERIALIZED_SIZE + Fw::LogSeverity::SERIALIZED_SIZE + FW_LOG_BUFFER_MAX_SIZE]; | ||
Fw::ExternalSerializeBuffer serializer(buffer, sizeof(buffer)); | ||
serializer.resetSer(); | ||
FW_ASSERT(serializer.serialize(id) == Fw::SerializeStatus::FW_SERIALIZE_OK);; |
Check notice
Code scanning / CodeQL
More than one statement per line
FW_ASSERT(serializer.serialize(timeTag) == Fw::SerializeStatus::FW_SERIALIZE_OK); | ||
FW_ASSERT(serializer.serialize(val) == Fw::SerializeStatus::FW_SERIALIZE_OK); | ||
U32 size = serializer.getBuffLength(); | ||
this->send_data(HubType::HUB_TYPE_CHANNEL, portNum, buffer, size); |
Check warning
Code scanning / CodeQL
Unchecked function argument
FW_ASSERT(serializer.serialize(severity) == Fw::SerializeStatus::FW_SERIALIZE_OK); | ||
FW_ASSERT(serializer.serialize(args) == Fw::SerializeStatus::FW_SERIALIZE_OK); | ||
U32 size = serializer.getBuffLength(); | ||
this->send_data(HubType::HUB_TYPE_EVENT, portNum, buffer, size); |
Check warning
Code scanning / CodeQL
Unchecked function argument
…2078) * Adding telemetry and event automatic processing for GenericHub * Fixes as suggested by review
* Adding telemetry and event automatic processing for GenericHub * Fixes as suggested by review
Change Description
GenericHub's difficult in deployment comes from primarily from the specific wrangling of standard types across the hub. This PR adds in dedicated telemetry and event processing such that the hub can be used with FPP pattern specifiers when connecting components to it.