DHB Reply Timeout #637

Merged
meierj merged 19 commits from meier/dhbReplyTimeout into development 2022-07-14 09:17:20 +02:00
Owner
  • for some devices it might be convenient to timeout replies by using the time instead of the number of polling cycles
  • this extension allows to link a reply to a Countdown object instead of specifying delay cycles
  • added unit test to verify the detection of missed replies both for periodic and action replies
  • adaption in helper script to optionally specify the cmake generator
  • adaptions required for unit tests in destructor of HealthHelper and FailureIsolationBase
  • HealthHelper:
    • remove object from health table when device handler is deleted which happens after each test case
  • FailureIsolationBase:
    • unsubscribe from event range when device handler is deleted
* for some devices it might be convenient to timeout replies by using the time instead of the number of polling cycles * this extension allows to link a reply to a Countdown object instead of specifying delay cycles * added unit test to verify the detection of missed replies both for periodic and action replies * adaption in helper script to optionally specify the cmake generator * adaptions required for unit tests in destructor of HealthHelper and FailureIsolationBase * HealthHelper: * remove object from health table when device handler is deleted which happens after each test case * FailureIsolationBase: * unsubscribe from event range when device handler is deleted
meierj added 8 commits 2022-06-06 11:16:19 +02:00
option to use Countdown object to time out replies
All checks were successful
fsfw/fsfw/pipeline/head This commit looks good
951c077abc
typo in readme
All checks were successful
fsfw/fsfw/pipeline/head This commit looks good
0aee86442e
device handler unittest wip
All checks were successful
fsfw/fsfw/pipeline/head This commit looks good
1611a4e1f0
fixed merge conflicts
All checks were successful
fsfw/fsfw/pipeline/head This commit looks good
161dbde0d7
unit test for detection of missed reply when commanded externally
Some checks failed
fsfw/fsfw/pipeline/head There was a failure building this commit
fsfw/fsfw/pipeline/pr-development There was a failure building this commit
4fba2704aa
meierj changed title from DHB Reply Timeout to WIP: DHB Reply Timeout 2022-06-06 11:17:13 +02:00
meierj added 1 commit 2022-06-06 11:59:49 +02:00
run auto-formatter
Some checks failed
fsfw/fsfw/pipeline/pr-development There was a failure building this commit
ae2f7219fd
meierj added 1 commit 2022-06-06 12:26:16 +02:00
deugging
All checks were successful
fsfw/fsfw/pipeline/pr-development This commit looks good
103661facc
meierj added 1 commit 2022-06-06 12:30:41 +02:00
missed reply check in simple command nominal test case
Some checks failed
fsfw/fsfw/pipeline/pr-development There was a failure building this commit
ade36e65c6
meierj added 1 commit 2022-06-06 12:35:14 +02:00
changed reply timeouts
Some checks failed
fsfw/fsfw/pipeline/pr-development There was a failure building this commit
21eb386f3c
meierj changed title from WIP: DHB Reply Timeout to DHB Reply Timeout 2022-06-06 12:37:12 +02:00
meierj requested review from gaisser 2022-06-06 12:37:20 +02:00
meierj requested review from mohr 2022-06-06 12:37:52 +02:00
mohr requested changes 2022-06-09 15:20:20 +02:00
@ -431,1 +447,4 @@
info.command = deviceCommandMap.end();
info.countdown = countdown;
if (info.periodic) {
info.active = true;
Owner

So far, convention is that periodic packets are disabled by default and need to be exlpicitely enabled. See info.delayCycles = 0; above.

So far, convention is that periodic packets are disabled by default and need to be exlpicitely enabled. See ` info.delayCycles = 0;` above.
mohr marked this conversation as resolved
@ -962,6 +1002,10 @@ ReturnValue_t DeviceHandlerBase::enableReplyInReplyMap(DeviceCommandMap::iterato
info->delayCycles = info->maxDelayCycles;
Owner

please add a comment, that both delay Cycles as well as the countdown are set if a countdown is preset, but the countdown will take precedence.

please add a comment, that both delay Cycles as well as the countdown are set if a countdown is preset, but the countdown will take precedence.
mohr marked this conversation as resolved
@ -448,6 +448,9 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* by the device repeatedly without request) or not. Default is aperiodic (0).
* Please note that periodic replies are disabled by default. You can enable them with
* #updatePeriodicReply
Owner

updatePeriodicReply needs to be adapted, too.

`updatePeriodicReply` needs to be adapted, too.
mohr marked this conversation as resolved
Owner

Also, dude, you wrote a DHB unit test (add exploding head emoji, it seems gitea can not handle unicode..)

Also, dude, you wrote a DHB unit test (add exploding head emoji, it seems gitea can not handle unicode..)
muellerr added this to the v5.0.0 milestone 2022-06-20 16:16:44 +02:00
muellerr added 1 commit 2022-06-21 10:49:09 +02:00
Merge branch 'development' into meier/dhbReplyTimeout
All checks were successful
fsfw/fsfw/pipeline/pr-development This commit looks good
3e9ae62b28
meierj added 1 commit 2022-06-23 11:55:15 +02:00
moved activation of periodic replies to updatePeriodicReply
All checks were successful
fsfw/fsfw/pipeline/pr-development This commit looks good
2d2f65bf89
meierj added 1 commit 2022-06-23 11:57:03 +02:00
run auto-formatter
All checks were successful
fsfw/fsfw/pipeline/pr-development This commit looks good
df97bbc691
mohr added 1 commit 2022-07-13 21:58:12 +02:00
some small fixes to dhb countdown addition
Some checks failed
fsfw/fsfw/pipeline/pr-development There was a failure building this commit
adbf375f38
Owner

As I think it is faster than writing about it, I took the liberty to add my remaining comments directly as code.

@meierj if you agree with my changes, feel free to add a positive review and merge this PR.

As I think it is faster than writing about it, I took the liberty to add my remaining comments directly as code. @meierj if you agree with my changes, feel free to add a positive review and merge this PR.
Owner

Also, I think we should remove the delay based solution completely some time in the future. The countdown based one is nicer and having both gives not exactly beautiful code.

Also, I think we should remove the delay based solution completely some time in the future. The countdown based one is nicer and having both gives not exactly beautiful code.
mohr removed review request for gaisser 2022-07-13 22:01:23 +02:00
meierj added 2 commits 2022-07-14 09:01:44 +02:00
meierj added 1 commit 2022-07-14 09:15:26 +02:00
better naming for functions which reset states of replies
All checks were successful
fsfw/fsfw/pipeline/pr-development This commit looks good
fsfw/fsfw/pipeline/head This commit looks good
ecac08814e
meierj merged commit 3686bbc486 into development 2022-07-14 09:17:20 +02:00
muellerr deleted branch meier/dhbReplyTimeout 2022-07-14 13:19:13 +02:00
Owner

I am working on refactoring the command/reply API anyway, it has become bloated up a bit.

I am working on refactoring the command/reply API anyway, it has become bloated up a bit.
Sign in to join this conversation.
No description provided.