Skip to content

Log Activity and Write Telemetry in Constructor #1412

Answered by SterlingPeet
MichaelStarks asked this question in Q&A
Discussion options

You must be logged in to vote

F Prime's logging and telemetry handling is not guaranteed to be initialized at the time of component construction. Because they are themselves components, this would be a race condition. For those mechanisms to work, the topology ports need to be connected; a process that starts after all of the component instances have been constructed and initialized. BTW; that also means you won't have access to spacecraft time via getTime() either.

So, if you want to log something during construction for debugging and testing purposes, you could go around the built-in tooling and just printf() that information. If you need that information to go through a flight or flight-like downlink to a GDS, you …

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by LeStarch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants