Compare commits
1394 Commits
Author | SHA1 | Date | |
---|---|---|---|
b6e08f369a | |||
9b088a22b4 | |||
cf2fb54cc1 | |||
f749866818 | |||
7e675ba35d | |||
16441678c9 | |||
f271da3b04 | |||
6f7cde69e5 | |||
b8a58edf5a | |||
c611bc824b | |||
481b0361f9 | |||
60cb56769d | |||
140fd9f4f5 | |||
7b3265ea91 | |||
a94e7ed17c | |||
e5f06fe19f | |||
ddad5e30a4 | |||
7d29da1263 | |||
dec13c7d13 | |||
577e45fec3 | |||
8611144a70 | |||
25de385766 | |||
b9cf144c1f | |||
bb0c4ac03e | |||
ce04532759 | |||
4277a98c16 | |||
34cd92840f | |||
3f94bf7855 | |||
1b05f45e24 | |||
be4a6b2434 | |||
f68f4066be | |||
3f1f3fa916 | |||
379c868abb | |||
c9ec0f67bd | |||
eee829919b | |||
3150261e3e | |||
fe01d3d4b5 | |||
bc6b492976 | |||
11ccd1f535 | |||
b891198bee | |||
da831ff789 | |||
078299a07c | |||
2f5ec84237 | |||
2694f0cbc8 | |||
6e4d27a454 | |||
ab74382c12 | |||
2be5cdabb0 | |||
11e1222a7c | |||
573ff334b8 | |||
19dd7a0964 | |||
a92f664770 | |||
bb27700cc2 | |||
3e3355a926 | |||
55d32a2bb0 | |||
2f990d8bbc | |||
8482d56fd0 | |||
e349504b41 | |||
0bb5f08d23 | |||
0dbe6b9854 | |||
043a458f42 | |||
c682d75aff | |||
aea4313b7d | |||
11c54e270f | |||
881a03fbed | |||
f9e04ed9a2 | |||
d8f84ed00d | |||
b516f12a61 | |||
de4bf6dd55 | |||
22f8d256dd | |||
7cf3247cbd | |||
8843a0d8c5 | |||
ec18cb7007 | |||
74bb27e61f | |||
5890e639fe | |||
7c2755db26 | |||
0b81a92941 | |||
f39d03afc2 | |||
b54ced65f6 | |||
ff8ebfe67a | |||
99e6ea6000 | |||
a196ab136e | |||
ba1cc420c4 | |||
1dfbb9474c | |||
0e8859c278 | |||
a8af3a8447 | |||
97a947f5aa | |||
5d63160c57 | |||
a4ba52e76d | |||
a5318b430b | |||
9cec20a550 | |||
024da6ceef | |||
d544792e29 | |||
9a5901235c | |||
e16ee5d6a5 | |||
596b6eb46d | |||
5b84808d7c | |||
ce59e66c05 | |||
af85c883fa | |||
1fd5d065b6 | |||
509d144117 | |||
6da3d6f06a | |||
2f0aed97dc | |||
52ab77eded | |||
4ff1548cf2 | |||
f6d1a41cb9 | |||
1623dd1c80 | |||
94ae33a554 | |||
e3c41dd807 | |||
2f263c6aa6 | |||
8c83ec78fd | |||
f229ebb141 | |||
a2f2e1b84e | |||
19753c43f1 | |||
7ab01687ce | |||
22076ea25e | |||
7c54e920ef | |||
be848ea5e4 | |||
8dd22b6ea0 | |||
53c38d9c05 | |||
d894479f75 | |||
37e128041f | |||
bab0bbf82d | |||
7d9be35cb4 | |||
95a4d88ed4 | |||
102228100e | |||
c4fe772fe7 | |||
ccf1fcaa79 | |||
4fdb2de510 | |||
5e2f7fa3ed | |||
7ddfdc0978 | |||
bb895c9e12 | |||
3eb5fc7f47 | |||
533aaa207c | |||
005d5a5223 | |||
2b12cc4fa2 | |||
ec2db69236 | |||
263f4eb25f | |||
13c7ef373d | |||
adcc68e0fa | |||
11106cf755 | |||
f966b517a4 | |||
3e5937db67 | |||
d322096573 | |||
a392e31f99 | |||
719ffcad2b | |||
59ee375fc1 | |||
bbb8dd7a8a | |||
8fa2d0be0b | |||
af1d03f53f | |||
8a6d292a48 | |||
017171f221 | |||
f2210010de | |||
52ec5093bc | |||
77e39f3a92 | |||
af59a4e5d5 | |||
dc1047b7f9 | |||
e27b0875e0 | |||
0d46349caa | |||
1d935d46e7 | |||
8dd350e8dd | |||
07394ddfc9 | |||
551a4fe00f | |||
306fe7a2d9 | |||
9c300298b7 | |||
dcbf1502a2 | |||
f8c9ddbc3c | |||
74fa81d8f6 | |||
4429dd1be9 | |||
d15db7668d | |||
66b38fa294 | |||
7ce881debc | |||
90d00b44ee | |||
7d6c6f03ef | |||
b7abab1114 | |||
fe9c8c50f2 | |||
9af43cb93b | |||
6e049f3ee1 | |||
157e7d2b4d | |||
882fb02600 | |||
6688499128 | |||
038a529b06 | |||
70806cffff | |||
e03e35ab77 | |||
ee08adb525 | |||
c9e16642c5 | |||
143d787f60 | |||
4664a9f4e7 | |||
3a56297a83 | |||
1f9935cf22 | |||
b43e1ef4e9 | |||
a83adb148e | |||
4a386ae641 | |||
b59a84b3d5 | |||
a0fda428bf | |||
870cc1da10 | |||
cd5061fe0f | |||
1981c4f70a | |||
192c7c6f31 | |||
a1f6143b92 | |||
ee3926fe2a | |||
853215e0dd | |||
e7811ebd0c | |||
b4b6363337 | |||
090ef88030 | |||
f358719778 | |||
4d74c8ec43 | |||
e77766ae59 | |||
79bd349ac7 | |||
63f45ec27e | |||
9cdc932ad8 | |||
977235df87 | |||
84adbeda38 | |||
f5b5fcd7ff | |||
ace01e2742 | |||
b14038e29c | |||
f115e6ca33 | |||
bfd2ed5b6e | |||
fde644cdbf | |||
f71fe274f4 | |||
b1fa3fd016 | |||
eb66d7585c | |||
f62b312d3c | |||
a83136515c | |||
569fdfef6e | |||
eb861c9f01 | |||
7fd2fbc481 | |||
58a5ede270 | |||
08ca196c74 | |||
16ea033fd2 | |||
a4e6d877ff | |||
baf69fac44 | |||
0f7fd39d72 | |||
9892938601 | |||
97698a08d5 | |||
b603554a80 | |||
bbd27eca76 | |||
f9c03af538 | |||
68ed3fa232 | |||
8c450596f6 | |||
5ea2767662 | |||
b4129950cf | |||
939d7fd98e | |||
c47a7338db | |||
1048456a5b | |||
2a84ebba57 | |||
9413f723cf | |||
4257e1d918 | |||
127a8e6124 | |||
5f9e0bf80a | |||
976235a79f | |||
b6d18ef4d2 | |||
7b3393c5b2 | |||
3c0b8f9e8b | |||
4e8e85f450 | |||
342ff62837 | |||
bce8df376a | |||
97b4db10bf | |||
e0024e738e | |||
879bce4f76 | |||
49d060d20e | |||
2e6962c29c | |||
afd704650f | |||
bc0f1cad7b | |||
04541b4a19 | |||
4a386ad3d1 | |||
6452242f2f | |||
79abd05820 | |||
793d6feaaa | |||
8b6a03a3ab | |||
b6fc9d65b7 | |||
2e431668dd | |||
37a32bb6e9 | |||
2f4f7f088e | |||
0b09816b4a | |||
c85c2cf4b6 | |||
c80426309d | |||
ba0bc1b98b | |||
170976566b | |||
b1c4241b03 | |||
555e0ce49d | |||
cb8a49775d | |||
ac6031364e | |||
98ba4a0449 | |||
68c728cbdb | |||
340b600599 | |||
3caa9dea75 | |||
86e48eea6d | |||
cca8734908 | |||
a9b514ddc8 | |||
9a30ae5175 | |||
75a80b55ec | |||
e4efd42234 | |||
0dbd6b703d | |||
b6477e099d | |||
f3c3e8a443 | |||
357c01343c | |||
677a3f95bd | |||
64fd7fb37d | |||
fae83a0fca | |||
8b26d13070 | |||
55bd87abb6 | |||
c8fe1b1359 | |||
38907fc0f5 | |||
f8d432f6eb | |||
dd8b6ced8f | |||
9cb7cefb85 | |||
2374dea493 | |||
00e04e8b77 | |||
df3fa17017 | |||
cb71b8cfb2 | |||
fd943a99b6 | |||
d50cbe9e5b | |||
e6aa582fcb | |||
245116403a | |||
3ebcbaa44f | |||
1dee29aabd | |||
9d5f846658 | |||
b2fd2f5d83 | |||
96865c1dd2 | |||
42779e6ace | |||
9f9b1e440a | |||
ac2c4c7abc | |||
eb61996f91 | |||
49e3002abc | |||
e5636f0b6c | |||
21899d663e | |||
c1b43bb504 | |||
087db386d7 | |||
2f5f47a02c | |||
8821cc1079 | |||
14cea6369a | |||
0a37db617b | |||
101117cebe | |||
4863dad1cd | |||
1154c0e887 | |||
c6289e27ae | |||
6538005a30 | |||
fa5883bdf3 | |||
b261a4ecfa | |||
a6dfe02128 | |||
bcd31c9248 | |||
bf73f2ff04 | |||
b2a8c5d7ec | |||
2dd97a55f8 | |||
ccf03b131b | |||
c48268ffa9 | |||
97a78fc4c9 | |||
0bdc6d3d7c | |||
66583e8009 | |||
c0f01a75e4 | |||
6a15aa14a2 | |||
11e9d71775 | |||
d30bab7bc0 | |||
a366ef0960 | |||
930f7a5233 | |||
68f4323d14 | |||
01e97c8381 | |||
1b73e7de7d | |||
8759f86889 | |||
a2d5138c71 | |||
f5c4e2b788 | |||
af1c18e8cf | |||
c562c4a240 | |||
45e1e7250b | |||
70e2a3f5f8 | |||
e6a5847e9c | |||
72ae6aee94 | |||
25e5f8d2a4 | |||
0f25f95307 | |||
af5d4e12c5 | |||
fd62efcae2 | |||
1b00029202 | |||
72174c76cd | |||
7476f33905 | |||
e48d080673 | |||
888ade0bfb | |||
a2fd590280 | |||
23c9e8eed7 | |||
1f8f62457d | |||
cb43688f38 | |||
f84e7e42d6 | |||
51317782c3 | |||
97bb255d53 | |||
97888953ec | |||
112cfa3ee7 | |||
5de7653600 | |||
bf7e4b4b8c | |||
5b0db43e0f | |||
72ab4b1a24 | |||
1cc39bb6d7 | |||
e3389c32a7 | |||
fd405e61a4 | |||
903c0c8258 | |||
82966eed31 | |||
fd436dbe8b | |||
d8a07312f2 | |||
58db0d7184 | |||
5218202824 | |||
bd295d5b52 | |||
faf4937e76 | |||
ba0e07b5c6 | |||
37673a2782 | |||
c169229107 | |||
d2daa89d89 | |||
ca7fbcf6a9 | |||
db2905c834 | |||
2ccd2a832c | |||
892d2f5939 | |||
cee56f6d02 | |||
3016683db3 | |||
f66777a23c | |||
e38b39b3b2 | |||
4e9646fe10 | |||
ca6556c000 | |||
6aae94823e | |||
0dc26ec8b2 | |||
3b5ecb43cc | |||
e7a1c9f402 | |||
ff9a5fc1bf | |||
2fcba4028c | |||
85d0ac92da | |||
b3a14e9a9b | |||
bf61724374 | |||
8c9424f02b | |||
350b892bb7 | |||
586f04e488 | |||
1f7ab7c2ce | |||
9d8991491a | |||
b64cc8f404 | |||
acae88c67c | |||
4fa5aa6b84 | |||
b48a6e2318 | |||
193ed01bce | |||
d18a0e98a5 | |||
6e10ccd2d6 | |||
3b61697615 | |||
f82cc2aeda | |||
0b2aff56e5 | |||
7f141aa1e8 | |||
c8d09debf7 | |||
1938addaa8 | |||
e6b5ee65f3 | |||
4d6ccaeb4b | |||
3003a4c4d1 | |||
f96fbf707d | |||
80115640ba | |||
4c1b79fd66 | |||
c8a2395d61 | |||
f6f3f17505 | |||
300f3230d1 | |||
c71a1a29f3 | |||
cfbc53792d | |||
5b5489c8da | |||
773e1c9ecc | |||
f041655378 | |||
206c29bb25 | |||
e8da0885eb | |||
f209ac6b2d | |||
b20266f153 | |||
e6b0b4048c | |||
982db82ddb | |||
0d175951ec | |||
3b383b98df | |||
41f1eaec44 | |||
05be170890 | |||
1e4766ddfc | |||
8720dacb7f | |||
39bf9f9b5b | |||
2165f34a28 | |||
70e1d41a08 | |||
3b0490835c | |||
6c7d1e674c | |||
cc3bcdfaeb | |||
26f9c499d8 | |||
59e165be4f | |||
53133573e1 | |||
7a7f25a638 | |||
ec2ec32af4 | |||
fcba76b7f1 | |||
60afb573a0 | |||
ff50203fbb | |||
da72b3a96a | |||
1cf3fbaabe | |||
245b5dfcc6 | |||
04e3d2486d | |||
c4ef164f41 | |||
39bb90eb61 | |||
7a4a42c692 | |||
21ed43614e | |||
7288a5edbd | |||
d55daebabf | |||
ca22904d32 | |||
4ec362d849 | |||
00834de1b7 | |||
3ade660132 | |||
3e2338f3a4 | |||
79d27ff9e3 | |||
d13e593f89 | |||
35caddbfc4 | |||
196aca241e | |||
6530ad8f1a | |||
34807c94ba | |||
0919acf2d5 | |||
69ea16c36d | |||
e2cb88da0e | |||
f2ffb12219 | |||
25dfb54be0 | |||
f43a93842e | |||
ad4ab98356 | |||
7b571bc007 | |||
dfb1e88f55 | |||
7b539e2fa5 | |||
4b37a19644 | |||
718a440442 | |||
7e33ec16e4 | |||
26d8e852dc | |||
0fc17624f3 | |||
74ffbf1dcd | |||
b5049fa8d0 | |||
652326443b | |||
d4b7c6493a | |||
4aa6ed4de4 | |||
9067c4180e | |||
0056ebcb62 | |||
a2485a2195 | |||
eaa0fc6cbe | |||
14188a4f3b | |||
eee92baa6e | |||
6104bf7adb | |||
e52c909580 | |||
5f17b1f6e8 | |||
90175e5c9d | |||
7a8816e49a | |||
c4cd6332f8 | |||
8ff70462cb | |||
2e9de68e17 | |||
8ad1daa11f | |||
4a820fba55 | |||
d045498761 | |||
0a7eb6f6bc | |||
3784cf688f | |||
f646566228 | |||
58527dacf6 | |||
03cf5891b0 | |||
1b79bfc02a | |||
3c6c990b8f | |||
1252897a1c | |||
22b2f137b4 | |||
c347b6d1d4 | |||
24b939c50b | |||
ef5bc9731d | |||
67128b398c | |||
c251d93305 | |||
26aeb88d84 | |||
6004233c67 | |||
11f476878d | |||
809626b6e3 | |||
db90c59557 | |||
2c6ea8dc9f | |||
543568be39 | |||
a8e886200f | |||
0fabe3adb6 | |||
f2598b5c4c | |||
f7573b4902 | |||
7b0657bb55 | |||
d59daa2485 | |||
9556ce6d9f | |||
6f1a2952d5 | |||
c09d94f003 | |||
10807d577f | |||
6e6dff56f2 | |||
959adcafb1 | |||
737d5ecb53 | |||
84643020da | |||
04a561b9a0 | |||
d86b9d55da | |||
90b4b7c0f4 | |||
48d9a65f09 | |||
251dddc42d | |||
1129836112 | |||
d4923ac3e8 | |||
8e5adae8ef | |||
26369039da | |||
5c30adb9bb | |||
309358f447 | |||
7bf72e3c18 | |||
12ac8f7c70 | |||
92f5a8bf89 | |||
fd4be08796 | |||
afb9303dcb | |||
17a1a5a655 | |||
22558a2f39 | |||
e9514b1c97 | |||
c06dd15303 | |||
89ba9f7009 | |||
0df5070fa6 | |||
20edbf6213 | |||
d7ebc4dbe2 | |||
316971c6bc | |||
c7bed10bdf | |||
cc4c3182a0 | |||
71a2ecc2ea | |||
2f9cdefc96 | |||
ea993ad2e9 | |||
972012e549 | |||
a6af6174f4 | |||
9ae43d83f9 | |||
828b6adf77 | |||
9b4026a1c9 | |||
72753aa43a | |||
cf42ca7835 | |||
e41f8901c5 | |||
c99b9f5afa | |||
a245966793 | |||
746f288f1e | |||
9501d0802f | |||
be3c778fee | |||
13f2f39325 | |||
66b4fc6294 | |||
aae4d019e7 | |||
cbb6a45407 | |||
95ce2c79b9 | |||
8810ad3d60 | |||
66a1e690e0 | |||
1744f1aff0 | |||
0206115abb | |||
6e8fc83aed | |||
f02bc6b345 | |||
d662cdba34 | |||
dd5373a728 | |||
d2e3f14b72 | |||
6d148307ae | |||
d671de7efb | |||
862f8b3da3 | |||
e349bb8a7f | |||
cb1a98ccff | |||
95e20e70ff | |||
f765707886 | |||
fd6be806ed | |||
22bac9e7c0 | |||
36fe0921de | |||
acd4c5da6d | |||
cb869fef0c | |||
d3fc9a4491 | |||
7af7eff316 | |||
7392012a00 | |||
89518a035a | |||
89230b60d7 | |||
104d9647fe | |||
eb2a0604e9 | |||
0cb7446297 | |||
f789380343 | |||
e33a0fd60b | |||
b4ce9d2a22 | |||
5984bb52f2 | |||
9b6c3964c6 | |||
089d04646a | |||
ed992e495b | |||
8da373542e | |||
ee974d0e2d | |||
0907e8f5e5 | |||
59b80807ba | |||
80e12fb194 | |||
7c3031de78 | |||
f160dfa56d | |||
bf16d6d86a | |||
43a2993f4d | |||
e19c03f0d7 | |||
33d552693f | |||
152a9b2dce | |||
91af3ac497 | |||
ee4db78a95 | |||
89f6314a18 | |||
5db1f71854 | |||
0ee7bdad0a | |||
481e546e6d | |||
1e45bff0cc | |||
419864e5da | |||
cd88e8948d | |||
ca743ccd6c | |||
9fc6386ac5 | |||
513dcf9be1 | |||
b60891ddd1 | |||
cd988753ae | |||
d37770422b | |||
12539ba415 | |||
0726b9d730 | |||
66d3b06f9e | |||
bd60255220 | |||
ba9268aae6 | |||
9f83a49690 | |||
5d9ed222f5 | |||
5205c5b78a | |||
3b17af9d07 | |||
205bd4648e | |||
29f1dd0f8e | |||
0254fb9fd2 | |||
eee3da50f2 | |||
d32ce3c563 | |||
a190d99f6d | |||
5357de8da8 | |||
9614a76acf | |||
0466622a16 | |||
90c1d45f20 | |||
8873ecae48 | |||
5ad2fa5e93 | |||
2c4a47f302 | |||
0d8cb295d9 | |||
2a91105124 | |||
eaceb32359 | |||
01d8eccdd2 | |||
28f3b07c5c | |||
9633359db3 | |||
ee811371c5 | |||
5f6f806b88 | |||
721d38f758 | |||
19d04c0023 | |||
67a14ca6f6 | |||
83b81e1ba8 | |||
5f275778de | |||
ce72e4308e | |||
8b45786e5d | |||
e915f6cc90 | |||
c9f16b223a | |||
2ee70d53d9 | |||
6c16238cc7 | |||
1803b2c650 | |||
3137ebb86e | |||
fd1c090141 | |||
82d428440b | |||
018f93cfbe | |||
c64a490324 | |||
62cadd16ab | |||
a1cb4fb549 | |||
e416d94224 | |||
411b2595fa | |||
2c3a7791e1 | |||
f19729e11d | |||
019cc29c24 | |||
d1402587dc | |||
793e6f4119 | |||
0ec0d551a3 | |||
2a9c1aab7f | |||
41adaf36bf | |||
7dae81c122 | |||
243088252c | |||
9be00603f4 | |||
f3fe65080b | |||
d9ef0f9a9d | |||
7aa977efdf | |||
adda32854d | |||
01ac2f4aff | |||
b01b9d3b99 | |||
a2a822c118 | |||
1bdfd5f8ea | |||
0f5e65e5ce | |||
62e7e23512 | |||
b6558acdbc | |||
257efd4974 | |||
6ca210ac31 | |||
b3b736a7bd | |||
b3dd2ec57a | |||
262e6d0b39 | |||
7bda0dfb97 | |||
eefdc8ff5b | |||
1a8f9ab4a2 | |||
0d7b77e5d1 | |||
6ea22b63df | |||
a91e6b7dfe | |||
1d5856b4d4 | |||
35ad0a40d3 | |||
5349fb45e3 | |||
b5b80cef97 | |||
582c8e8eff | |||
3ffdcf3885 | |||
80f8df3ee4 | |||
ef24aba750 | |||
586966bebe | |||
a864d51ddf | |||
6104b94268 | |||
682b528004 | |||
124e08e80b | |||
030d3272d3 | |||
03fbc6b23d | |||
c149f3871a | |||
328fd149e5 | |||
d0613727ba | |||
7af4a777ae | |||
c98b3f6aa4 | |||
532add94d0 | |||
e3d9614fae | |||
9ce065adb2 | |||
d38b5346a2 | |||
fb0ff922a8 | |||
cac634503d | |||
56cdd1173e | |||
ea6b13d189 | |||
60b07035b1 | |||
94262a9d04 | |||
bcce945cce | |||
803c0b1a3e | |||
9285e13ce5 | |||
6b80daab0a | |||
82c97656f1 | |||
3ad6c8a56c | |||
7275454f8a | |||
57054c46ab | |||
40446b1fea | |||
1eb26240b1 | |||
81a4112c45 | |||
48b0ee8662 | |||
67e9dc9090 | |||
a7d3f2c3f8 | |||
2c8cfa3874 | |||
6016063add | |||
04e1cb52ac | |||
a3f2219f9b | |||
fd0da7379a | |||
4c079b7d33 | |||
7d8cf0cbfe | |||
6b931dce7f | |||
6074e9246e | |||
a918d61f2b | |||
4fe14b464a | |||
03470284a4 | |||
700d7ced64 | |||
2b38fe19af | |||
2bacf1efa0 | |||
641c069664 | |||
9a9574369a | |||
4b6e0addf1 | |||
01fbb2d9fd | |||
f945252d3c | |||
ffebe00f93 | |||
6523634b2a | |||
8f3ea62632 | |||
612c9967b4 | |||
cd9b0cb4f4 | |||
98bf2d592c | |||
7cbc3fe06c | |||
8d68d80eb2 | |||
27420b0c4e | |||
4de18cbaa4 | |||
f36c2e9587 | |||
b1d56eb299 | |||
a2cb348ee3 | |||
953d7f1db4 | |||
263b62e6d0 | |||
a0f4b031be | |||
cab2d00530 | |||
8f5a454771 | |||
bf65d13849 | |||
de4e28fcec | |||
0c78037fb8 | |||
10a18ba6af | |||
5abecd065c | |||
6f4c81117b | |||
da898a3f16 | |||
ec8c5b7a5c | |||
b3cdb05214 | |||
e9104b7479 | |||
0dae3b04be | |||
0d32bc0c0a | |||
6352b65f46 | |||
f12fa77644 | |||
f0d77125e1 | |||
d9708c6175 | |||
d709e190e2 | |||
eb6a0c410f | |||
da78f00f82 | |||
2f07f2b75e | |||
1d541dcca5 | |||
c1598f8808 | |||
378120416a | |||
fdc37ad381 | |||
8e7c4b5da2 | |||
7fa8a497f2 | |||
8fbb058322 | |||
54d48feb2d | |||
2bfc9bc565 | |||
706e3c8882 | |||
fdebddb965 | |||
cb6a98b0d2 | |||
47e97ff1be | |||
7f74cca11f | |||
2f7abb2da8 | |||
1e0c94246d | |||
12c5a10662 | |||
d233dc9f82 | |||
e1703be49b | |||
1518fba6bd | |||
537b8282c3 | |||
03941472a8 | |||
f41cf14df5 | |||
e99819449a | |||
123db49c78 | |||
f54945de12 | |||
7ee9bf6edf | |||
75ade4d8f8 | |||
08f36954ad | |||
29e031f0df | |||
7ff63930d4 | |||
0968d91fb5 | |||
c6c92e1140 | |||
9d59f960a4 | |||
fb3359b44f | |||
cfad85c6c5 | |||
c29d7e6f3e | |||
8b1d6cf07d | |||
feb59d321c | |||
6be54a9485 | |||
97f7f7c973 | |||
a026f5e2d0 | |||
bc2a0d875f | |||
39f83937c5 | |||
d831110127 | |||
e5271a9ca5 | |||
4b8f5992b5 | |||
efe63b394c | |||
9fdb41506b | |||
655e01c2d1 | |||
8c001b6443 | |||
8b0eceb072 | |||
f784d4f248 | |||
7c68de26d2 | |||
e7123a4bb1 | |||
a13ae7abcc | |||
9ddcc8dc14 | |||
177b573cd4 | |||
1553900145 | |||
166fd77f7b | |||
075bba242b | |||
29e78a7ae3 | |||
11e06f6b21 | |||
a893618f60 | |||
918cd7b237 | |||
d506b515fc | |||
a26924fa04 | |||
6f84099c5e | |||
024e06a3d3 | |||
35b9c7a4df | |||
fd9503ed3b | |||
0bf1df81cd | |||
0654001945 | |||
a0d09e7f23 | |||
14d70950f8 | |||
bf70e8ece4 | |||
e07492c855 | |||
92b3f740d5 | |||
16eab6b266 | |||
58f29e16c5 | |||
6d428859f2 | |||
650f24d0ff | |||
1de832509a | |||
ef09cdabc2 | |||
3da5f1d6cc | |||
e0c33b21e9 | |||
2d4c881d3a | |||
56840deb9b | |||
ecb22bdd85 | |||
9b2398888d | |||
a57384f6c4 | |||
2aac3c67ee | |||
66d20dc118 | |||
a75e035cc5 | |||
3c5a2568ef | |||
131fff6847 | |||
d9acbe3207 | |||
4ba0d36800 | |||
6a1d4bd52f | |||
4cccafbe01 | |||
f5092b27ba | |||
17fa9a6e82 | |||
2813d229bb | |||
6c0234149e | |||
99913594fd | |||
f864d73253 | |||
af8caca3f6 | |||
e2f8ca752f | |||
efbb5d69c7 | |||
ebc32d1cc2 | |||
b4d9ea6c19 | |||
323140c846 | |||
cec9ef6c5d | |||
97a001a1da | |||
0bc7ddf38e | |||
59a0a74032 | |||
60c99fdbfb | |||
068b31a3d6 | |||
1d20c3b472 | |||
14c43c49dc | |||
53f31ca5a4 | |||
b5e096abcb | |||
f4f6d1ed81 | |||
ac22a00e09 | |||
4958fa73d1 | |||
c90d6f1f55 | |||
227b371329 | |||
577915db13 | |||
2c0efdee5a | |||
7e3de3ca95 | |||
f81984235b | |||
3759b5d34a | |||
c5a4fcd674 | |||
1d40e40691 | |||
4b36313fea | |||
2f2d164526 | |||
6521e419eb | |||
e94af34ef0 | |||
f5b5ef66b7 | |||
767618f61f | |||
84a4d093bc | |||
b0c84f9284 | |||
6b919c727d | |||
62eb39923f | |||
b3202623f4 | |||
bd455b750c | |||
1cad316575 | |||
37b786898e | |||
35172185f9 | |||
fc5196f8da | |||
285bd7116b | |||
08df102f36 | |||
33684f2ef7 | |||
bc4c6c3a54 | |||
109560feb2 | |||
ea32d87c25 | |||
01d6060111 | |||
c2079dcbba | |||
9041a3376c | |||
9dfd8491d2 | |||
d73946e005 | |||
c5e856aaa6 | |||
22fdb6994a | |||
57aab39b8b | |||
bcec465f9a | |||
99e5d3bb03 | |||
ea7b43234e | |||
51629da4a0 | |||
4bb802362b | |||
a3eaace4a5 | |||
29eda50e35 | |||
d01308f0ba | |||
5a5d00e4e5 | |||
ee51b5428d | |||
c34d32e65e | |||
417969fcec | |||
15f8b9d0fb | |||
59689f2af6 | |||
8a88695409 | |||
9ded406f49 | |||
f8b9373627 | |||
1cda86ee94 | |||
e527695a33 | |||
c496271a0e | |||
3159574cfa | |||
5542507024 | |||
fa62f07dce | |||
c61e8f6dd7 | |||
8d69996d4c | |||
c843e34464 | |||
7eab7169f7 | |||
9d14788ef3 | |||
7ec8ca3356 | |||
fc61066848 | |||
cea0a28cee | |||
557fe5a9a2 | |||
f7e59edaf2 | |||
4052534235 | |||
ee885b516f | |||
a4d551e420 | |||
b943fee515 | |||
5f9a52977b | |||
1d12d5f144 | |||
fddfa80f76 | |||
c04936d0dc | |||
13b3fe03b8 | |||
79a13b8b6a | |||
2e11f067e2 | |||
e1e6ce5d34 | |||
4528e61fcd | |||
881f9ea7ea | |||
b1da4bb81b | |||
50d8d0b278 | |||
7e0b30e845 | |||
349ebca08d | |||
6dcec02377 | |||
da166c7bc3 | |||
80f48acb07 | |||
c1d8693d3c | |||
6ae0ee5b26 | |||
098fcc4f12 | |||
bfa61632c2 | |||
e25eed7687 | |||
4412690652 | |||
7c53cafbbe | |||
f2629f1b51 | |||
6fa1084d21 | |||
ba5621f4b7 | |||
fdb2b52f2f | |||
02f0349525 | |||
de95a1ba61 | |||
b7ec4e3b20 | |||
37988fbfd4 | |||
d0c8c2a418 | |||
953be9cccd | |||
2a0ba039e6 | |||
c170bff720 | |||
489c813bcc | |||
d6a4048793 | |||
6a24e1b935 | |||
9373a24413 | |||
7514071d79 | |||
2580b7cb20 | |||
6cda616236 | |||
4f2853e1b8 | |||
835d2277d8 | |||
6829c16ced | |||
8bc71b268e | |||
e8120fcdef | |||
bc6cecc14a | |||
f5ba859560 | |||
b2de4ee08c | |||
d82810d5e7 | |||
9cf65be1be | |||
540bd63f4c | |||
ecc61d184b | |||
36ed787db1 | |||
ab0a3bfd45 | |||
36f20d235c | |||
454d56935c | |||
afbaec8e2d | |||
e3cc45d7e3 | |||
d6b60723d9 | |||
94fee2d429 | |||
650bfd1ad3 | |||
568954e9e0 | |||
b6022d2ff1 | |||
b1ea53ef1e | |||
5f9a445aa2 | |||
d6aa6875cc | |||
5d0a1858cc | |||
07ca738842 | |||
6567fd1023 | |||
c8e376a625 | |||
b881b57a1b | |||
a9fcb6a183 | |||
18af6228a0 | |||
4f8fdc973f | |||
5f81b0866a | |||
7ae2b44806 | |||
8ffd10cacc | |||
d4e8db49d2 | |||
86babcf07b | |||
9d7291eea2 | |||
77aff26204 | |||
64e1355e06 | |||
f4f0796459 | |||
974434d326 | |||
5e8eb7151b | |||
970e018c27 | |||
67835dd7f7 | |||
ee01b6253e | |||
1a4dbce350 | |||
4d6d4dd44d | |||
c49580ea51 | |||
4d6215f546 | |||
fd7709ea81 | |||
10378ef1bb | |||
3b8903b2e2 | |||
b9ed485d60 | |||
b8130265cd | |||
e4a227359b | |||
f9ae4860d9 | |||
3a092fd920 | |||
519d55af4b | |||
e46b4c51d5 | |||
02f7b1ae4a | |||
305f8aa561 | |||
1e0d9561a2 | |||
12d5422e7f | |||
4590e1d9c9 | |||
f6abe2b466 | |||
c2fb224fea | |||
3a69bc705a | |||
c0f936b757 | |||
1ad30f33a5 | |||
fc1dedeb7a | |||
b8baca92e2 | |||
43deed9dc0 | |||
2d4551d559 | |||
9a056e6ad5 | |||
60e75612fd | |||
45eadb8302 | |||
617507b3d4 | |||
fa7281794a | |||
4aba46e02c | |||
24d2405fc8 | |||
03ec64672b | |||
7e25f5012e | |||
d432443545 | |||
bb18525ed9 | |||
430e535fe9 | |||
d0a7d2892e | |||
485ee2f8e0 | |||
a0ad48d169 | |||
95fe06a09b | |||
adef468c0b | |||
e5b297a513 | |||
a761b3f83c | |||
0e2ae50fc5 | |||
6fd10e7180 | |||
2b3fe93906 | |||
fdcd8e2800 | |||
4b396884c6 | |||
bd7a38ac2b | |||
abee554454 | |||
638573757b | |||
19c8703e15 | |||
44b384cd17 | |||
58f1c93de5 | |||
d447f4ba42 | |||
5e7a088da9 | |||
6e4d3393ba | |||
9c4b2872e3 | |||
42b570a274 | |||
673c24a34d | |||
8fa1d69db3 | |||
9791c11c99 | |||
2120ff8cca | |||
153c62337f | |||
db763e394d | |||
bc169d50b9 | |||
ce3841a23d | |||
2f0eace822 | |||
d8c0ba19fd | |||
5e557d2d46 | |||
4090941c3e | |||
27d6e95062 | |||
66e2d782b2 | |||
25867e76b1 | |||
a2626afebb | |||
25c59aa187 | |||
d14d7ae66d | |||
ac83e66016 | |||
c79e17514c | |||
93ec49bf8d | |||
0854b1c778 | |||
887d193526 | |||
4e74dc7bee | |||
10f1898b98 | |||
341966e709 | |||
00d4a7602a | |||
94c178941d | |||
a81e7c5057 | |||
23906047ec | |||
73df54abb0 | |||
bac8166611 | |||
bd52da8afd | |||
20fd204aa9 | |||
8bfe2405cd | |||
29fd2653f1 | |||
d9453c3b83 | |||
d9d7559097 | |||
c338c4fb58 | |||
e4936b1bed | |||
b9753dc5ba | |||
c4c1f09f2e | |||
74f116f2fa | |||
6365f497a7 | |||
b3a2cc4367 | |||
bbf0def3ff | |||
b6522c9fb3 | |||
62b3e16ac4 | |||
5431dfc9bd | |||
4d473315fe | |||
3f2910c3a7 | |||
8b415883e9 | |||
ec02332615 | |||
8a9ed28845 | |||
5d67b896aa | |||
ff9bcd6b14 | |||
58d6b59b7c | |||
c97d319b2a | |||
9cea0c50c3 | |||
8ee6a23229 | |||
b6c5796121 | |||
2d72942d47 | |||
12a367f65f | |||
d5677c20f7 | |||
b80ecfb600 | |||
9c217ad91e | |||
d37f48336b | |||
3e17de0127 | |||
8858084f6e | |||
283b897ae7 | |||
8c10cbe37b | |||
130a3ce727 | |||
33ac72de83 | |||
fcc9858b66 | |||
828d791da5 | |||
3965c08bfb | |||
eddc620307 | |||
0b1136ad28 | |||
b49d37e15a | |||
d33ae9ede7 | |||
b89e440fc4 | |||
7ea2fd67c7 | |||
04b04ed859 | |||
e62c527d05 | |||
873bb2f79e | |||
762ae04bb2 | |||
1f381d9477 | |||
ed603f4e48 | |||
293082a7e8 | |||
a9699ad969 | |||
279697b326 | |||
6f1f92c9d1 | |||
cf1a1185fc | |||
c6e8c40b2c | |||
46945a8674 | |||
5fe3ac09a5 | |||
f35c42aead | |||
e9dd0f8f6d | |||
c493273a21 | |||
fac2fc4971 | |||
72b503bb8f | |||
fba820a1c0 | |||
578b4a4408 | |||
2b445369fd | |||
2b2b14193f | |||
141a3e9be8 | |||
d36202d86b | |||
a0dd3f585b | |||
577e96bc95 | |||
266e1a8527 | |||
93b7bbc43e | |||
5be341d991 | |||
4a404835c0 | |||
d81ae3c35f | |||
0a9173559d | |||
55608f0660 | |||
f8a5e04dc7 | |||
ad5ee7fa44 | |||
32cda0f58b | |||
868ba0cd03 | |||
46165f8166 | |||
0484daac23 | |||
23f12d2fd1 | |||
44aae18311 | |||
41eefda1bc | |||
f376c01e02 | |||
e223a6eac0 | |||
35cd18240c | |||
073ebb4afe | |||
5265575186 | |||
49524abeb7 | |||
4f25bdd121 | |||
43ed7d4bc5 | |||
1f687ffc38 | |||
ad168f18b3 | |||
f932c4c2c5 | |||
17a336ba0a | |||
da98cd77e8 | |||
5aa98a1aff | |||
2c65dd87e1 | |||
b52bade150 | |||
e3730a9b94 | |||
8d1cbd9f8b | |||
92b732a189 | |||
f35ed8101a | |||
d980c0404c | |||
609d429161 | |||
666c7bc77f | |||
33bd5cb63a | |||
311d03e680 | |||
55dec574c5 | |||
c599714aea | |||
f60a80f308 | |||
8d0c6ebc57 | |||
608632fde3 | |||
4ca892e9f3 | |||
08c225a633 | |||
20936faec6 | |||
75ab11fc35 | |||
ba541300ca | |||
31093c0d13 | |||
d5867f104f | |||
46a756b1ee | |||
ed76062904 | |||
e897fb63d8 | |||
098741ffe6 | |||
e87221a8a3 | |||
ffc7a55763 |
7
.gitignore
vendored
7
.gitignore
vendored
@ -12,8 +12,13 @@
|
||||
#vscode
|
||||
/.vscode
|
||||
|
||||
# IntelliJ
|
||||
/.idea/*
|
||||
|
||||
# Python
|
||||
__pycache__
|
||||
.idea
|
||||
|
||||
# CLion
|
||||
!/.idea/cmake.xml
|
||||
|
||||
generators/*.db
|
||||
|
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -10,9 +10,6 @@
|
||||
[submodule "thirdparty/lwgps"]
|
||||
path = thirdparty/lwgps
|
||||
url = https://github.com/rmspacefish/lwgps.git
|
||||
[submodule "generators/fsfwgen"]
|
||||
path = generators/deps/fsfwgen
|
||||
url = https://egit.irs.uni-stuttgart.de/fsfw/fsfw-gen.git
|
||||
[submodule "thirdparty/arcsec_star_tracker"]
|
||||
path = thirdparty/arcsec_star_tracker
|
||||
url = https://egit.irs.uni-stuttgart.de/eive/arcsec_star_tracker.git
|
||||
|
16
.idea/cmake.xml
generated
Normal file
16
.idea/cmake.xml
generated
Normal file
@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="CMakeSharedSettings">
|
||||
<configurations>
|
||||
<configuration PROFILE_NAME="Debug" ENABLED="true" CONFIG_NAME="Debug" NO_GENERATOR="true" />
|
||||
<configuration PROFILE_NAME="Debug Q7S" ENABLED="true" CONFIG_NAME="Debug" TOOLCHAIN_NAME="Q7S" GENERATION_OPTIONS="-DTGT_BSP="arm/q7s"" NO_GENERATOR="true">
|
||||
<ADDITIONAL_GENERATION_ENVIRONMENT>
|
||||
<envs>
|
||||
<env name="ZYNQ_7020_ROOTFS" value="/opt/xiphos/sdk/ark/sysroots/cortexa9hf-neon-xiphos-linux-gnueabi" />
|
||||
<env name="CROSS_COMPILE" value="/opt/q7s-gcc/gcc-arm-8.3-2019.03-x86_64-arm-linux-gnueabihf/bin/arm-linux-gnueabihf" />
|
||||
</envs>
|
||||
</ADDITIONAL_GENERATION_ENVIRONMENT>
|
||||
</configuration>
|
||||
</configurations>
|
||||
</component>
|
||||
</project>
|
10
.run/Q7S FM.run.xml
Normal file
10
.run/Q7S FM.run.xml
Normal file
@ -0,0 +1,10 @@
|
||||
<component name="ProjectRunConfigurationManager">
|
||||
<configuration default="false" name="Q7S FM" type="com.jetbrains.cidr.remote.gdbserver.type" factoryName="com.jetbrains.cidr.remote.gdbserver.factory" REDIRECT_INPUT="false" ELEVATE="false" USE_EXTERNAL_CONSOLE="false" PASS_PARENT_ENVS_2="true" PROJECT_NAME="eive-obsw" TARGET_NAME="eive-obsw" CONFIG_NAME="Debug" version="1" RUN_TARGET_PROJECT_NAME="eive-obsw" RUN_TARGET_NAME="eive-obsw">
|
||||
<custom-gdb-server version="1" gdb-connect="localhost:1234" executable="" warmup-ms="0" download-type="NONE" sshConfigName="Q7S FM" uploadFile="/tmp/eive-obsw" defaultGdbServerArgs=":1234 /tmp/eive-obsw">
|
||||
<debugger kind="GDB" isBundled="true" />
|
||||
</custom-gdb-server>
|
||||
<method v="2">
|
||||
<option name="CLION.COMPOUND.BUILD" enabled="true" />
|
||||
</method>
|
||||
</configuration>
|
||||
</component>
|
711
CHANGELOG.md
711
CHANGELOG.md
@ -8,15 +8,714 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/).
|
||||
The [milestone](https://egit.irs.uni-stuttgart.de/eive/eive-obsw/milestones)
|
||||
list yields a list of all related PRs for each release.
|
||||
|
||||
Starting at v2.0.0, the following changes will consitute of a breaking
|
||||
change warranting a new major release:
|
||||
Starting at v2.0.0, this project will adhere to semantic versioning and the the following changes
|
||||
will consitute of a breaking change warranting a new major release:
|
||||
|
||||
- The TMTC interface changes in any shape of form.
|
||||
- The behavour of the OBSW changes in a major shape or form relevant
|
||||
for operations
|
||||
- The behaviour of the OBSW changes in a major shape or form relevant for operations
|
||||
|
||||
# [unreleased]
|
||||
|
||||
# [v1.39.1] 2023-03-22
|
||||
|
||||
## Fixed
|
||||
|
||||
- Bugfix for STR: Some action commands wrongfully declined.
|
||||
- STR: No normal command handling while a special request like an image upload is active.
|
||||
- RS485 data line was not enabled when the transmitter was switched on.
|
||||
|
||||
# [v1.39.0] 2023-03-21
|
||||
|
||||
Requires firmware update for new FPGA design where reset line is routed into the software.
|
||||
2 relevant PRs:
|
||||
- https://egit.irs.uni-stuttgart.de/eive/q7s-vivado/pulls/53
|
||||
- https://egit.irs.uni-stuttgart.de/eive/q7s-vivado/pulls/54
|
||||
|
||||
eive-tmtc: v2.19.3
|
||||
|
||||
## Added
|
||||
|
||||
- Added NaN and Inf check for the `MEKF`. If these are detected, the `AcsController` will reset
|
||||
the `MEKF` on its own once. This way, there will not be an event spam and operators will have
|
||||
to look into the reason of wrong outputs. To restore the reset ability, an action command has
|
||||
been added.
|
||||
- Contingency handling for non-working I2C bus bug. Reboot the system if the I2C is not working.
|
||||
|
||||
## Fixed
|
||||
|
||||
- Fixed transition for dual power lane assemblies: When going from dual side submode to single side
|
||||
submode, perform logical commanding first, similarly to when going to OFF mode.
|
||||
- GPS time is only set to valid if at least one satellite is in view.
|
||||
|
||||
## Changed
|
||||
|
||||
- Bugfixes for STR mode transitions: Booting to mode ON with submode FIRMWARE now works properly.
|
||||
Furthermore, the submode in the NORMAL mode now should be 0 instead of some ON mode submode.
|
||||
- Updated GYR bias values to newest measurements. This also corrects the ADIS values to always
|
||||
consit of just one digit.
|
||||
- The CCSDS IP core handler now exposes a parameter to enable the priority select mode
|
||||
for the PTME core. This mode prioritizes virtual channels with a lower index, so for example
|
||||
the virtual channel (VC0) will have the highest priority, while VC3 will have the lowestg
|
||||
priority. This mode will be enabled by default for now, but can be set via the parameter IF with
|
||||
the unique parameter ID 0. The update of this mode requires a PTME reset. Therefore, it will only
|
||||
be performed when the transmitter is off to avoid weird bugs.
|
||||
- Connect and handle reset line for the PTME core in the software now.
|
||||
- Safe mode controller failure event now only triggers once per minute.
|
||||
|
||||
# [v1.38.0] 2023-03-17
|
||||
|
||||
eive-tmtc: v2.19.2
|
||||
|
||||
## Fixed
|
||||
|
||||
- SA deployment file handling: Use exceptionless API.
|
||||
- Fix deadlock in SD card manager constructor: Double lock of preferred SD card lock.
|
||||
|
||||
## Added
|
||||
|
||||
- Failure of Safe Mode Ctrl will now trigger an event. As this can only be caused by sensors not
|
||||
being in the correct mode, the assemblies should take care that this will never happen and no
|
||||
additional FDIR is needed.
|
||||
|
||||
## Changed
|
||||
|
||||
- Telemetry relevant datasets for the RWs are now set invalid and partially reset on shotdown.
|
||||
- I2C PST now has a polling frequency of 0.4 seconds instead of 0.2 seconds.
|
||||
- GS PST now has a polling frequency of 0.5 seconds instead of 1 second.
|
||||
- Bump FSFW: merged upstream.
|
||||
- Move BPX battery scheduling to ACS PST to avoid clashes with IMTQ scheduling / polling
|
||||
|
||||
# [v1.37.2] 2023-03-14
|
||||
|
||||
- Changed `PoolManager` bugfix implementation in the FSFW.
|
||||
- Some tweaks for IPC and TM store configuration
|
||||
|
||||
# [v1.37.1] 2023-03-14
|
||||
|
||||
This version works on the EM as well.
|
||||
|
||||
eive-tmtc: v2.19.1
|
||||
|
||||
## Added
|
||||
|
||||
- Added `EXECUTE_SHELL_CMD` action command for `CoreController` to execute arbitrary Linux commands.
|
||||
- Added some missing PLOC commands.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/462
|
||||
- Add `PcduHandlerDummy` component.
|
||||
- Added parameter for timeout until `MEKF_INVALID_MODE_VIOLATION` event is triggered.
|
||||
|
||||
## Fixed
|
||||
|
||||
- Pointing control of the `AcsController` was still expecting submodes instead of modes.
|
||||
- Limitation of RW speeds was done before converting them to the correct unit scale.
|
||||
- The Syrlinks task now has a proper name instead of `MAIN_SPI`.
|
||||
- Make whole EIVE system initial transition work for the EM. This was also made possible by
|
||||
always scheduling most EIVE components instead of tying the scheduling to preprocessor defines.
|
||||
- Store more TCP und UDP packets.
|
||||
- Bump fsfw for small tweak in local datapool manager: Re-enable or re-disabling dataset
|
||||
generation will not fail anymore.
|
||||
- Bump FSFW to simplify HK helpers: Was previously buggy and did not allow to use
|
||||
minmum sampling frequency. Now both diagnostics and HK can use minimum
|
||||
sampling frequency for requesting HK
|
||||
- Bump FSFW to allow the TC/TM/IPC pools to spill to higher pools/pool pages.
|
||||
|
||||
## Changed
|
||||
|
||||
- Set `OBSW_ADD_TCS_CTRL` to 1. Always add TCS controller now for both EM and FM.
|
||||
- generators module: Bump `fsfwgen` dependency to v0.3.1. The returnvalue CSV files are now sorted.
|
||||
- generators module: Always generate subsystem ID CSV files now.
|
||||
- The COM subsystem is now not commanded by the EIVE system anymore. Instead,
|
||||
a separate RX_ONLY mode command will be sent at OBSW boot. After that,
|
||||
commanding is done autonomously by the COM subsystem internally or by the operator. This prevents
|
||||
the transmitter from going off during fallbacks to the SAFE mode, which might not always be
|
||||
desired.
|
||||
- Initialize switch states to a special `SWITCH_STATE_UNKNOWN` (2) variable. Return
|
||||
`PowerSwitchIF::SWITCH_UNKNOWN` in switch state getter if this is the state.
|
||||
- Wait 1 second before commanding SAFE mode. This ensures or at least increases the chance that
|
||||
the switch states were initialized.
|
||||
- Dual Lane Assemblies: The returnvalues of the dual lane power state machine FSM are not ignored
|
||||
anymore.
|
||||
|
||||
# [v1.37.0] 2023-03-11
|
||||
|
||||
eive-tmtc: v2.18.1
|
||||
|
||||
## Added
|
||||
|
||||
- `SensorProcessing` now includes an FDIR for GPS altitude. If the measured GPS altitude is out
|
||||
of bounds of the range defined in the `AcsParameters`, the altitude defaults to an altitude
|
||||
set in the `AcsParameters`.
|
||||
- `AcsController` will now never command a RW speed larger than the maximum allowed speed.
|
||||
|
||||
## Fixed
|
||||
|
||||
- `PAPB_EMPTY_SIGNAL_VC1` GPIO was not set up properly.
|
||||
- Fix for heater names: HPA heater (index 7) is now the Syrlinks heater.
|
||||
- `AcsParameters` setter were previously all for scalar parameters. Now vector and matrix
|
||||
parameters use their respective setters.
|
||||
- Several `AcsController` components had their own implementation of `AcsParameters`. This resulted
|
||||
in those parameters not being updated, while the actual ones were updated. All instances of
|
||||
`AcsParameters` not belonging to `AcsController` are eiter removed or replaced by pointer
|
||||
instances.
|
||||
- Instead of updating the `gsTargetModeControllerParameters`, the `targetModeControllerParameters`
|
||||
were updated.
|
||||
- Instead of updating the `idleModeControllerParameters`, the `targetModeControllerParameters`
|
||||
were updated.
|
||||
- Fixed Idle Mode Controller never calling `ptgLaw` and therefore never calculating control
|
||||
values.
|
||||
- Fixed wrong check on wether file used for persistant boolean flag on successful still existed.
|
||||
- Scaling of MTQ Cmds now scales the current values to command with the current values and not
|
||||
the values of the last step, which would result in undefined behaviour.
|
||||
- Solved naming collision between file used for solar array deployment and confirmation for
|
||||
ACS for solar array deployment.
|
||||
- Fixed that scaling of RW torque would result in a zero vector unless the maximum value was exceeded.
|
||||
- Bias for the GYR data was substracted within the wrong rf (sensor rf vs body rf).
|
||||
|
||||
## Changed
|
||||
|
||||
- Refactored TM pipeline to optimize usage of the PTME and communication downlink bandwidth.
|
||||
This was done by moving the dumping of TMs to the VCs into separate threads with permanent loops.
|
||||
These threads are then able to process high TM loads on demand. The PUS TM funnel will route
|
||||
PUS packets to the approrpiate persisten TM stores and then demultiplex the TM to all registered
|
||||
TM destinations as before.
|
||||
- Service 5 now handles 40 events per cycle instead of 15
|
||||
- Remove periodic SD card check. The file system is not mounted read-only anymore when using an
|
||||
ext4 filesystem
|
||||
- The `detumbleCounter` now does not get hard reset anymore, if the critical rate does not get
|
||||
violated anymore. Instead it is incrementally reset.
|
||||
- The RW antistiction now only takes the RW speeds in account.
|
||||
- ACS CTRL transition to DETUBMLE is now done in CTRL internally. No
|
||||
system level handling necessary anymore.
|
||||
- More fixes and improvements for SD card handling. Extend SD card setup in core controller to
|
||||
create full initial state for SD card manager are core controller as early as possible, turn
|
||||
execution of setup file update blocking. This might solve the issue with the SD card manager
|
||||
sometimes blocking for a long time.
|
||||
- Request raw MTM measurement twice for IMTQ, might reduce number of times measurement could not
|
||||
be retrieved.
|
||||
- Event manager and event service have larger queues now: 45 -> 120 for Service 5, 80 -> 120 for
|
||||
event manager
|
||||
- ACS mode changes: The ACS CTRL submodes are now modes. DETUBMLE is now submode of SAFE mode.
|
||||
- EIVE system now tracks the mode of the ACS subsyste in SAFE mode.
|
||||
|
||||
# [v1.36.0] 2023-03-08
|
||||
|
||||
eive-tmtc: v2.17.2
|
||||
|
||||
## Added
|
||||
|
||||
- Star Tracker Assembly
|
||||
- New `REBOOT_COUNTER` and `INDIVIDUAL_BOOT_COUNTS` events. The first contains the total boot count
|
||||
as a u64, the second one contains the individual boot counts as 4 u16. Add new core controller
|
||||
action command `ANNOUNCE_BOOT_COUNTS` with action ID 3 which triggers both events. These events
|
||||
will also be triggered on each reboot.
|
||||
|
||||
## Changed
|
||||
|
||||
- Persistent TM stores will now create new files on each reboot.
|
||||
- Fast ACS subsystem commanding: Command SUS board consecutively with other devices now
|
||||
- Star Tracker: Use ground confguration for EM and flight config for FM by default.
|
||||
|
||||
## Fixed
|
||||
|
||||
- Command TCS controller off first for TCS subsystem transition to off.
|
||||
- Health handling for TCS board assembly
|
||||
- Mode fallback from IDLE mode to SAFE mode due to ACS errors/events now works properly for
|
||||
the ACS subsystem
|
||||
- Bugfix in IDLE transition for system.
|
||||
- `std::filesystem` API usages: Avoid exceptions by using variants which return an error code
|
||||
instead of throwing exceptions.
|
||||
- GPS fix loss was not reported if mode is unset.
|
||||
- Star Tracker: OFF to NORMAL transition now posssible. Requires FSFW bump which sets
|
||||
transition source modes properly for those transitions.
|
||||
FSFW PR: https://egit.irs.uni-stuttgart.de/eive/fsfw/pulls/131
|
||||
- Star Tracker JSON initialization is now done during object initization instead of redoing it
|
||||
when building a command. This avoids missed deadlines issues in the ACS PST.
|
||||
- Allow arbitrary submodes for dual lane boards to avoid FDIR reactions of subsystem components.
|
||||
Bump FSFW to allow this.
|
||||
- PUS 15 was not scheduled
|
||||
- Transmitter timeout set to 2 minutes instead of 15 minutes. This will prevent to discharge the
|
||||
battery in case the syrlinks starts transmitting due to detection of unintentional bitlock. This
|
||||
happened e.g. on ground when the uplink to the flying latop was established.
|
||||
- ACS system components are now always scheduled (EM specific)
|
||||
|
||||
# [v1.35.1] 2023-03-04
|
||||
|
||||
## Fixed
|
||||
|
||||
- ACS Board Assembly FDIR: Prevent permanent SAFE mode fallbacks by introducing special health
|
||||
handling.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/418/files
|
||||
- Watchdog fixes
|
||||
- IMTQ timing fixes
|
||||
|
||||
## Added
|
||||
|
||||
- Add IMTQ assembly
|
||||
|
||||
# [v1.35.0] 2023-03-04
|
||||
|
||||
eive-tmtc: v2.16.4
|
||||
|
||||
## Added
|
||||
|
||||
- Improved the OBSW watchdog by adding a watch functionality. The watch functionality is optional
|
||||
and has to be enabled specifically by the application being watched by the watchdog when
|
||||
starting the watchdog. If the watch functionality is enabled and the OBSW has not pinged
|
||||
the watchdog via the FIFO for 2 minutes, the watchdog will restart the OBSW service via systemd.
|
||||
The primary OBSW will only activate the watch functionality if it is the OBSW inside the
|
||||
`/usr/bin` directory. This allows debugging the system by leaving flashed or manually copied
|
||||
debugging images 2 minutes to start the watchdog without the watch functionality.
|
||||
|
||||
## Fixed
|
||||
|
||||
- Bumped FSFW: `Countdown` and `Stopwatch` use new monotonic clock API now.
|
||||
- IMTQ: Various fixes, most notably missing buffer time after starting MGM measurement
|
||||
and corrections for actuator commanding.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/430
|
||||
|
||||
# [v1.34.0] 2023-03-03
|
||||
|
||||
eive-tmtc: v2.16.3
|
||||
|
||||
This might include the fix for the race condition where CPU usage jumped to 200 %. The race
|
||||
condition was traced to the `Countdown` class, more specifically to the `getUptime` function where
|
||||
the `/proc/uptime` file is read.
|
||||
|
||||
## Changed
|
||||
|
||||
- The SD card prefix is now set earlier inside the `CoreController` constructor
|
||||
- The watchdog handling was moved outside the `CoreController` into the main loop.
|
||||
- Moved polling of all SPI parts to the same PST.
|
||||
- Allow quicker transition for the EIVE system component by allowing consecutive TCS and ACS
|
||||
component commanding again.
|
||||
- Changed a lot of lock guards to use timeouts
|
||||
- Queue sizes of TCP/UDP servers increased from 20 to 50
|
||||
- Significantly simplified and improved lock guard handling in TCS and ACS board polling
|
||||
tasks.
|
||||
|
||||
## Fixed
|
||||
|
||||
- IMTQ: Sets were filled with wrong data, e.g. Raw MTM was filled with calibrated MTM measurements.
|
||||
- Set RM3100 dataset to valid.
|
||||
- Fixed units in calculation of ACS control laws safe and detumble.
|
||||
- Bump FSFW for change in Countdown: Use system clock instead of reading uptime from file
|
||||
to prevent possible race condition.
|
||||
- GPS: No fix considered a fault now after 30 minutes instead of 5 hours.
|
||||
- SUS Assembly FDIR: Prevent permanent SAFE mode fallbacks by introducing special health
|
||||
handling.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/418/files
|
||||
|
||||
## Added
|
||||
|
||||
- Added Syrlinks Assembly object to allow recovery handling and to fix faulty FDIR behaviour.
|
||||
|
||||
# [v1.33.0] 2023-03-01
|
||||
|
||||
eive-tmtc: v2.16.2
|
||||
|
||||
## Changed
|
||||
|
||||
- Move ACS board polling to separate worker thread.
|
||||
- Move SUS board polling to separate worker thread.
|
||||
|
||||
## Fixed
|
||||
|
||||
- Linux GPS handler now checks the individual `*_SET` flags when analysing the `gpsd` struct.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/400
|
||||
|
||||
# [v1.32.0] 2023-02-24
|
||||
|
||||
eive-tmtc: v2.16.1
|
||||
|
||||
## Fixed
|
||||
|
||||
- ADIS1650X: Added missing MDL_RANG pool entry for configuration set
|
||||
- Bumped FSFW for bugfix in health service: No execution complete for targeted health announce
|
||||
command.
|
||||
- Removed matrix determinant calculation as part of the `MEKF`, which would take about
|
||||
300ms of runtime
|
||||
- Resetting the `MEKF` now also actually resets its stored state
|
||||
- Bumped FSFW for bugfix in destination handler: Better error handling and able to process
|
||||
destination folder path.
|
||||
|
||||
## Changed
|
||||
|
||||
- Added basic persistent TM store for PUS telemetry and basic interface to dump and delete
|
||||
telemetry. Implementation is based on a timed rotating files, with the addition that files
|
||||
might be generated more often if the maximum file size of 8192 bytes is exceeded.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/320/files
|
||||
- Commented out commanding of actuators as part of the `AcsController`
|
||||
- Collection sets of the `AcsController` now get updated before running the actual ACS
|
||||
algorithm
|
||||
- `GpsController` now always gets scheduled
|
||||
- The `CoreController` now initializes the initial clock from the time file as early as possible
|
||||
(in the constructor) if possible, which should usually be the case.
|
||||
|
||||
## Added
|
||||
|
||||
- Added basic persistent TM store for PUS telemetry and basic interface to dump and delete
|
||||
telemetry.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/320/files
|
||||
- `ExecutableComIfDummy` class to have a dummy for classes like the RTD polling class.
|
||||
- Added `AcsController` action command to confirm solar array deployment, which then deletes
|
||||
two files
|
||||
- Added `AcsController` action command to reset `MEKF`
|
||||
- `GpsCtrlDummy` now initializes the `gpsSet`
|
||||
- `RwDummy` now initializes with a non faulty state
|
||||
|
||||
|
||||
# [v1.31.1] 2023-02-23
|
||||
|
||||
## Fixed
|
||||
|
||||
- ADIS1650X configuration set was empty because the local pool variables were not registered.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/402
|
||||
- ACS Controller: Correction for size of MEKF dataset and some optimization and fixes
|
||||
for actuator control which lead to a crash.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/403
|
||||
|
||||
# [v1.31.0] 2023-02-23
|
||||
|
||||
eive-tmtc: v2.16.0
|
||||
|
||||
## Fixed
|
||||
|
||||
- Usage of floats as iterators and using them to calculate a uint8_t index in `SusConverter`
|
||||
- Removed unused variables in the `AcsController`
|
||||
- Remove shadowing variables inside ACS assembly classes.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/issues/385
|
||||
|
||||
## Changed
|
||||
|
||||
COM PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/364
|
||||
|
||||
* Moved transmitter timer and handling of carrier and bitlock event from CCSDS handler to COM
|
||||
subsystem
|
||||
* Added parameter command to be able to change the transmitter timeout
|
||||
* Solves [#362](https://egit.irs.uni-stuttgart.de/eive/eive-obsw/issues/362)
|
||||
* Solves [#360](https://egit.irs.uni-stuttgart.de/eive/eive-obsw/issues/360)
|
||||
* Solves [#361](https://egit.irs.uni-stuttgart.de/eive/eive-obsw/issues/361)
|
||||
* Solves [#386](https://egit.irs.uni-stuttgart.de/eive/eive-obsw/issues/386)
|
||||
- All `targetQuat` functions in `Guidance` now return the target quaternion (target
|
||||
in ECI frame), which is passed on to `CtrlValData`.
|
||||
- Moved polling sequence table definitions and source code to `mission/core` folder.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/395
|
||||
|
||||
## Added
|
||||
|
||||
- `MEKF` now returns an unique returnvalue depending on why the function terminates. These
|
||||
returnvalues are used in the `AcsController` to determine on how to procede with its
|
||||
perform functions. In case the `MEKF` did terminate before estimating the quaternion
|
||||
and rotational rate, an info event will be triggered. Another info event can only be
|
||||
triggered after the `MEKF` has run successfully again. If the `AcsController` tries to
|
||||
perform any pointing mode and the `MEKF` fails, the `performPointingCtrl` function will
|
||||
set the RWs to the last RW speeds and set a zero dipole vector. If the `MEKF` does not
|
||||
recover within 5 cycles (2 mins) the `AcsController` triggers another event, resulting in
|
||||
the `AcsSubsystem` being commanded to `SAFE`.
|
||||
- `MekfData` now includes `mekfStatus`
|
||||
- `CtrlValData` now includes `tgtRotRate`
|
||||
|
||||
# [v1.30.0] 2023-02-22
|
||||
|
||||
eive-tmtc: v2.14.0
|
||||
|
||||
Event IDs for PDEC handler have changed in a breaking manner.
|
||||
|
||||
## Added and Fixed
|
||||
|
||||
- PDEC: Added basic FDIR to limit the number of allowed TC interrupts and to allow complete task
|
||||
lockups in the case an IRQ is immediately re-raised by the PDEC module. This is done by only
|
||||
allowing a certain number of handled IRQs (whether they yield a valid TC or not) during
|
||||
time windows of one second. Right now, 800 IRQs/TCs are allowed per time window.
|
||||
This time window is reset if a TC reception timeout after 500ms occurs. TBD whether the maximum
|
||||
allowed number will be a configurable parameter. If the number of occured IRQs is exceeded,
|
||||
an event is triggered and the task is delayed for 400 ms.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/393
|
||||
|
||||
# [v1.29.1] 2023-02-21
|
||||
|
||||
## Fixed
|
||||
|
||||
- Limit number of handled messages for core TM handlers:
|
||||
- https://egit.irs.uni-stuttgart.de/eive/eive-obsw/issues/391
|
||||
- https://egit.irs.uni-stuttgart.de/eive/eive-obsw/issues/390
|
||||
- https://egit.irs.uni-stuttgart.de/eive/eive-obsw/issues/389
|
||||
- HeaterHandler better handling for faulty message reception
|
||||
Issue: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/issues/388
|
||||
- Disable stopwatch in MAX31865 polling task
|
||||
|
||||
# [v1.29.0] 2023-02-21
|
||||
|
||||
eive-tmtc: v2.13.0
|
||||
|
||||
## Changed
|
||||
|
||||
- Refactored IMTQ handlers to also perform low level I2C communication tasks in separate thread.
|
||||
This avoids the various delays needed for I2C communication with that device inside the ACS PST.
|
||||
(e.g. 1 ms delay between each transfer, or 10 ms integration delay for MGM measurements).
|
||||
|
||||
## Added
|
||||
|
||||
- Added new heater info set for the TCS controller. This set contains the heater switch states
|
||||
and the current draw.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/351
|
||||
- The HeaterHandler now exposes a mode which reflects whether the heater power
|
||||
is on or off. It also triggers mode events for its heater children objects
|
||||
which show whether the specific heaters are on or off. The heater handler
|
||||
will be part of the TCS tree.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/351
|
||||
|
||||
# [v1.28.1] 2023-02-21
|
||||
|
||||
## Fixed
|
||||
|
||||
- Patch version which compiles for EM
|
||||
- CFDP Funnel bugfix: CCSDS wrapping was buggy and works properly now.
|
||||
- PDEC: Some adaptions to prevent task lockups on invalid FAR states.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/393
|
||||
- CMakeLists.txt fix which broke CI/CD builds when server could not retrieve full git SHA.
|
||||
- Possible regression in the MAX31865 polling task: Using a `ManualCsLockGuard` for reconfiguring
|
||||
and then polling the sensor is problematic, invalid sensor values will be read.
|
||||
CS probably needs to be de-asserted or some other HW/SPI specific issue. Letting the SPI ComIF
|
||||
do the locking does the job.
|
||||
|
||||
## Changed
|
||||
|
||||
- Add `-Wshadow=local` shadowing warnings and fixed all of them
|
||||
- Updated generated CSV files: Support for skip directive and explicit
|
||||
"No description" info string
|
||||
- The polling threads for actuator polling now have a slightly higher priority than the ACS PST
|
||||
to ensure timing requirements are met.
|
||||
|
||||
## Added
|
||||
|
||||
- git post checkout hook which initializes and updates the submodules
|
||||
automatically.
|
||||
|
||||
# [v1.28.0] 2023-02-17
|
||||
|
||||
eive-tmtc: v2.12.7
|
||||
|
||||
## Added
|
||||
|
||||
- In case the ACS Controller does recognize more than one RW to be invalid and therefore not
|
||||
available, it does not perform pointing control but aborts shortly after `sensorProcessing`. If the
|
||||
problem persits for 5 ACS cycles, the `MULTIPLE_RW_INVALID` event is triggered, which invokes the
|
||||
transition of the `AcsSubsystem` to safe mode.
|
||||
|
||||
## Changed
|
||||
|
||||
- Igrf13 model vector now outputs as uT instead of nT
|
||||
- Changed timings for `AcsPst`, more time for sun sensors.
|
||||
- Added values for MGM sensor fusion
|
||||
- Refactored RW Software: Polling runs in separate thread, all RWs are now polled in under 60 ms.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/381
|
||||
- Bumped FSFW to allow initializing child modes in `SubsystemBase` derived objects.
|
||||
|
||||
## Fixed
|
||||
|
||||
- Fixed values for GYR sensor fusion
|
||||
- Fixed speed types for `rwHandlingParameter`
|
||||
- Pseudo inverse used for allocating torque to RWs and RW antistiction now actually consider the
|
||||
state of the RWs
|
||||
|
||||
# [v1.27.2] 2023-02-14
|
||||
|
||||
Reaction Wheel handling was determined to be (quasi) broken and needs to be fixed in future release
|
||||
to be usable by ACS controller.
|
||||
|
||||
eive-tmtc: v2.12.6
|
||||
|
||||
## Added
|
||||
|
||||
- Function for the ACS controller to command MTQ and RWs called by all subroutines
|
||||
- RwHandler now handles commanding of RW speeds via RwSpeedActuationSet
|
||||
- Tracing supports which allows checking whether threads are running as usual.
|
||||
|
||||
## Changed
|
||||
|
||||
- Remove 2 TCS threads.
|
||||
- Move low level polling into ACS PST, move high level device handlers into TCS system task.
|
||||
- ActCmds now returns command vectors as integers as required by the actuators
|
||||
and scales them to the appropriate range
|
||||
- All RwHandler are now polled five times per ACS cycle
|
||||
- Remove 2 TCS threads. Move low level polling into ACS PST, move high level device handlers into
|
||||
TCS system task.
|
||||
- Further reduce number of threads:
|
||||
1. Remove PUS low priority task, move assigned threads to the generic system task
|
||||
2. Group events and verification tasks into PUS high priority task
|
||||
3. Group all other components into PUS medium priority task
|
||||
4. Add SCEX device handler to PL task, remove dedicated thread
|
||||
|
||||
## Removed
|
||||
|
||||
- lwgps dependency not compiled anymore, is not used
|
||||
|
||||
# [v1.27.1] 2023-02-13
|
||||
|
||||
## Fixed
|
||||
|
||||
- Fix for SPI ComIF: Set transfer size to 0 for failed transfers
|
||||
- Fix shadowing issue with locks in MAX31865 low level handler
|
||||
|
||||
# [v1.27.0] 2023-02-13
|
||||
|
||||
eive-tmtc: v2.12.5
|
||||
|
||||
Added EIVE system top mode component. Currently, only SAFE and IDLE mode are
|
||||
implemented, and the system does not do more than commanding TCS and ACS
|
||||
into the correct modes. It does not have a lot of mode tracking capabilities
|
||||
yet because the ACS controller might alternate between SAFE and DETUMBLE.
|
||||
It takes around 5-10 seconds for the EIVE system to reach the SAFE mode.
|
||||
|
||||
The new system is used at software boot to command the satellite into safe mode
|
||||
on each reboot. This behaviour can be disabled with the
|
||||
`OBSW_SWITCH_TO_NORMAL_MODE_AFTER_STARTUP` flag.
|
||||
|
||||
## Added
|
||||
|
||||
- New EIVE system component like explained above.
|
||||
|
||||
## Changed
|
||||
|
||||
- The satellite now commands itself into SAFE mode on each reboot, which
|
||||
triggers a lot of events on each SW reboot. The TCS subsystem will commanded
|
||||
to NORMAL mode immediately while the ACS subsystem will be commanded to
|
||||
SAFE mode. The payload subsystem will be commanded OFF.
|
||||
- `RELEASE_BUILD` flag moved to `commonConfig.h`
|
||||
- The ACS subsystem transitions are now staggered: The SUS board assembly
|
||||
is commanded as a separate transition. This reduces the risk of long bus lockups.
|
||||
- No INFO mode event translations for release builds to reduce number of
|
||||
printouts.
|
||||
- More granular locking inside the MAX31865 low level read handler.
|
||||
|
||||
## Fixed
|
||||
|
||||
- More DHB thermal module fixes.
|
||||
- ACS PST frequency extended to 0.8 seconds in debug builds to avoid SPI
|
||||
bus lockups.
|
||||
- Local datapool fixes for the `PlocSupervisorHandler`
|
||||
|
||||
# [v1.26.4] 2023-02-10
|
||||
|
||||
eive-tmtc: v2.12.3
|
||||
|
||||
## Fixed
|
||||
|
||||
- `SdCardManager.cpp` `isSdCardUsable`: Use `ext4` instead of `vfat` to check read-only state.
|
||||
|
||||
# [v1.26.3] 2023-02-09
|
||||
|
||||
eive-tmtc: v2.12.2
|
||||
|
||||
## Added
|
||||
|
||||
- First version of a TCS controller heater control loop, but
|
||||
the loop is disabled for now.
|
||||
|
||||
## Changed
|
||||
|
||||
- Reworked dummy handling for the TCS controller.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/325
|
||||
- Generator scripts now generate files for hosted and for Q7S build.
|
||||
|
||||
## Fixed
|
||||
|
||||
- GPS Controller: Set fix value to 0 when switching off to allow
|
||||
`GPS_FIX_CHANGE` to work when switching the GPS back on.
|
||||
|
||||
# [v1.26.2] 2023-02-08
|
||||
|
||||
## Changed
|
||||
|
||||
- ACS Controller scheduling is now configurable via the `eive/definitions.h` file. Also ensured
|
||||
that scheduling is done in big blocks to reduce risk of missed deadlines.
|
||||
- Replaced chained locks for polling new sensor data to the `AcsController`.
|
||||
- Made TM store even larger.
|
||||
|
||||
## Fixed
|
||||
|
||||
- Bugfix for PDEC handler which causes the PIR register of the PDEC to never
|
||||
be cleared on release builds. The dummy variable used to read the register
|
||||
needs to be declared volatile to avoid compiler optimizations.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/374
|
||||
- Bumped FSFW for fix of possible memory leaks in TCP/IP TMTC bridge
|
||||
inside the FSFW.
|
||||
|
||||
## Added
|
||||
|
||||
- Create TCS controller for EM build.
|
||||
|
||||
# [v1.26.1] 2023-02-08
|
||||
|
||||
- Initialize parameter helper in ACS controller.
|
||||
|
||||
# [v1.26.0] 2023-02-08
|
||||
|
||||
eive-tmtc v2.12.1
|
||||
|
||||
## Changed
|
||||
|
||||
### ACS
|
||||
|
||||
- Readded calibration matrices for MGM calibration.
|
||||
- Added calculation of satellite velocity vector from GPS position data
|
||||
- Added detumble mode using GYR values
|
||||
- Added inertial pointing mode
|
||||
- Added nadir pointing mode
|
||||
- Added ground station target mode
|
||||
- Added antistiction for RWs
|
||||
- Added `sunTargetSafe` differentiation for LEOP
|
||||
- Added check for existance of `SD_0_SKEWED_PTG_FILE` and `SD_1_SKEWED_PTG_FILE` to determine
|
||||
which `sunTargetSafe` to use
|
||||
- Added `gpsVelocity` and `gpsPosition` to `gpsProcessed`
|
||||
- Removed deprecated `OutputValues`
|
||||
- Added `HasParametersIF` to `AcsParameters`
|
||||
- Added `ReceivesParameterMessagesIF` and `ParameterHelper` to `AcsController`
|
||||
- Updated `AcsParameters` with actual values and changed structure
|
||||
- Sun vector model and magnetic field vector model calculations are always executed now
|
||||
- `domainId` is now used as identifier for parameter structs
|
||||
- Changed onboard GYR value handling from deg/s to rad/s
|
||||
|
||||
## Fixed
|
||||
|
||||
- Single sourcing the version information into `CMakeLists.txt`. The `git describe` functionality
|
||||
is only used to retrieve the git SHA hash now. Also removed `OBSWVersion.h` accordingly.
|
||||
- Build system: Fixed small bug, where the version itself was
|
||||
stored as the git SHA hash in `commonConfig.h`. This will be
|
||||
an empty string now for regular versions.
|
||||
- Bump FSFW for important fix in PUS mode service.
|
||||
|
||||
### ACS
|
||||
|
||||
- Bugfixes in 'SensorProcessing' where previously MGM values would be calibrated before being
|
||||
transformed in body RF. However, the calibration values are in the body RF. Also fixed the
|
||||
validity flag of 'mgmVecTotDerivative'.
|
||||
- Fixed calculation of model sun vector
|
||||
- Fixed calculation of model magnetic field vector
|
||||
- Fixed MEKF algorithm
|
||||
- Fixed several variable initializations
|
||||
- Fixed several variable types
|
||||
- Fixed use of `sunMagAngleMin` for safe mode
|
||||
- Fixed MEKF not using correct `sampleTime`
|
||||
- Fixed assignment of `SUS0` and `SUS6` calibration matrices due to wiring being mixed up
|
||||
- Various smaller bugfixes
|
||||
|
||||
# [v1.25.0] 2023-02-06
|
||||
|
||||
eive-tmtc version: v2.12.0
|
||||
|
||||
## Changed
|
||||
|
||||
- Updated Subsystem mode IDs to avoid clashes with regular device handler modes.
|
||||
|
||||
## Fixed
|
||||
|
||||
- `GpsHyperionLinuxController`: Fix `gpsd` polling by continuously calling `gps_read` in one cycle
|
||||
until it does not have any data left anymore. Also, the data is now polled in a permanent loop,
|
||||
where controller handling is done on 0.2 second timeouts.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/368
|
||||
|
||||
# [v1.24.0] 2023-02-03
|
||||
|
||||
- eive-tmtc v2.10.0
|
||||
@ -37,6 +736,10 @@ change warranting a new major release:
|
||||
|
||||
## Changed
|
||||
|
||||
- Update ACS scheduling to represent the actual ACS design. There is one ACS PST now for all
|
||||
timing sensitive ACS operations. In the debug builds, the new ACS polling sequence table
|
||||
will have a period of 0.6 seconds, but will remain 0.4 seconds for the release build.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/365
|
||||
- `ACS::SensorValues` is now an ACS controller member to reduce the risk of stack overflow.
|
||||
- ACS Subsystem Sequence Mode IDs updated.
|
||||
PR: https://egit.irs.uni-stuttgart.de/eive/eive-obsw/pulls/365
|
||||
|
@ -9,9 +9,9 @@
|
||||
# ##############################################################################
|
||||
cmake_minimum_required(VERSION 3.13)
|
||||
|
||||
set(OBSW_VERSION_MAJOR_IF_GIT_FAILS 1)
|
||||
set(OBSW_VERSION_MINOR_IF_GIT_FAILS 24)
|
||||
set(OBSW_VERSION_REVISION_IF_GIT_FAILS 0)
|
||||
set(OBSW_VERSION_MAJOR 1)
|
||||
set(OBSW_VERSION_MINOR 39)
|
||||
set(OBSW_VERSION_REVISION 1)
|
||||
|
||||
# set(CMAKE_VERBOSE TRUE)
|
||||
|
||||
@ -71,11 +71,13 @@ if(EIVE_Q7S_EM)
|
||||
1
|
||||
CACHE STRING "Q7S EM configuration")
|
||||
set(INIT_VAL 0)
|
||||
set(OBSW_STAR_TRACKER_GROUND_CONFIG 1)
|
||||
else()
|
||||
set(OBSW_Q7S_EM
|
||||
0
|
||||
CACHE STRING "Q7S EM configuration")
|
||||
set(INIT_VAL 1)
|
||||
set(OBSW_STAR_TRACKER_GROUND_CONFIG 0)
|
||||
endif()
|
||||
set(OBSW_ADD_MGT
|
||||
${INIT_VAL}
|
||||
@ -108,7 +110,7 @@ set(OBSW_TC_FROM_PDEC
|
||||
1
|
||||
CACHE STRING "Poll telecommand from PDEC IP core")
|
||||
set(OBSW_ADD_TCS_CTRL
|
||||
${INIT_VAL}
|
||||
1
|
||||
CACHE STRING "Add TCS controllers")
|
||||
set(OBSW_ADD_HEATERS
|
||||
${INIT_VAL}
|
||||
@ -168,29 +170,18 @@ if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/.git)
|
||||
set(GIT_INFO
|
||||
${GIT_INFO}
|
||||
CACHE STRING "Version information retrieved with git describe")
|
||||
list(GET GIT_INFO 1 OBSW_VERSION_MAJOR)
|
||||
list(GET GIT_INFO 2 OBSW_VERSION_MINOR)
|
||||
list(GET GIT_INFO 3 OBSW_VERSION_REVISION)
|
||||
list(GET GIT_INFO 4 OBSW_VERSION_CST_GIT_SHA1)
|
||||
if(NOT OBSW_VERSION_MAJOR)
|
||||
set(OBSW_VERSION_MAJOR ${OBSW_VERSION_MAJOR_IF_GIT_FAILS})
|
||||
endif()
|
||||
if(NOT OBSW_VERSION_MINOR)
|
||||
set(FSFW_SUBVERSION ${OBSW_VERSION_MINOR_IF_GIT_FAILS})
|
||||
endif()
|
||||
if(NOT OBSW_VERSION_REVISION)
|
||||
set(FSFW_REVISION ${OBSW_VERSION_REVISION_IF_GIT_FAILS})
|
||||
# CMakeLists.txt is now single source of information. list(GET GIT_INFO 1
|
||||
# OBSW_VERSION_MAJOR) list(GET GIT_INFO 2 OBSW_VERSION_MINOR) list(GET
|
||||
# GIT_INFO 3 OBSW_VERSION_REVISION)
|
||||
list(LENGTH GIT_INFO LIST_LEN)
|
||||
if(LIST_LEN GREATER 4)
|
||||
list(GET GIT_INFO 4 OBSW_VERSION_CST_GIT_SHA1)
|
||||
endif()
|
||||
set(GIT_VER_HANDLING_OK TRUE)
|
||||
else()
|
||||
set(GIT_VER_HANDLING_OK FALSE)
|
||||
endif()
|
||||
endif()
|
||||
if(NOT GIT_VER_HANDLING_OK)
|
||||
set(OBSW_VERSION_MAJOR ${OBSW_VERSION_MAJOR_IF_GIT_FAILS})
|
||||
set(OBSW_VERSION_MINOR ${OBSW_VERSION_MINOR_IF_GIT_FAILS})
|
||||
set(OBSW_VERSION_REVISION ${OBSW_VERSION_REVISION_IF_GIT_FAILS})
|
||||
endif()
|
||||
|
||||
# Set names and variables
|
||||
set(OBSW_NAME ${CMAKE_PROJECT_NAME})
|
||||
@ -234,6 +225,7 @@ set(LIB_JSON_PATH ${THIRD_PARTY_FOLDER}/json)
|
||||
|
||||
set(FSFW_WARNING_SHADOW_LOCAL_GCC OFF)
|
||||
set(EIVE_ADD_LINUX_FILES OFF)
|
||||
set(FSFW_ADD_TMSTORAGE ON)
|
||||
|
||||
# Analyse different OS and architecture/target options, determine BSP_PATH,
|
||||
# display information about compiler etc.
|
||||
@ -301,6 +293,16 @@ else()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
include(BuildType)
|
||||
set_build_type()
|
||||
|
||||
set(FSFW_DEBUG_INFO 0)
|
||||
set(Q7S_CHECK_FOR_ALREADY_RUNNING_IMG 0)
|
||||
if(RELEASE_BUILD MATCHES 0)
|
||||
set(FSFW_DEBUG_INFO 1)
|
||||
set(Q7S_CHECK_FOR_ALREADY_RUNNING_IMG 1)
|
||||
endif()
|
||||
|
||||
# Configuration files
|
||||
configure_file(${COMMON_CONFIG_PATH}/commonConfig.h.in commonConfig.h)
|
||||
configure_file(${FSFW_CONFIG_PATH}/FSFWConfig.h.in FSFWConfig.h)
|
||||
@ -347,6 +349,7 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
|
||||
"-Wimplicit-fallthrough=1"
|
||||
"-Wno-unused-parameter"
|
||||
"-Wno-psabi"
|
||||
"-Wshadow=local"
|
||||
"-Wduplicated-cond" # check for duplicate conditions
|
||||
"-Wduplicated-branches" # check for duplicate branches
|
||||
"-Wlogical-op" # Search for bitwise operations instead of logical
|
||||
@ -413,7 +416,6 @@ add_subdirectory(${BSP_PATH})
|
||||
add_subdirectory(${COMMON_PATH})
|
||||
add_subdirectory(${DUMMY_PATH})
|
||||
|
||||
add_subdirectory(${LIB_LWGPS_PATH})
|
||||
add_subdirectory(${FSFW_PATH})
|
||||
add_subdirectory(${LIB_EIVE_MISSION_PATH})
|
||||
add_subdirectory(${TEST_PATH})
|
||||
@ -480,8 +482,8 @@ endif()
|
||||
# ##############################################################################
|
||||
|
||||
# Add libraries
|
||||
target_link_libraries(${LIB_EIVE_MISSION}
|
||||
PUBLIC ${LIB_FSFW_NAME} ${LIB_LWGPS_NAME} ${LIB_OS_NAME})
|
||||
target_link_libraries(${LIB_EIVE_MISSION} PUBLIC ${LIB_FSFW_NAME}
|
||||
${LIB_OS_NAME})
|
||||
|
||||
target_link_libraries(${LIB_DUMMIES} PUBLIC ${LIB_FSFW_NAME} ${LIB_JSON_NAME})
|
||||
|
||||
@ -559,6 +561,3 @@ add_custom_command(
|
||||
POST_BUILD
|
||||
COMMAND ${CMAKE_SIZE} ${OBSW_BIN_NAME}${FILE_SUFFIX}
|
||||
COMMENT ${POST_BUILD_COMMENT})
|
||||
|
||||
include(BuildType)
|
||||
set_build_type()
|
||||
|
17
README.md
17
README.md
@ -18,6 +18,7 @@
|
||||
11. [Q7S OBC](#q7s)
|
||||
12. [Static Code Analysis](#static-code-analysis)
|
||||
13. [Eclipse](#eclipse)
|
||||
14. [CLion](#clion)
|
||||
14. [Running the OBSW on a Raspberry Pi](#rpi)
|
||||
15. [Running OBSW on EGSE](#egse)
|
||||
16. [Manually preparing sysroots to compile gpsd](#gpsd)
|
||||
@ -1229,6 +1230,22 @@ Finally, you can convert the generated `.xml` file to HTML with the following co
|
||||
cppcheck-htmlreport --file=report.xml --report-dir=cppcheck --source-dir=..
|
||||
```
|
||||
|
||||
# <a id="CLion"></a> CLion
|
||||
|
||||
CLion is the recommended IDE for the development of the hosted version of EIVE.
|
||||
You can also set up CLion for cross-compilation of the primary OBSW.
|
||||
|
||||
There is a shared `.idea/cmake.xml` file to get started with this.
|
||||
To make cross-compilation work, two special environment variables
|
||||
need to be set:
|
||||
|
||||
- `ZYNQ_7020_ROOTFS` pointing to the root filesystem
|
||||
- `CROSS_COMPILE` pointing to the the full path of the cross-compiler
|
||||
without the specific tool suffix. For example, if the the cross-compiler
|
||||
tools are located at `/opt/q7s-gcc/gcc-arm-8.3-2019.03-x86_64-arm-linux-gnueabihf/bin`,
|
||||
this variable would be set
|
||||
to `/opt/q7s-gcc/gcc-arm-8.3-2019.03-x86_64-arm-linux-gnueabihf/bin/arm-linux-gnueabihf`
|
||||
|
||||
# <a id="eclipse"></a> Eclipse
|
||||
|
||||
When using Eclipse, there are two special build variables in the project properties
|
||||
|
20
automation/Jenkinsfile
vendored
20
automation/Jenkinsfile
vendored
@ -1,6 +1,7 @@
|
||||
pipeline {
|
||||
environment {
|
||||
BUILDDIR_Q7 = 'build_q7'
|
||||
BUILDDIR_Q7S = 'build_q7s_fm'
|
||||
BUILDDIR_Q7S_EM = 'build_q7s_em'
|
||||
BUILDDIR_LINUX = 'build_linux'
|
||||
}
|
||||
agent {
|
||||
@ -12,15 +13,24 @@ pipeline {
|
||||
stages {
|
||||
stage('Clean') {
|
||||
steps {
|
||||
sh 'rm -rf $BUILDDIR_Q7'
|
||||
sh 'rm -rf $BUILDDIR_Q7S'
|
||||
sh 'rm -rf $BUILDDIR_Q7S_EM'
|
||||
sh 'rm -rf $BUILDDIR_LINUX'
|
||||
}
|
||||
}
|
||||
stage('Build Q7S') {
|
||||
steps {
|
||||
dir(BUILDDIR_Q7) {
|
||||
dir(BUILDDIR_Q7S) {
|
||||
sh 'cmake -DTGT_BSP="arm/q7s" -DCMAKE_BUILD_TYPE=Debug ..'
|
||||
sh 'cmake --build . -j4'
|
||||
sh 'cmake --build . -j6'
|
||||
}
|
||||
}
|
||||
}
|
||||
stage('Build Q7S EM') {
|
||||
steps {
|
||||
dir(BUILDDIR_Q7S_EM) {
|
||||
sh 'cmake -DTGT_BSP="arm/q7s" -DEIVE_Q7S_EM=ON -DCMAKE_BUILD_TYPE=Debug ..'
|
||||
sh 'cmake --build . -j6'
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -28,7 +38,7 @@ pipeline {
|
||||
steps {
|
||||
dir(BUILDDIR_LINUX) {
|
||||
sh 'cmake ..'
|
||||
sh 'cmake --build . -j4'
|
||||
sh 'cmake --build . -j6'
|
||||
sh './eive-unittest'
|
||||
}
|
||||
}
|
||||
|
@ -7,7 +7,6 @@
|
||||
#define FSFWCONFIG_OBSWCONFIG_H_
|
||||
|
||||
#include "commonConfig.h"
|
||||
#include "OBSWVersion.h"
|
||||
|
||||
/*******************************************************************/
|
||||
/** All of the following flags should be enabled for mission code */
|
||||
|
@ -8,12 +8,10 @@
|
||||
#include <mission/tmtc/TmFunnelHandler.h>
|
||||
#include <objects/systemObjectList.h>
|
||||
|
||||
#include "../mission/utility/DummySdCardManager.h"
|
||||
#include "OBSWConfig.h"
|
||||
#include "devConf.h"
|
||||
#include "eive/definitions.h"
|
||||
#include "fsfw/platform.h"
|
||||
#include "fsfw_tests/integration/task/TestTask.h"
|
||||
#include "tmtc/pusIds.h"
|
||||
|
||||
#if OBSW_ADD_TMTC_UDP_SERVER == 1
|
||||
#include "fsfw/osal/common/UdpTcPollingTask.h"
|
||||
@ -24,32 +22,14 @@
|
||||
#include "fsfw/osal/common/TcpTmTcServer.h"
|
||||
#endif
|
||||
|
||||
#include <fsfw/tmtcpacket/pus/tm.h>
|
||||
|
||||
#if OBSW_ADD_TEST_CODE == 1
|
||||
#include <test/testtasks/TestTask.h>
|
||||
#endif
|
||||
|
||||
#include <dummies/AcuDummy.h>
|
||||
#include <dummies/BpxDummy.h>
|
||||
#include <dummies/ComCookieDummy.h>
|
||||
#include <dummies/ComIFDummy.h>
|
||||
#include <dummies/CoreControllerDummy.h>
|
||||
#include <dummies/GyroAdisDummy.h>
|
||||
#include <dummies/GyroL3GD20Dummy.h>
|
||||
#include <dummies/ImtqDummy.h>
|
||||
#include <dummies/MgmLIS3MDLDummy.h>
|
||||
#include <dummies/P60DockDummy.h>
|
||||
#include <dummies/PduDummy.h>
|
||||
#include <dummies/PlPcduDummy.h>
|
||||
#include <dummies/RwDummy.h>
|
||||
#include <dummies/StarTrackerDummy.h>
|
||||
#include <dummies/SusDummy.h>
|
||||
#include <dummies/SyrlinksDummy.h>
|
||||
#include <dummies/TemperatureSensorsDummy.h>
|
||||
|
||||
#include "dummies/helpers.h"
|
||||
#include "mission/utility/GlobalConfigHandler.h"
|
||||
|
||||
#ifdef PLATFORM_UNIX
|
||||
#include <fsfw_hal/linux/serial/SerialComIF.h>
|
||||
@ -78,11 +58,15 @@ void ObjectFactory::produce(void* args) {
|
||||
Factory::setStaticFrameworkObjectIds();
|
||||
PusTmFunnel* pusFunnel;
|
||||
CfdpTmFunnel* cfdpFunnel;
|
||||
ObjectFactory::produceGenericObjects(nullptr, &pusFunnel, &cfdpFunnel);
|
||||
StorageManagerIF* tmStore;
|
||||
StorageManagerIF* ipcStore;
|
||||
PersistentTmStores persistentStores;
|
||||
auto sdcMan = new DummySdCardManager("/tmp");
|
||||
ObjectFactory::produceGenericObjects(nullptr, &pusFunnel, &cfdpFunnel, *sdcMan, &ipcStore,
|
||||
&tmStore, persistentStores);
|
||||
|
||||
DummyGpioIF* dummyGpioIF = new DummyGpioIF();
|
||||
auto* dummyGpioIF = new DummyGpioIF();
|
||||
auto* dummySwitcher = new DummyPowerSwitcher(objects::PCDU_HANDLER, 18, 0);
|
||||
static_cast<void>(dummyGpioIF);
|
||||
#ifdef PLATFORM_UNIX
|
||||
new SerialComIF(objects::UART_COM_IF);
|
||||
#if OBSW_ADD_PLOC_MPSOC == 1
|
||||
@ -109,7 +93,15 @@ void ObjectFactory::produce(void* args) {
|
||||
#endif
|
||||
|
||||
dummy::DummyCfg cfg;
|
||||
dummy::createDummies(cfg, *dummySwitcher);
|
||||
new ThermalController(objects::THERMAL_CONTROLLER);
|
||||
dummy::createDummies(cfg, *dummySwitcher, dummyGpioIF);
|
||||
|
||||
HeaterHandler* heaterHandler = nullptr;
|
||||
// new ThermalController(objects::THERMAL_CONTROLLER);
|
||||
ObjectFactory::createGenericHeaterComponents(*dummyGpioIF, *dummySwitcher, heaterHandler);
|
||||
if (heaterHandler == nullptr) {
|
||||
sif::error << "HeaterHandler could not be created" << std::endl;
|
||||
} else {
|
||||
ObjectFactory::createThermalController(*heaterHandler);
|
||||
}
|
||||
new TestTask(objects::TEST_TASK);
|
||||
}
|
||||
|
@ -50,6 +50,8 @@
|
||||
//! If set to 1 the binary needs "cap_sys_nice=eip" privileges to run
|
||||
#define FSFW_USE_REALTIME_FOR_LINUX 0
|
||||
|
||||
#define FSFW_UDP_SEND_WIRETAPPING_ENABLED 0
|
||||
|
||||
namespace fsfwconfig {
|
||||
|
||||
//! Default timestamp size. The default timestamp will be an seven byte CDC short timestamp.
|
||||
|
@ -1,7 +1,7 @@
|
||||
/**
|
||||
* @brief Auto-generated event translation file. Contains 239 translations.
|
||||
* @brief Auto-generated event translation file. Contains 279 translations.
|
||||
* @details
|
||||
* Generated on: 2022-11-16 15:25:08
|
||||
* Generated on: 2023-03-21 23:59:36
|
||||
*/
|
||||
#include "translateEvents.h"
|
||||
|
||||
@ -35,11 +35,11 @@ const char *INVALID_DEVICE_COMMAND_STRING = "INVALID_DEVICE_COMMAND";
|
||||
const char *MONITORING_LIMIT_EXCEEDED_STRING = "MONITORING_LIMIT_EXCEEDED";
|
||||
const char *MONITORING_AMBIGUOUS_STRING = "MONITORING_AMBIGUOUS";
|
||||
const char *DEVICE_WANTS_HARD_REBOOT_STRING = "DEVICE_WANTS_HARD_REBOOT";
|
||||
const char *SWITCH_WENT_OFF_STRING = "SWITCH_WENT_OFF";
|
||||
const char *FUSE_CURRENT_HIGH_STRING = "FUSE_CURRENT_HIGH";
|
||||
const char *FUSE_WENT_OFF_STRING = "FUSE_WENT_OFF";
|
||||
const char *POWER_ABOVE_HIGH_LIMIT_STRING = "POWER_ABOVE_HIGH_LIMIT";
|
||||
const char *POWER_BELOW_LOW_LIMIT_STRING = "POWER_BELOW_LOW_LIMIT";
|
||||
const char *SWITCH_WENT_OFF_STRING = "SWITCH_WENT_OFF";
|
||||
const char *HEATER_ON_STRING = "HEATER_ON";
|
||||
const char *HEATER_OFF_STRING = "HEATER_OFF";
|
||||
const char *HEATER_TIMEOUT_STRING = "HEATER_TIMEOUT";
|
||||
@ -82,6 +82,7 @@ const char *BIT_LOCK_STRING = "BIT_LOCK";
|
||||
const char *BIT_LOCK_LOST_STRING = "BIT_LOCK_LOST";
|
||||
const char *FRAME_PROCESSING_FAILED_STRING = "FRAME_PROCESSING_FAILED";
|
||||
const char *CLOCK_SET_STRING = "CLOCK_SET";
|
||||
const char *CLOCK_DUMP_STRING = "CLOCK_DUMP";
|
||||
const char *CLOCK_SET_FAILURE_STRING = "CLOCK_SET_FAILURE";
|
||||
const char *TC_DELETION_FAILED_STRING = "TC_DELETION_FAILED";
|
||||
const char *TEST_STRING = "TEST";
|
||||
@ -89,6 +90,14 @@ const char *CHANGE_OF_SETUP_PARAMETER_STRING = "CHANGE_OF_SETUP_PARAMETER";
|
||||
const char *STORE_ERROR_STRING = "STORE_ERROR";
|
||||
const char *MSG_QUEUE_ERROR_STRING = "MSG_QUEUE_ERROR";
|
||||
const char *SERIALIZATION_ERROR_STRING = "SERIALIZATION_ERROR";
|
||||
const char *FILESTORE_ERROR_STRING = "FILESTORE_ERROR";
|
||||
const char *FILENAME_TOO_LARGE_ERROR_STRING = "FILENAME_TOO_LARGE_ERROR";
|
||||
const char *SAFE_RATE_VIOLATION_STRING = "SAFE_RATE_VIOLATION";
|
||||
const char *SAFE_RATE_RECOVERY_STRING = "SAFE_RATE_RECOVERY";
|
||||
const char *MULTIPLE_RW_INVALID_STRING = "MULTIPLE_RW_INVALID";
|
||||
const char *MEKF_INVALID_INFO_STRING = "MEKF_INVALID_INFO";
|
||||
const char *MEKF_INVALID_MODE_VIOLATION_STRING = "MEKF_INVALID_MODE_VIOLATION";
|
||||
const char *SAFE_MODE_CONTROLLER_FAILURE_STRING = "SAFE_MODE_CONTROLLER_FAILURE";
|
||||
const char *SWITCH_CMD_SENT_STRING = "SWITCH_CMD_SENT";
|
||||
const char *SWITCH_HAS_CHANGED_STRING = "SWITCH_HAS_CHANGED";
|
||||
const char *SWITCHING_Q7S_DENIED_STRING = "SWITCHING_Q7S_DENIED";
|
||||
@ -126,8 +135,8 @@ const char *SELF_TEST_COIL_CURRENT_FAILURE_STRING = "SELF_TEST_COIL_CURRENT_FAIL
|
||||
const char *INVALID_ERROR_BYTE_STRING = "INVALID_ERROR_BYTE";
|
||||
const char *ERROR_STATE_STRING = "ERROR_STATE";
|
||||
const char *RESET_OCCURED_STRING = "RESET_OCCURED";
|
||||
const char *BOOTING_FIRMWARE_FAILED_STRING = "BOOTING_FIRMWARE_FAILED";
|
||||
const char *BOOTING_BOOTLOADER_FAILED_STRING = "BOOTING_BOOTLOADER_FAILED";
|
||||
const char *BOOTING_FIRMWARE_FAILED_EVENT_STRING = "BOOTING_FIRMWARE_FAILED_EVENT";
|
||||
const char *BOOTING_BOOTLOADER_FAILED_EVENT_STRING = "BOOTING_BOOTLOADER_FAILED_EVENT";
|
||||
const char *SUPV_MEMORY_READ_RPT_CRC_FAILURE_STRING = "SUPV_MEMORY_READ_RPT_CRC_FAILURE";
|
||||
const char *SUPV_UNKNOWN_TM_STRING = "SUPV_UNKNOWN_TM";
|
||||
const char *SUPV_UNINIMPLEMENTED_TM_STRING = "SUPV_UNINIMPLEMENTED_TM";
|
||||
@ -135,7 +144,7 @@ const char *SUPV_ACK_FAILURE_STRING = "SUPV_ACK_FAILURE";
|
||||
const char *SUPV_EXE_FAILURE_STRING = "SUPV_EXE_FAILURE";
|
||||
const char *SUPV_CRC_FAILURE_EVENT_STRING = "SUPV_CRC_FAILURE_EVENT";
|
||||
const char *SUPV_HELPER_EXECUTING_STRING = "SUPV_HELPER_EXECUTING";
|
||||
const char *SUPV_MPSOC_SHUWDOWN_BUILD_FAILED_STRING = "SUPV_MPSOC_SHUWDOWN_BUILD_FAILED";
|
||||
const char *SUPV_MPSOC_SHUTDOWN_BUILD_FAILED_STRING = "SUPV_MPSOC_SHUTDOWN_BUILD_FAILED";
|
||||
const char *SANITIZATION_FAILED_STRING = "SANITIZATION_FAILED";
|
||||
const char *MOUNTED_SD_CARD_STRING = "MOUNTED_SD_CARD";
|
||||
const char *SEND_MRAM_DUMP_FAILED_STRING = "SEND_MRAM_DUMP_FAILED";
|
||||
@ -147,7 +156,11 @@ const char *CARRIER_LOCK_STRING = "CARRIER_LOCK";
|
||||
const char *BIT_LOCK_PDEC_STRING = "BIT_LOCK_PDEC";
|
||||
const char *LOST_CARRIER_LOCK_PDEC_STRING = "LOST_CARRIER_LOCK_PDEC";
|
||||
const char *LOST_BIT_LOCK_PDEC_STRING = "LOST_BIT_LOCK_PDEC";
|
||||
const char *POLL_ERROR_PDEC_STRING = "POLL_ERROR_PDEC";
|
||||
const char *TOO_MANY_IRQS_STRING = "TOO_MANY_IRQS";
|
||||
const char *POLL_SYSCALL_ERROR_PDEC_STRING = "POLL_SYSCALL_ERROR_PDEC";
|
||||
const char *WRITE_SYSCALL_ERROR_PDEC_STRING = "WRITE_SYSCALL_ERROR_PDEC";
|
||||
const char *PDEC_RESET_FAILED_STRING = "PDEC_RESET_FAILED";
|
||||
const char *OPEN_IRQ_FILE_FAILED_STRING = "OPEN_IRQ_FILE_FAILED";
|
||||
const char *IMAGE_UPLOAD_FAILED_STRING = "IMAGE_UPLOAD_FAILED";
|
||||
const char *IMAGE_DOWNLOAD_FAILED_STRING = "IMAGE_DOWNLOAD_FAILED";
|
||||
const char *IMAGE_UPLOAD_SUCCESSFUL_STRING = "IMAGE_UPLOAD_SUCCESSFUL";
|
||||
@ -197,6 +210,7 @@ const char *POWER_STATE_MACHINE_TIMEOUT_STRING = "POWER_STATE_MACHINE_TIMEOUT";
|
||||
const char *SIDE_SWITCH_TRANSITION_NOT_ALLOWED_STRING = "SIDE_SWITCH_TRANSITION_NOT_ALLOWED";
|
||||
const char *CHILDREN_LOST_MODE_STRING = "CHILDREN_LOST_MODE";
|
||||
const char *GPS_FIX_CHANGE_STRING = "GPS_FIX_CHANGE";
|
||||
const char *CANT_GET_FIX_STRING = "CANT_GET_FIX";
|
||||
const char *P60_BOOT_COUNT_STRING = "P60_BOOT_COUNT";
|
||||
const char *BATT_MODE_STRING = "BATT_MODE";
|
||||
const char *BATT_MODE_CHANGED_STRING = "BATT_MODE_CHANGED";
|
||||
@ -227,11 +241,8 @@ const char *SUPV_REPLY_CRC_MISSMATCH_STRING = "SUPV_REPLY_CRC_MISSMATCH";
|
||||
const char *SUPV_UPDATE_PROGRESS_STRING = "SUPV_UPDATE_PROGRESS";
|
||||
const char *HDLC_FRAME_REMOVAL_ERROR_STRING = "HDLC_FRAME_REMOVAL_ERROR";
|
||||
const char *HDLC_CRC_ERROR_STRING = "HDLC_CRC_ERROR";
|
||||
const char *ALLOC_FAILURE_STRING = "ALLOC_FAILURE";
|
||||
const char *REBOOT_SW_STRING = "REBOOT_SW";
|
||||
const char *REBOOT_MECHANISM_TRIGGERED_STRING = "REBOOT_MECHANISM_TRIGGERED";
|
||||
const char *REBOOT_HW_STRING = "REBOOT_HW";
|
||||
const char *NO_SD_CARD_ACTIVE_STRING = "NO_SD_CARD_ACTIVE";
|
||||
const char *TX_ON_STRING = "TX_ON";
|
||||
const char *TX_OFF_STRING = "TX_OFF";
|
||||
const char *MISSING_PACKET_STRING = "MISSING_PACKET";
|
||||
const char *EXPERIMENT_TIMEDOUT_STRING = "EXPERIMENT_TIMEDOUT";
|
||||
const char *MULTI_PACKET_COMMAND_DONE_STRING = "MULTI_PACKET_COMMAND_DONE";
|
||||
@ -240,6 +251,34 @@ const char *GET_CONFIGFILEVALUE_FAILED_STRING = "GET_CONFIGFILEVALUE_FAILED";
|
||||
const char *INSERT_CONFIGFILEVALUE_FAILED_STRING = "INSERT_CONFIGFILEVALUE_FAILED";
|
||||
const char *WRITE_CONFIGFILE_FAILED_STRING = "WRITE_CONFIGFILE_FAILED";
|
||||
const char *READ_CONFIGFILE_FAILED_STRING = "READ_CONFIGFILE_FAILED";
|
||||
const char *ALLOC_FAILURE_STRING = "ALLOC_FAILURE";
|
||||
const char *REBOOT_SW_STRING = "REBOOT_SW";
|
||||
const char *REBOOT_MECHANISM_TRIGGERED_STRING = "REBOOT_MECHANISM_TRIGGERED";
|
||||
const char *REBOOT_HW_STRING = "REBOOT_HW";
|
||||
const char *NO_SD_CARD_ACTIVE_STRING = "NO_SD_CARD_ACTIVE";
|
||||
const char *VERSION_INFO_STRING = "VERSION_INFO";
|
||||
const char *CURRENT_IMAGE_INFO_STRING = "CURRENT_IMAGE_INFO";
|
||||
const char *REBOOT_COUNTER_STRING = "REBOOT_COUNTER";
|
||||
const char *INDIVIDUAL_BOOT_COUNTS_STRING = "INDIVIDUAL_BOOT_COUNTS";
|
||||
const char *I2C_UNAVAILABLE_REBOOT_STRING = "I2C_UNAVAILABLE_REBOOT";
|
||||
const char *NO_VALID_SENSOR_TEMPERATURE_STRING = "NO_VALID_SENSOR_TEMPERATURE";
|
||||
const char *NO_HEALTHY_HEATER_AVAILABLE_STRING = "NO_HEALTHY_HEATER_AVAILABLE";
|
||||
const char *SYRLINKS_OVERHEATING_STRING = "SYRLINKS_OVERHEATING";
|
||||
const char *PLOC_OVERHEATING_STRING = "PLOC_OVERHEATING";
|
||||
const char *OBC_OVERHEATING_STRING = "OBC_OVERHEATING";
|
||||
const char *HPA_OVERHEATING_STRING = "HPA_OVERHEATING";
|
||||
const char *PLPCDU_OVERHEATING_STRING = "PLPCDU_OVERHEATING";
|
||||
const char *TX_TIMER_EXPIRED_STRING = "TX_TIMER_EXPIRED";
|
||||
const char *BIT_LOCK_TX_ON_STRING = "BIT_LOCK_TX_ON";
|
||||
const char *POSSIBLE_FILE_CORRUPTION_STRING = "POSSIBLE_FILE_CORRUPTION";
|
||||
const char *FILE_TOO_LARGE_STRING = "FILE_TOO_LARGE";
|
||||
const char *BUSY_DUMPING_EVENT_STRING = "BUSY_DUMPING_EVENT";
|
||||
const char *DUMP_WAS_CANCELLED_STRING = "DUMP_WAS_CANCELLED";
|
||||
const char *DUMP_OK_STORE_DONE_STRING = "DUMP_OK_STORE_DONE";
|
||||
const char *DUMP_NOK_STORE_DONE_STRING = "DUMP_NOK_STORE_DONE";
|
||||
const char *DUMP_MISC_STORE_DONE_STRING = "DUMP_MISC_STORE_DONE";
|
||||
const char *DUMP_HK_STORE_DONE_STRING = "DUMP_HK_STORE_DONE";
|
||||
const char *DUMP_CFDP_STORE_DONE_STRING = "DUMP_CFDP_STORE_DONE";
|
||||
|
||||
const char *translateEvents(Event event) {
|
||||
switch ((event & 0xFFFF)) {
|
||||
@ -303,16 +342,16 @@ const char *translateEvents(Event event) {
|
||||
return MONITORING_AMBIGUOUS_STRING;
|
||||
case (2811):
|
||||
return DEVICE_WANTS_HARD_REBOOT_STRING;
|
||||
case (4201):
|
||||
return FUSE_CURRENT_HIGH_STRING;
|
||||
case (4202):
|
||||
return FUSE_WENT_OFF_STRING;
|
||||
case (4204):
|
||||
return POWER_ABOVE_HIGH_LIMIT_STRING;
|
||||
case (4205):
|
||||
return POWER_BELOW_LOW_LIMIT_STRING;
|
||||
case (4300):
|
||||
return SWITCH_WENT_OFF_STRING;
|
||||
case (4301):
|
||||
return FUSE_CURRENT_HIGH_STRING;
|
||||
case (4302):
|
||||
return FUSE_WENT_OFF_STRING;
|
||||
case (4304):
|
||||
return POWER_ABOVE_HIGH_LIMIT_STRING;
|
||||
case (4305):
|
||||
return POWER_BELOW_LOW_LIMIT_STRING;
|
||||
case (5000):
|
||||
return HEATER_ON_STRING;
|
||||
case (5001):
|
||||
@ -398,6 +437,8 @@ const char *translateEvents(Event event) {
|
||||
case (8900):
|
||||
return CLOCK_SET_STRING;
|
||||
case (8901):
|
||||
return CLOCK_DUMP_STRING;
|
||||
case (8902):
|
||||
return CLOCK_SET_FAILURE_STRING;
|
||||
case (9100):
|
||||
return TC_DELETION_FAILED_STRING;
|
||||
@ -411,6 +452,22 @@ const char *translateEvents(Event event) {
|
||||
return MSG_QUEUE_ERROR_STRING;
|
||||
case (10802):
|
||||
return SERIALIZATION_ERROR_STRING;
|
||||
case (10803):
|
||||
return FILESTORE_ERROR_STRING;
|
||||
case (10804):
|
||||
return FILENAME_TOO_LARGE_ERROR_STRING;
|
||||
case (11200):
|
||||
return SAFE_RATE_VIOLATION_STRING;
|
||||
case (11201):
|
||||
return SAFE_RATE_RECOVERY_STRING;
|
||||
case (11202):
|
||||
return MULTIPLE_RW_INVALID_STRING;
|
||||
case (11203):
|
||||
return MEKF_INVALID_INFO_STRING;
|
||||
case (11204):
|
||||
return MEKF_INVALID_MODE_VIOLATION_STRING;
|
||||
case (11205):
|
||||
return SAFE_MODE_CONTROLLER_FAILURE_STRING;
|
||||
case (11300):
|
||||
return SWITCH_CMD_SENT_STRING;
|
||||
case (11301):
|
||||
@ -486,9 +543,9 @@ const char *translateEvents(Event event) {
|
||||
case (11802):
|
||||
return RESET_OCCURED_STRING;
|
||||
case (11901):
|
||||
return BOOTING_FIRMWARE_FAILED_STRING;
|
||||
return BOOTING_FIRMWARE_FAILED_EVENT_STRING;
|
||||
case (11902):
|
||||
return BOOTING_BOOTLOADER_FAILED_STRING;
|
||||
return BOOTING_BOOTLOADER_FAILED_EVENT_STRING;
|
||||
case (12001):
|
||||
return SUPV_MEMORY_READ_RPT_CRC_FAILURE_STRING;
|
||||
case (12002):
|
||||
@ -504,7 +561,7 @@ const char *translateEvents(Event event) {
|
||||
case (12007):
|
||||
return SUPV_HELPER_EXECUTING_STRING;
|
||||
case (12008):
|
||||
return SUPV_MPSOC_SHUWDOWN_BUILD_FAILED_STRING;
|
||||
return SUPV_MPSOC_SHUTDOWN_BUILD_FAILED_STRING;
|
||||
case (12100):
|
||||
return SANITIZATION_FAILED_STRING;
|
||||
case (12101):
|
||||
@ -528,7 +585,15 @@ const char *translateEvents(Event event) {
|
||||
case (12406):
|
||||
return LOST_BIT_LOCK_PDEC_STRING;
|
||||
case (12407):
|
||||
return POLL_ERROR_PDEC_STRING;
|
||||
return TOO_MANY_IRQS_STRING;
|
||||
case (12408):
|
||||
return POLL_SYSCALL_ERROR_PDEC_STRING;
|
||||
case (12409):
|
||||
return WRITE_SYSCALL_ERROR_PDEC_STRING;
|
||||
case (12410):
|
||||
return PDEC_RESET_FAILED_STRING;
|
||||
case (12411):
|
||||
return OPEN_IRQ_FILE_FAILED_STRING;
|
||||
case (12500):
|
||||
return IMAGE_UPLOAD_FAILED_STRING;
|
||||
case (12501):
|
||||
@ -627,6 +692,8 @@ const char *translateEvents(Event event) {
|
||||
return CHILDREN_LOST_MODE_STRING;
|
||||
case (13100):
|
||||
return GPS_FIX_CHANGE_STRING;
|
||||
case (13101):
|
||||
return CANT_GET_FIX_STRING;
|
||||
case (13200):
|
||||
return P60_BOOT_COUNT_STRING;
|
||||
case (13201):
|
||||
@ -687,16 +754,10 @@ const char *translateEvents(Event event) {
|
||||
return HDLC_FRAME_REMOVAL_ERROR_STRING;
|
||||
case (13632):
|
||||
return HDLC_CRC_ERROR_STRING;
|
||||
case (13700):
|
||||
return ALLOC_FAILURE_STRING;
|
||||
case (13701):
|
||||
return REBOOT_SW_STRING;
|
||||
return TX_ON_STRING;
|
||||
case (13702):
|
||||
return REBOOT_MECHANISM_TRIGGERED_STRING;
|
||||
case (13703):
|
||||
return REBOOT_HW_STRING;
|
||||
case (13704):
|
||||
return NO_SD_CARD_ACTIVE_STRING;
|
||||
return TX_OFF_STRING;
|
||||
case (13800):
|
||||
return MISSING_PACKET_STRING;
|
||||
case (13801):
|
||||
@ -713,6 +774,62 @@ const char *translateEvents(Event event) {
|
||||
return WRITE_CONFIGFILE_FAILED_STRING;
|
||||
case (13905):
|
||||
return READ_CONFIGFILE_FAILED_STRING;
|
||||
case (14000):
|
||||
return ALLOC_FAILURE_STRING;
|
||||
case (14001):
|
||||
return REBOOT_SW_STRING;
|
||||
case (14002):
|
||||
return REBOOT_MECHANISM_TRIGGERED_STRING;
|
||||
case (14003):
|
||||
return REBOOT_HW_STRING;
|
||||
case (14004):
|
||||
return NO_SD_CARD_ACTIVE_STRING;
|
||||
case (14005):
|
||||
return VERSION_INFO_STRING;
|
||||
case (14006):
|
||||
return CURRENT_IMAGE_INFO_STRING;
|
||||
case (14007):
|
||||
return REBOOT_COUNTER_STRING;
|
||||
case (14008):
|
||||
return INDIVIDUAL_BOOT_COUNTS_STRING;
|
||||
case (14010):
|
||||
return I2C_UNAVAILABLE_REBOOT_STRING;
|
||||
case (14100):
|
||||
return NO_VALID_SENSOR_TEMPERATURE_STRING;
|
||||
case (14101):
|
||||
return NO_HEALTHY_HEATER_AVAILABLE_STRING;
|
||||
case (14102):
|
||||
return SYRLINKS_OVERHEATING_STRING;
|
||||
case (14103):
|
||||
return PLOC_OVERHEATING_STRING;
|
||||
case (14104):
|
||||
return OBC_OVERHEATING_STRING;
|
||||
case (14105):
|
||||
return HPA_OVERHEATING_STRING;
|
||||
case (14106):
|
||||
return PLPCDU_OVERHEATING_STRING;
|
||||
case (14201):
|
||||
return TX_TIMER_EXPIRED_STRING;
|
||||
case (14202):
|
||||
return BIT_LOCK_TX_ON_STRING;
|
||||
case (14300):
|
||||
return POSSIBLE_FILE_CORRUPTION_STRING;
|
||||
case (14301):
|
||||
return FILE_TOO_LARGE_STRING;
|
||||
case (14302):
|
||||
return BUSY_DUMPING_EVENT_STRING;
|
||||
case (14303):
|
||||
return DUMP_WAS_CANCELLED_STRING;
|
||||
case (14305):
|
||||
return DUMP_OK_STORE_DONE_STRING;
|
||||
case (14306):
|
||||
return DUMP_NOK_STORE_DONE_STRING;
|
||||
case (14307):
|
||||
return DUMP_MISC_STORE_DONE_STRING;
|
||||
case (14308):
|
||||
return DUMP_HK_STORE_DONE_STRING;
|
||||
case (14309):
|
||||
return DUMP_CFDP_STORE_DONE_STRING;
|
||||
default:
|
||||
return "UNKNOWN_EVENT";
|
||||
}
|
||||
|
@ -24,7 +24,7 @@ enum sourceObjects : uint32_t {
|
||||
/* 0x49 ('I') for Communication Interfaces **/
|
||||
ARDUINO_COM_IF = 0x49000001,
|
||||
|
||||
DUMMY_COM_IF = 0x49000002
|
||||
DUMMY_COM_IF = 0x49000002,
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -1,16 +1,17 @@
|
||||
/**
|
||||
* @brief Auto-generated object translation file.
|
||||
* @details
|
||||
* Contains 148 translations.
|
||||
* Generated on: 2022-11-15 17:44:20
|
||||
* Contains 169 translations.
|
||||
* Generated on: 2023-03-21 23:59:36
|
||||
*/
|
||||
#include "translateObjects.h"
|
||||
|
||||
const char *P60DOCK_TEST_TASK_STRING = "P60DOCK_TEST_TASK";
|
||||
const char *TEST_TASK_STRING = "TEST_TASK";
|
||||
const char *ACS_CONTROLLER_STRING = "ACS_CONTROLLER";
|
||||
const char *CORE_CONTROLLER_STRING = "CORE_CONTROLLER";
|
||||
const char *GLOBAL_JSON_CFG_STRING = "GLOBAL_JSON_CFG";
|
||||
const char *THERMAL_CONTROLLER_STRING = "THERMAL_CONTROLLER";
|
||||
const char *DUMMY_HANDLER_STRING = "DUMMY_HANDLER";
|
||||
const char *MGM_0_LIS3_HANDLER_STRING = "MGM_0_LIS3_HANDLER";
|
||||
const char *GYRO_0_ADIS_HANDLER_STRING = "GYRO_0_ADIS_HANDLER";
|
||||
const char *SUS_0_N_LOC_XFYFZM_PT_XF_STRING = "SUS_0_N_LOC_XFYFZM_PT_XF";
|
||||
@ -37,6 +38,7 @@ const char *GYRO_3_L3G_HANDLER_STRING = "GYRO_3_L3G_HANDLER";
|
||||
const char *RW4_STRING = "RW4";
|
||||
const char *STAR_TRACKER_STRING = "STAR_TRACKER";
|
||||
const char *GPS_CONTROLLER_STRING = "GPS_CONTROLLER";
|
||||
const char *IMTQ_POLLING_STRING = "IMTQ_POLLING";
|
||||
const char *IMTQ_HANDLER_STRING = "IMTQ_HANDLER";
|
||||
const char *PCDU_HANDLER_STRING = "PCDU_HANDLER";
|
||||
const char *P60DOCK_HANDLER_STRING = "P60DOCK_HANDLER";
|
||||
@ -52,6 +54,10 @@ const char *STR_HELPER_STRING = "STR_HELPER";
|
||||
const char *PLOC_MPSOC_HELPER_STRING = "PLOC_MPSOC_HELPER";
|
||||
const char *AXI_PTME_CONFIG_STRING = "AXI_PTME_CONFIG";
|
||||
const char *PTME_CONFIG_STRING = "PTME_CONFIG";
|
||||
const char *PTME_VC0_LIVE_TM_STRING = "PTME_VC0_LIVE_TM";
|
||||
const char *PTME_VC1_LOG_TM_STRING = "PTME_VC1_LOG_TM";
|
||||
const char *PTME_VC2_HK_TM_STRING = "PTME_VC2_HK_TM";
|
||||
const char *PTME_VC3_CFDP_TM_STRING = "PTME_VC3_CFDP_TM";
|
||||
const char *PLOC_MPSOC_HANDLER_STRING = "PLOC_MPSOC_HANDLER";
|
||||
const char *PLOC_SUPERVISOR_HANDLER_STRING = "PLOC_SUPERVISOR_HANDLER";
|
||||
const char *PLOC_SUPERVISOR_HELPER_STRING = "PLOC_SUPERVISOR_HELPER";
|
||||
@ -63,7 +69,6 @@ const char *TMP1075_HANDLER_TCS_1_STRING = "TMP1075_HANDLER_TCS_1";
|
||||
const char *TMP1075_HANDLER_PLPCDU_0_STRING = "TMP1075_HANDLER_PLPCDU_0";
|
||||
const char *TMP1075_HANDLER_PLPCDU_1_STRING = "TMP1075_HANDLER_PLPCDU_1";
|
||||
const char *TMP1075_HANDLER_IF_BOARD_STRING = "TMP1075_HANDLER_IF_BOARD";
|
||||
const char *TMP1075_HANDLER_OBC_IF_BOARD_STRING = "TMP1075_HANDLER_OBC_IF_BOARD";
|
||||
const char *RTD_0_IC3_PLOC_HEATSPREADER_STRING = "RTD_0_IC3_PLOC_HEATSPREADER";
|
||||
const char *RTD_1_IC4_PLOC_MISSIONBOARD_STRING = "RTD_1_IC4_PLOC_MISSIONBOARD";
|
||||
const char *RTD_2_IC5_4K_CAMERA_STRING = "RTD_2_IC5_4K_CAMERA";
|
||||
@ -80,26 +85,32 @@ const char *RTD_12_IC15_ACU_STRING = "RTD_12_IC15_ACU";
|
||||
const char *RTD_13_IC16_PLPCDU_HEATSPREADER_STRING = "RTD_13_IC16_PLPCDU_HEATSPREADER";
|
||||
const char *RTD_14_IC17_TCS_BOARD_STRING = "RTD_14_IC17_TCS_BOARD";
|
||||
const char *RTD_15_IC18_IMTQ_STRING = "RTD_15_IC18_IMTQ";
|
||||
const char *SYRLINKS_HK_HANDLER_STRING = "SYRLINKS_HK_HANDLER";
|
||||
const char *SYRLINKS_HANDLER_STRING = "SYRLINKS_HANDLER";
|
||||
const char *ARDUINO_COM_IF_STRING = "ARDUINO_COM_IF";
|
||||
const char *GPIO_IF_STRING = "GPIO_IF";
|
||||
const char *DUMMY_COM_IF_STRING = "DUMMY_COM_IF";
|
||||
const char *SCEX_UART_READER_STRING = "SCEX_UART_READER";
|
||||
const char *SPI_MAIN_COM_IF_STRING = "SPI_MAIN_COM_IF";
|
||||
const char *SPI_RW_COM_IF_STRING = "SPI_RW_COM_IF";
|
||||
const char *SPI_RTD_COM_IF_STRING = "SPI_RTD_COM_IF";
|
||||
const char *UART_COM_IF_STRING = "UART_COM_IF";
|
||||
const char *I2C_COM_IF_STRING = "I2C_COM_IF";
|
||||
const char *CSP_COM_IF_STRING = "CSP_COM_IF";
|
||||
const char *ACS_BOARD_POLLING_TASK_STRING = "ACS_BOARD_POLLING_TASK";
|
||||
const char *RW_POLLING_TASK_STRING = "RW_POLLING_TASK";
|
||||
const char *SPI_RTD_COM_IF_STRING = "SPI_RTD_COM_IF";
|
||||
const char *SUS_POLLING_TASK_STRING = "SUS_POLLING_TASK";
|
||||
const char *CCSDS_PACKET_DISTRIBUTOR_STRING = "CCSDS_PACKET_DISTRIBUTOR";
|
||||
const char *PUS_PACKET_DISTRIBUTOR_STRING = "PUS_PACKET_DISTRIBUTOR";
|
||||
const char *TMTC_BRIDGE_STRING = "TMTC_BRIDGE";
|
||||
const char *TMTC_POLLING_TASK_STRING = "TMTC_POLLING_TASK";
|
||||
const char *TCP_TMTC_SERVER_STRING = "TCP_TMTC_SERVER";
|
||||
const char *UDP_TMTC_SERVER_STRING = "UDP_TMTC_SERVER";
|
||||
const char *TCP_TMTC_POLLING_TASK_STRING = "TCP_TMTC_POLLING_TASK";
|
||||
const char *UDP_TMTC_POLLING_TASK_STRING = "UDP_TMTC_POLLING_TASK";
|
||||
const char *FILE_SYSTEM_HANDLER_STRING = "FILE_SYSTEM_HANDLER";
|
||||
const char *SDC_MANAGER_STRING = "SDC_MANAGER";
|
||||
const char *PTME_STRING = "PTME";
|
||||
const char *PDEC_HANDLER_STRING = "PDEC_HANDLER";
|
||||
const char *CCSDS_HANDLER_STRING = "CCSDS_HANDLER";
|
||||
const char *PUS_SERVICE_3_STRING = "PUS_SERVICE_3";
|
||||
const char *PUS_SERVICE_5_STRING = "PUS_SERVICE_5";
|
||||
const char *PUS_SERVICE_6_STRING = "PUS_SERVICE_6";
|
||||
const char *PUS_SERVICE_8_STRING = "PUS_SERVICE_8";
|
||||
const char *PUS_SERVICE_23_STRING = "PUS_SERVICE_23";
|
||||
const char *PUS_SERVICE_201_STRING = "PUS_SERVICE_201";
|
||||
const char *FSFW_OBJECTS_START_STRING = "FSFW_OBJECTS_START";
|
||||
const char *PUS_SERVICE_1_VERIFICATION_STRING = "PUS_SERVICE_1_VERIFICATION";
|
||||
const char *PUS_SERVICE_2_DEVICE_ACCESS_STRING = "PUS_SERVICE_2_DEVICE_ACCESS";
|
||||
@ -108,6 +119,7 @@ const char *PUS_SERVICE_5_EVENT_REPORTING_STRING = "PUS_SERVICE_5_EVENT_REPORTIN
|
||||
const char *PUS_SERVICE_8_FUNCTION_MGMT_STRING = "PUS_SERVICE_8_FUNCTION_MGMT";
|
||||
const char *PUS_SERVICE_9_TIME_MGMT_STRING = "PUS_SERVICE_9_TIME_MGMT";
|
||||
const char *PUS_SERVICE_11_TC_SCHEDULER_STRING = "PUS_SERVICE_11_TC_SCHEDULER";
|
||||
const char *PUS_SERVICE_15_TM_STORAGE_STRING = "PUS_SERVICE_15_TM_STORAGE";
|
||||
const char *PUS_SERVICE_17_TEST_STRING = "PUS_SERVICE_17_TEST";
|
||||
const char *PUS_SERVICE_20_PARAMETERS_STRING = "PUS_SERVICE_20_PARAMETERS";
|
||||
const char *PUS_SERVICE_200_MODE_MGMT_STRING = "PUS_SERVICE_200_MODE_MGMT";
|
||||
@ -123,14 +135,6 @@ const char *IPC_STORE_STRING = "IPC_STORE";
|
||||
const char *TIME_STAMPER_STRING = "TIME_STAMPER";
|
||||
const char *VERIFICATION_REPORTER_STRING = "VERIFICATION_REPORTER";
|
||||
const char *FSFW_OBJECTS_END_STRING = "FSFW_OBJECTS_END";
|
||||
const char *SPI_TEST_STRING = "SPI_TEST";
|
||||
const char *UART_TEST_STRING = "UART_TEST";
|
||||
const char *I2C_TEST_STRING = "I2C_TEST";
|
||||
const char *DUMMY_COM_IF_STRING = "DUMMY_COM_IF";
|
||||
const char *DUMMY_HANDLER_STRING = "DUMMY_HANDLER";
|
||||
const char *DUMMY_INTERFACE_STRING = "DUMMY_INTERFACE";
|
||||
const char *LIBGPIOD_TEST_STRING = "LIBGPIOD_TEST";
|
||||
const char *TEST_TASK_STRING = "TEST_TASK";
|
||||
const char *HEATER_0_PLOC_PROC_BRD_STRING = "HEATER_0_PLOC_PROC_BRD";
|
||||
const char *HEATER_1_PCDU_BRD_STRING = "HEATER_1_PCDU_BRD";
|
||||
const char *HEATER_2_ACS_BRD_STRING = "HEATER_2_ACS_BRD";
|
||||
@ -138,12 +142,15 @@ const char *HEATER_3_OBC_BRD_STRING = "HEATER_3_OBC_BRD";
|
||||
const char *HEATER_4_CAMERA_STRING = "HEATER_4_CAMERA";
|
||||
const char *HEATER_5_STR_STRING = "HEATER_5_STR";
|
||||
const char *HEATER_6_DRO_STRING = "HEATER_6_DRO";
|
||||
const char *HEATER_7_HPA_STRING = "HEATER_7_HPA";
|
||||
const char *HEATER_7_SYRLINKS_STRING = "HEATER_7_SYRLINKS";
|
||||
const char *ACS_BOARD_ASS_STRING = "ACS_BOARD_ASS";
|
||||
const char *SUS_BOARD_ASS_STRING = "SUS_BOARD_ASS";
|
||||
const char *TCS_BOARD_ASS_STRING = "TCS_BOARD_ASS";
|
||||
const char *RW_ASS_STRING = "RW_ASS";
|
||||
const char *RW_ASSY_STRING = "RW_ASSY";
|
||||
const char *CAM_SWITCHER_STRING = "CAM_SWITCHER";
|
||||
const char *SYRLINKS_ASSY_STRING = "SYRLINKS_ASSY";
|
||||
const char *IMTQ_ASSY_STRING = "IMTQ_ASSY";
|
||||
const char *STR_ASSY_STRING = "STR_ASSY";
|
||||
const char *TM_FUNNEL_STRING = "TM_FUNNEL";
|
||||
const char *PUS_TM_FUNNEL_STRING = "PUS_TM_FUNNEL";
|
||||
const char *CFDP_TM_FUNNEL_STRING = "CFDP_TM_FUNNEL";
|
||||
@ -152,13 +159,27 @@ const char *CFDP_DISTRIBUTOR_STRING = "CFDP_DISTRIBUTOR";
|
||||
const char *EIVE_SYSTEM_STRING = "EIVE_SYSTEM";
|
||||
const char *ACS_SUBSYSTEM_STRING = "ACS_SUBSYSTEM";
|
||||
const char *PL_SUBSYSTEM_STRING = "PL_SUBSYSTEM";
|
||||
const char *TCS_SUBSYSTEM_STRING = "TCS_SUBSYSTEM";
|
||||
const char *COM_SUBSYSTEM_STRING = "COM_SUBSYSTEM";
|
||||
const char *MISC_TM_STORE_STRING = "MISC_TM_STORE";
|
||||
const char *OK_TM_STORE_STRING = "OK_TM_STORE";
|
||||
const char *NOT_OK_TM_STORE_STRING = "NOT_OK_TM_STORE";
|
||||
const char *HK_TM_STORE_STRING = "HK_TM_STORE";
|
||||
const char *CFDP_TM_STORE_STRING = "CFDP_TM_STORE";
|
||||
const char *LIVE_TM_TASK_STRING = "LIVE_TM_TASK";
|
||||
const char *LOG_STORE_AND_TM_TASK_STRING = "LOG_STORE_AND_TM_TASK";
|
||||
const char *HK_STORE_AND_TM_TASK_STRING = "HK_STORE_AND_TM_TASK";
|
||||
const char *CFDP_STORE_AND_TM_TASK_STRING = "CFDP_STORE_AND_TM_TASK";
|
||||
const char *DOWNLINK_RAM_STORE_STRING = "DOWNLINK_RAM_STORE";
|
||||
const char *CCSDS_IP_CORE_BRIDGE_STRING = "CCSDS_IP_CORE_BRIDGE";
|
||||
const char *THERMAL_TEMP_INSERTER_STRING = "THERMAL_TEMP_INSERTER";
|
||||
const char *DUMMY_INTERFACE_STRING = "DUMMY_INTERFACE";
|
||||
const char *NO_OBJECT_STRING = "NO_OBJECT";
|
||||
|
||||
const char *translateObject(object_id_t object) {
|
||||
switch ((object & 0xFFFFFFFF)) {
|
||||
case 0x00005060:
|
||||
return P60DOCK_TEST_TASK_STRING;
|
||||
case 0x42694269:
|
||||
return TEST_TASK_STRING;
|
||||
case 0x43000002:
|
||||
return ACS_CONTROLLER_STRING;
|
||||
case 0x43000003:
|
||||
@ -167,6 +188,8 @@ const char *translateObject(object_id_t object) {
|
||||
return GLOBAL_JSON_CFG_STRING;
|
||||
case 0x43400001:
|
||||
return THERMAL_CONTROLLER_STRING;
|
||||
case 0x44000001:
|
||||
return DUMMY_HANDLER_STRING;
|
||||
case 0x44120006:
|
||||
return MGM_0_LIS3_HANDLER_STRING;
|
||||
case 0x44120010:
|
||||
@ -219,6 +242,8 @@ const char *translateObject(object_id_t object) {
|
||||
return STAR_TRACKER_STRING;
|
||||
case 0x44130045:
|
||||
return GPS_CONTROLLER_STRING;
|
||||
case 0x44140013:
|
||||
return IMTQ_POLLING_STRING;
|
||||
case 0x44140014:
|
||||
return IMTQ_HANDLER_STRING;
|
||||
case 0x442000A1:
|
||||
@ -249,6 +274,14 @@ const char *translateObject(object_id_t object) {
|
||||
return AXI_PTME_CONFIG_STRING;
|
||||
case 0x44330005:
|
||||
return PTME_CONFIG_STRING;
|
||||
case 0x44330006:
|
||||
return PTME_VC0_LIVE_TM_STRING;
|
||||
case 0x44330007:
|
||||
return PTME_VC1_LOG_TM_STRING;
|
||||
case 0x44330008:
|
||||
return PTME_VC2_HK_TM_STRING;
|
||||
case 0x44330009:
|
||||
return PTME_VC3_CFDP_TM_STRING;
|
||||
case 0x44330015:
|
||||
return PLOC_MPSOC_HANDLER_STRING;
|
||||
case 0x44330016:
|
||||
@ -271,8 +304,6 @@ const char *translateObject(object_id_t object) {
|
||||
return TMP1075_HANDLER_PLPCDU_1_STRING;
|
||||
case 0x44420008:
|
||||
return TMP1075_HANDLER_IF_BOARD_STRING;
|
||||
case 0x44420009:
|
||||
return TMP1075_HANDLER_OBC_IF_BOARD_STRING;
|
||||
case 0x44420016:
|
||||
return RTD_0_IC3_PLOC_HEATSPREADER_STRING;
|
||||
case 0x44420017:
|
||||
@ -306,33 +337,35 @@ const char *translateObject(object_id_t object) {
|
||||
case 0x44420031:
|
||||
return RTD_15_IC18_IMTQ_STRING;
|
||||
case 0x445300A3:
|
||||
return SYRLINKS_HK_HANDLER_STRING;
|
||||
case 0x49000000:
|
||||
return SYRLINKS_HANDLER_STRING;
|
||||
case 0x49000001:
|
||||
return ARDUINO_COM_IF_STRING;
|
||||
case 0x49010005:
|
||||
return GPIO_IF_STRING;
|
||||
case 0x49000002:
|
||||
return DUMMY_COM_IF_STRING;
|
||||
case 0x49010006:
|
||||
return SCEX_UART_READER_STRING;
|
||||
case 0x49020004:
|
||||
return SPI_MAIN_COM_IF_STRING;
|
||||
case 0x49020005:
|
||||
return SPI_RW_COM_IF_STRING;
|
||||
case 0x49020006:
|
||||
return SPI_RTD_COM_IF_STRING;
|
||||
case 0x49030003:
|
||||
return UART_COM_IF_STRING;
|
||||
case 0x49040002:
|
||||
return I2C_COM_IF_STRING;
|
||||
case 0x49050001:
|
||||
return CSP_COM_IF_STRING;
|
||||
case 0x49060004:
|
||||
return ACS_BOARD_POLLING_TASK_STRING;
|
||||
case 0x49060005:
|
||||
return RW_POLLING_TASK_STRING;
|
||||
case 0x49060006:
|
||||
return SPI_RTD_COM_IF_STRING;
|
||||
case 0x49060007:
|
||||
return SUS_POLLING_TASK_STRING;
|
||||
case 0x50000100:
|
||||
return CCSDS_PACKET_DISTRIBUTOR_STRING;
|
||||
case 0x50000200:
|
||||
return PUS_PACKET_DISTRIBUTOR_STRING;
|
||||
case 0x50000300:
|
||||
return TMTC_BRIDGE_STRING;
|
||||
return TCP_TMTC_SERVER_STRING;
|
||||
case 0x50000301:
|
||||
return UDP_TMTC_SERVER_STRING;
|
||||
case 0x50000400:
|
||||
return TMTC_POLLING_TASK_STRING;
|
||||
return TCP_TMTC_POLLING_TASK_STRING;
|
||||
case 0x50000401:
|
||||
return UDP_TMTC_POLLING_TASK_STRING;
|
||||
case 0x50000500:
|
||||
return FILE_SYSTEM_HANDLER_STRING;
|
||||
case 0x50000550:
|
||||
@ -343,8 +376,18 @@ const char *translateObject(object_id_t object) {
|
||||
return PDEC_HANDLER_STRING;
|
||||
case 0x50000800:
|
||||
return CCSDS_HANDLER_STRING;
|
||||
case 0x51000300:
|
||||
return PUS_SERVICE_3_STRING;
|
||||
case 0x51000400:
|
||||
return PUS_SERVICE_5_STRING;
|
||||
case 0x51000500:
|
||||
return PUS_SERVICE_6_STRING;
|
||||
case 0x51000800:
|
||||
return PUS_SERVICE_8_STRING;
|
||||
case 0x51002300:
|
||||
return PUS_SERVICE_23_STRING;
|
||||
case 0x51020100:
|
||||
return PUS_SERVICE_201_STRING;
|
||||
case 0x53000000:
|
||||
return FSFW_OBJECTS_START_STRING;
|
||||
case 0x53000001:
|
||||
@ -361,6 +404,8 @@ const char *translateObject(object_id_t object) {
|
||||
return PUS_SERVICE_9_TIME_MGMT_STRING;
|
||||
case 0x53000011:
|
||||
return PUS_SERVICE_11_TC_SCHEDULER_STRING;
|
||||
case 0x53000015:
|
||||
return PUS_SERVICE_15_TM_STORAGE_STRING;
|
||||
case 0x53000017:
|
||||
return PUS_SERVICE_17_TEST_STRING;
|
||||
case 0x53000020:
|
||||
@ -391,22 +436,6 @@ const char *translateObject(object_id_t object) {
|
||||
return VERIFICATION_REPORTER_STRING;
|
||||
case 0x53ffffff:
|
||||
return FSFW_OBJECTS_END_STRING;
|
||||
case 0x54000010:
|
||||
return SPI_TEST_STRING;
|
||||
case 0x54000020:
|
||||
return UART_TEST_STRING;
|
||||
case 0x54000030:
|
||||
return I2C_TEST_STRING;
|
||||
case 0x54000040:
|
||||
return DUMMY_COM_IF_STRING;
|
||||
case 0x5400AFFE:
|
||||
return DUMMY_HANDLER_STRING;
|
||||
case 0x5400CAFE:
|
||||
return DUMMY_INTERFACE_STRING;
|
||||
case 0x54123456:
|
||||
return LIBGPIOD_TEST_STRING;
|
||||
case 0x54694269:
|
||||
return TEST_TASK_STRING;
|
||||
case 0x60000000:
|
||||
return HEATER_0_PLOC_PROC_BRD_STRING;
|
||||
case 0x60000001:
|
||||
@ -422,7 +451,7 @@ const char *translateObject(object_id_t object) {
|
||||
case 0x60000006:
|
||||
return HEATER_6_DRO_STRING;
|
||||
case 0x60000007:
|
||||
return HEATER_7_HPA_STRING;
|
||||
return HEATER_7_SYRLINKS_STRING;
|
||||
case 0x73000001:
|
||||
return ACS_BOARD_ASS_STRING;
|
||||
case 0x73000002:
|
||||
@ -430,9 +459,15 @@ const char *translateObject(object_id_t object) {
|
||||
case 0x73000003:
|
||||
return TCS_BOARD_ASS_STRING;
|
||||
case 0x73000004:
|
||||
return RW_ASS_STRING;
|
||||
return RW_ASSY_STRING;
|
||||
case 0x73000006:
|
||||
return CAM_SWITCHER_STRING;
|
||||
case 0x73000007:
|
||||
return SYRLINKS_ASSY_STRING;
|
||||
case 0x73000008:
|
||||
return IMTQ_ASSY_STRING;
|
||||
case 0x73000009:
|
||||
return STR_ASSY_STRING;
|
||||
case 0x73000100:
|
||||
return TM_FUNNEL_STRING;
|
||||
case 0x73000101:
|
||||
@ -449,8 +484,36 @@ const char *translateObject(object_id_t object) {
|
||||
return ACS_SUBSYSTEM_STRING;
|
||||
case 0x73010002:
|
||||
return PL_SUBSYSTEM_STRING;
|
||||
case 0x73010003:
|
||||
return TCS_SUBSYSTEM_STRING;
|
||||
case 0x73010004:
|
||||
return COM_SUBSYSTEM_STRING;
|
||||
case 0x73020001:
|
||||
return MISC_TM_STORE_STRING;
|
||||
case 0x73020002:
|
||||
return OK_TM_STORE_STRING;
|
||||
case 0x73020003:
|
||||
return NOT_OK_TM_STORE_STRING;
|
||||
case 0x73020004:
|
||||
return HK_TM_STORE_STRING;
|
||||
case 0x73030000:
|
||||
return CFDP_TM_STORE_STRING;
|
||||
case 0x73040000:
|
||||
return LIVE_TM_TASK_STRING;
|
||||
case 0x73040001:
|
||||
return LOG_STORE_AND_TM_TASK_STRING;
|
||||
case 0x73040002:
|
||||
return HK_STORE_AND_TM_TASK_STRING;
|
||||
case 0x73040003:
|
||||
return CFDP_STORE_AND_TM_TASK_STRING;
|
||||
case 0x73040004:
|
||||
return DOWNLINK_RAM_STORE_STRING;
|
||||
case 0x73500000:
|
||||
return CCSDS_IP_CORE_BRIDGE_STRING;
|
||||
case 0x90000003:
|
||||
return THERMAL_TEMP_INSERTER_STRING;
|
||||
case 0xCAFECAFE:
|
||||
return DUMMY_INTERFACE_STRING;
|
||||
case 0xFFFFFFFF:
|
||||
return NO_OBJECT_STRING;
|
||||
default:
|
||||
|
@ -13,6 +13,7 @@
|
||||
namespace CLASS_ID {
|
||||
enum {
|
||||
CLASS_ID_START = COMMON_CLASS_ID_END,
|
||||
CLASS_ID_END // [EXPORT] : [END]
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -14,6 +14,7 @@
|
||||
|
||||
#include "OBSWConfig.h"
|
||||
#include "ObjectFactory.h"
|
||||
#include "mission/core/scheduling.h"
|
||||
#include "scheduling.h"
|
||||
|
||||
#ifdef LINUX
|
||||
@ -55,26 +56,30 @@ void scheduling::initTasks() {
|
||||
|
||||
/* TMTC Distribution */
|
||||
PeriodicTaskIF* tmtcDistributor = factory->createPeriodicTask(
|
||||
"DIST", 45, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.2, missedDeadlineFunc);
|
||||
"DIST", 60, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.2, missedDeadlineFunc);
|
||||
ReturnValue_t result = tmtcDistributor->addComponent(objects::CCSDS_PACKET_DISTRIBUTOR);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "Object add component failed" << std::endl;
|
||||
sif::error << "adding CCSDS distributor failed" << std::endl;
|
||||
}
|
||||
result = tmtcDistributor->addComponent(objects::PUS_PACKET_DISTRIBUTOR);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "Object add component failed" << std::endl;
|
||||
sif::error << "adding PUS distributor failed" << std::endl;
|
||||
}
|
||||
result = tmtcDistributor->addComponent(objects::TM_FUNNEL);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "Object add component failed" << std::endl;
|
||||
sif::error << "adding TM funnel failed" << std::endl;
|
||||
}
|
||||
result = tmtcDistributor->addComponent(objects::CFDP_DISTRIBUTOR);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "adding CFDP distributor failed" << std::endl;
|
||||
}
|
||||
result = tmtcDistributor->addComponent(objects::UDP_TMTC_SERVER);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "Add component UDP Unix Bridge failed" << std::endl;
|
||||
sif::error << "adding UDP server failed" << std::endl;
|
||||
}
|
||||
result = tmtcDistributor->addComponent(objects::TCP_TMTC_SERVER);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "Add component UDP Unix Bridge failed" << std::endl;
|
||||
sif::error << "adding TCP server failed" << std::endl;
|
||||
}
|
||||
|
||||
PeriodicTaskIF* udpPollingTask = factory->createPeriodicTask(
|
||||
@ -90,46 +95,43 @@ void scheduling::initTasks() {
|
||||
sif::error << "Add component UDP Polling failed" << std::endl;
|
||||
}
|
||||
|
||||
/* PUS Services */
|
||||
PeriodicTaskIF* pusVerification = factory->createPeriodicTask(
|
||||
"PUS_VERIF", 40, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.200, missedDeadlineFunc);
|
||||
result = pusVerification->addComponent(objects::PUS_SERVICE_1_VERIFICATION);
|
||||
PeriodicTaskIF* pusHighPrio = factory->createPeriodicTask(
|
||||
"PUS_HIGH_PRIO", 60, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.200, missedDeadlineFunc);
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_1_VERIFICATION);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "Object add component failed" << std::endl;
|
||||
}
|
||||
|
||||
PeriodicTaskIF* eventHandling = factory->createPeriodicTask(
|
||||
"EVENTS", 60, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.200, missedDeadlineFunc);
|
||||
result = eventHandling->addComponent(objects::EVENT_MANAGER);
|
||||
result = pusHighPrio->addComponent(objects::EVENT_MANAGER);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("EVENT_MNGR", objects::EVENT_MANAGER);
|
||||
scheduling::printAddObjectError("EVENT_MGMT", objects::EVENT_MANAGER);
|
||||
}
|
||||
result = eventHandling->addComponent(objects::PUS_SERVICE_5_EVENT_REPORTING);
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_5_EVENT_REPORTING);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS5", objects::PUS_SERVICE_5_EVENT_REPORTING);
|
||||
}
|
||||
|
||||
PeriodicTaskIF* pusHighPrio = factory->createPeriodicTask(
|
||||
"PUS_HIGH_PRIO", 50, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.200, missedDeadlineFunc);
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_2_DEVICE_ACCESS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS2", objects::PUS_SERVICE_2_DEVICE_ACCESS);
|
||||
}
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_9_TIME_MGMT);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS9", objects::PUS_SERVICE_9_TIME_MGMT);
|
||||
}
|
||||
|
||||
PeriodicTaskIF* pusMedPrio = factory->createPeriodicTask(
|
||||
"PUS_MED_PRIO", 40, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.8, missedDeadlineFunc);
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_2_DEVICE_ACCESS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS2", objects::PUS_SERVICE_2_DEVICE_ACCESS);
|
||||
}
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_3_HOUSEKEEPING);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS3", objects::PUS_SERVICE_3_HOUSEKEEPING);
|
||||
}
|
||||
|
||||
PeriodicTaskIF* pusMedPrio = factory->createPeriodicTask(
|
||||
"PUS_MED_PRIO", 40, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.8, missedDeadlineFunc);
|
||||
result = pusMedPrio->addComponent(objects::PUS_SERVICE_8_FUNCTION_MGMT);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS8", objects::PUS_SERVICE_8_FUNCTION_MGMT);
|
||||
}
|
||||
result = pusMedPrio->addComponent(objects::PUS_SERVICE_15_TM_STORAGE);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS15", objects::PUS_SERVICE_15_TM_STORAGE);
|
||||
}
|
||||
result = pusMedPrio->addComponent(objects::PUS_SERVICE_200_MODE_MGMT);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS200", objects::PUS_SERVICE_200_MODE_MGMT);
|
||||
@ -138,10 +140,7 @@ void scheduling::initTasks() {
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS20", objects::PUS_SERVICE_20_PARAMETERS);
|
||||
}
|
||||
|
||||
PeriodicTaskIF* pusLowPrio = factory->createPeriodicTask(
|
||||
"PUS_LOW_PRIO", 30, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.6, missedDeadlineFunc);
|
||||
result = pusLowPrio->addComponent(objects::PUS_SERVICE_17_TEST);
|
||||
result = pusMedPrio->addComponent(objects::PUS_SERVICE_17_TEST);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS17", objects::PUS_SERVICE_17_TEST);
|
||||
}
|
||||
@ -165,6 +164,15 @@ void scheduling::initTasks() {
|
||||
sif::error << "Failed to add dummy pst to fixed timeslot task" << std::endl;
|
||||
}
|
||||
|
||||
#if OBSW_ADD_CFDP_COMPONENTS == 1
|
||||
PeriodicTaskIF* cfdpTask = factory->createPeriodicTask(
|
||||
"CFDP Handler", 45, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.4, missedDeadlineFunc);
|
||||
result = cfdpTask->addComponent(objects::CFDP_HANDLER);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("CFDP Handler", objects::CFDP_HANDLER);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if OBSW_ADD_PLOC_SUPERVISOR == 1
|
||||
PeriodicTaskIF* supvHelperTask = factory->createPeriodicTask(
|
||||
"PLOC_SUPV_HELPER", 20, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.0, missedDeadlineFunc);
|
||||
@ -186,6 +194,8 @@ void scheduling::initTasks() {
|
||||
|
||||
PeriodicTaskIF* dummyTask = factory->createPeriodicTask(
|
||||
"DUMMY_TASK", 30, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.0, missedDeadlineFunc);
|
||||
scheduling::scheduleTmpTempSensors(dummyTask);
|
||||
scheduling::scheduleRtdSensors(dummyTask);
|
||||
dummyTask->addComponent(objects::SUS_0_N_LOC_XFYFZM_PT_XF);
|
||||
dummyTask->addComponent(objects::SUS_1_N_LOC_XBYFZM_PT_XB);
|
||||
dummyTask->addComponent(objects::SUS_2_N_LOC_XFYBZB_PT_YB);
|
||||
@ -198,33 +208,14 @@ void scheduling::initTasks() {
|
||||
dummyTask->addComponent(objects::SUS_9_R_LOC_XBYBZB_PT_YF);
|
||||
dummyTask->addComponent(objects::SUS_10_N_LOC_XMYBZF_PT_ZF);
|
||||
dummyTask->addComponent(objects::SUS_11_R_LOC_XBYMZB_PT_ZB);
|
||||
dummyTask->addComponent(objects::RTD_0_IC3_PLOC_HEATSPREADER);
|
||||
dummyTask->addComponent(objects::RTD_1_IC4_PLOC_MISSIONBOARD);
|
||||
dummyTask->addComponent(objects::RTD_2_IC5_4K_CAMERA);
|
||||
dummyTask->addComponent(objects::RTD_3_IC6_DAC_HEATSPREADER);
|
||||
dummyTask->addComponent(objects::RTD_4_IC7_STARTRACKER);
|
||||
dummyTask->addComponent(objects::RTD_5_IC8_RW1_MX_MY);
|
||||
dummyTask->addComponent(objects::RTD_6_IC9_DRO);
|
||||
dummyTask->addComponent(objects::RTD_7_IC10_SCEX);
|
||||
dummyTask->addComponent(objects::RTD_8_IC11_X8);
|
||||
dummyTask->addComponent(objects::RTD_9_IC12_HPA);
|
||||
dummyTask->addComponent(objects::RTD_10_IC13_PL_TX);
|
||||
dummyTask->addComponent(objects::RTD_11_IC14_MPA);
|
||||
dummyTask->addComponent(objects::RTD_12_IC15_ACU);
|
||||
dummyTask->addComponent(objects::RTD_13_IC16_PLPCDU_HEATSPREADER);
|
||||
dummyTask->addComponent(objects::RTD_14_IC17_TCS_BOARD);
|
||||
dummyTask->addComponent(objects::RTD_15_IC18_IMTQ);
|
||||
|
||||
sif::info << "Starting tasks.." << std::endl;
|
||||
tmtcDistributor->startTask();
|
||||
udpPollingTask->startTask();
|
||||
tcpPollingTask->startTask();
|
||||
|
||||
pusVerification->startTask();
|
||||
eventHandling->startTask();
|
||||
pusHighPrio->startTask();
|
||||
pusMedPrio->startTask();
|
||||
pusLowPrio->startTask();
|
||||
|
||||
pstTask->startTask();
|
||||
thermalTask->startTask();
|
||||
@ -235,6 +226,9 @@ void scheduling::initTasks() {
|
||||
#if OBSW_ADD_PLOC_SUPERVISOR == 1 || OBSW_ADD_PLOC_MPSOC == 1
|
||||
plTask->startTask();
|
||||
#endif
|
||||
#if OBSW_ADD_CFDP_COMPONENTS == 1
|
||||
cfdpTask->startTask();
|
||||
#endif
|
||||
|
||||
#if OBSW_ADD_TEST_CODE == 1
|
||||
testTask->startTask();
|
||||
|
@ -1,5 +1,5 @@
|
||||
target_sources(${OBSW_NAME} PUBLIC InitMission.cpp main.cpp gpioInit.cpp
|
||||
ObjectFactory.cpp RPiSdCardManager.cpp)
|
||||
ObjectFactory.cpp)
|
||||
|
||||
add_subdirectory(boardconfig)
|
||||
add_subdirectory(boardtest)
|
||||
|
@ -82,7 +82,7 @@ void ObjectFactory::produce(void* args) {
|
||||
#endif
|
||||
|
||||
#if OBSW_ADD_SCEX_DEVICE == 1
|
||||
auto* sdcMan = new RPiSdCardManager("/tmp");
|
||||
auto* sdcMan = new DummySdCardManager("/tmp");
|
||||
createScexComponents(uart::DEV, pwrSwitcher, *sdcMan, true, std::nullopt);
|
||||
#endif
|
||||
|
||||
|
@ -1,13 +0,0 @@
|
||||
#include "RPiSdCardManager.h"
|
||||
|
||||
RPiSdCardManager::RPiSdCardManager(std::string prefix) : prefix(std::move(prefix)) {}
|
||||
|
||||
const std::string& RPiSdCardManager::getCurrentMountPrefix() const { return prefix; }
|
||||
|
||||
bool RPiSdCardManager::isSdCardUsable(sd::SdCard sdCard) { return true; }
|
||||
|
||||
std::optional<sd::SdCard> RPiSdCardManager::getPreferredSdCard() const { return std::nullopt; }
|
||||
|
||||
void RPiSdCardManager::setActiveSdCard(sd::SdCard sdCard) {}
|
||||
|
||||
std::optional<sd::SdCard> RPiSdCardManager::getActiveSdCard() const { return std::nullopt; }
|
@ -8,12 +8,17 @@
|
||||
|
||||
#include "commonConfig.h"
|
||||
#include "q7sConfig.h"
|
||||
#include "OBSWVersion.h"
|
||||
|
||||
/*******************************************************************/
|
||||
/** All of the following flags should be enabled for mission code */
|
||||
/*******************************************************************/
|
||||
|
||||
#define OBSW_ENABLE_PERIODIC_HK 0
|
||||
#define OBSW_ENABLE_SYRLINKS_TRANSMIT_TIMEOUT 0
|
||||
// This switch will cause the SW to command the EIVE system object to safe mode. This will
|
||||
// trigger a lot of events, so it can make sense to disable this for debugging purposes
|
||||
#define OBSW_COMMAND_SAFE_MODE_AT_STARTUP 1
|
||||
|
||||
#define OBSW_ADD_GOMSPACE_PCDU @OBSW_ADD_GOMSPACE_PCDU@
|
||||
#define OBSW_ADD_MGT @OBSW_ADD_MGT@
|
||||
#define OBSW_ADD_BPX_BATTERY_HANDLER @OBSW_ADD_BPX_BATTERY_HANDLER@
|
||||
@ -40,31 +45,29 @@
|
||||
#define OBSW_TM_TO_PTME @OBSW_TM_TO_PTME@
|
||||
// Set to 1 if telecommands are received via the PDEC IP Core
|
||||
#define OBSW_TC_FROM_PDEC @OBSW_TC_FROM_PDEC@
|
||||
#define OBSW_ENABLE_SYRLINKS_TRANSMIT_TIMEOUT 0
|
||||
|
||||
// Configuration parameter which causes the core controller to try to keep at least one SD card
|
||||
// working
|
||||
#define OBSW_SD_CARD_MUST_BE_ON 1
|
||||
#define OBSW_ENABLE_TIMERS 1
|
||||
|
||||
// This is a really tricky switch.. It initializes the PCDU switches to their default states
|
||||
// at powerup. I think it would be better
|
||||
// to leave it off for now. It makes testing a lot more difficult and it might mess with
|
||||
// something the operators might want to do by giving the software too much intelligence
|
||||
// at the wrong place. The system component might command all the Switches accordingly anyway
|
||||
#define OBSW_INITIALIZE_SWITCHES 0
|
||||
#define OBSW_ENABLE_PERIODIC_HK 0
|
||||
|
||||
/*******************************************************************/
|
||||
/** All of the following flags should be disabled for mission code */
|
||||
/*******************************************************************/
|
||||
|
||||
// Use TCP instead of UDP for the TMTC bridge. This allows using the TMTC client locally
|
||||
// because UDP packets are not allowed in the VPN
|
||||
// This will cause the OBSW to initialize the TMTC bridge responsible for exchanging data with the
|
||||
// CCSDS IP Cores.
|
||||
#define OBSW_ADD_TMTC_TCP_SERVER 1
|
||||
#define OBSW_ADD_TMTC_UDP_SERVER 1
|
||||
|
||||
// Can be used to switch device to NORMAL mode immediately
|
||||
#define OBSW_SWITCH_TO_NORMAL_MODE_AFTER_STARTUP 0
|
||||
#define OBSW_PRINT_MISSED_DEADLINES 1
|
||||
|
||||
#define OBSW_MPSOC_JTAG_BOOT 0
|
||||
#define OBSW_STAR_TRACKER_GROUND_CONFIG 1
|
||||
#define OBSW_STAR_TRACKER_GROUND_CONFIG @OBSW_STAR_TRACKER_GROUND_CONFIG@
|
||||
#define OBSW_SYRLINKS_SIMULATED @OBSW_SYRLINKS_SIMULATED@
|
||||
#define OBSW_ADD_TEST_CODE 0
|
||||
#define OBSW_ADD_TEST_TASK 0
|
||||
@ -120,13 +123,6 @@
|
||||
/** CMake Defines */
|
||||
/*******************************************************************/
|
||||
|
||||
// Use TCP instead of UDP for the TMTC bridge. This allows using the TMTC client locally
|
||||
// because UDP packets are not allowed in the VPN
|
||||
// This will cause the OBSW to initialize the TMTC bridge responsible for exchanging data with the
|
||||
// CCSDS IP Cores.
|
||||
#define OBSW_ADD_TMTC_TCP_SERVER 1
|
||||
#define OBSW_ADD_TMTC_UDP_SERVER 1
|
||||
|
||||
#cmakedefine EIVE_BUILD_GPSD_GPS_HANDLER
|
||||
|
||||
#cmakedefine LIBGPS_VERSION_MAJOR @LIBGPS_VERSION_MAJOR@
|
||||
|
@ -28,9 +28,13 @@ static constexpr char UIO_PDEC_IRQ[] = "/dev/uio_pdec_irq";
|
||||
static constexpr int MAP_ID_PTME_CONFIG = 3;
|
||||
|
||||
namespace uiomapids {
|
||||
// Live TM
|
||||
static const int PTME_VC0 = 0;
|
||||
// OK/NOK/MISC Store
|
||||
static const int PTME_VC1 = 1;
|
||||
// HK store
|
||||
static const int PTME_VC2 = 2;
|
||||
// CFDP
|
||||
static const int PTME_VC3 = 3;
|
||||
static const int PTME_CONFIG = 4;
|
||||
} // namespace uiomapids
|
||||
@ -86,6 +90,8 @@ static constexpr char PAPB_BUSY_SIGNAL_VC2[] = "papb_busy_signal_vc2";
|
||||
static constexpr char PAPB_EMPTY_SIGNAL_VC2[] = "papb_empty_signal_vc2";
|
||||
static constexpr char PAPB_BUSY_SIGNAL_VC3[] = "papb_busy_signal_vc3";
|
||||
static constexpr char PAPB_EMPTY_SIGNAL_VC3[] = "papb_empty_signal_vc3";
|
||||
static constexpr char PTME_RESETN[] = "ptme_resetn";
|
||||
|
||||
static constexpr char RS485_EN_TX_CLOCK[] = "tx_clock_enable_ltc2872";
|
||||
static constexpr char RS485_EN_TX_DATA[] = "tx_data_enable_ltc2872";
|
||||
static constexpr char RS485_EN_RX_CLOCK[] = "rx_clock_enable_ltc2872";
|
||||
|
@ -17,7 +17,7 @@
|
||||
/*******************************************************************/
|
||||
|
||||
// Probably better if this is disabled for mission code. Convenient for development
|
||||
#define Q7S_CHECK_FOR_ALREADY_RUNNING_IMG 1
|
||||
#define Q7S_CHECK_FOR_ALREADY_RUNNING_IMG @Q7S_CHECK_FOR_ALREADY_RUNNING_IMG@
|
||||
|
||||
#define Q7S_SIMPLE_ADD_FILE_SYSTEM_TEST 0
|
||||
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
#include <libgpsmm.h>
|
||||
|
||||
#include "test/testtasks/TestTask.h"
|
||||
#include "test/TestTask.h"
|
||||
|
||||
class CoreController;
|
||||
|
||||
|
@ -76,7 +76,7 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
if (write(fileDescriptor, writeBuffer, writeSize) != static_cast<ssize_t>(writeSize)) {
|
||||
sif::error << "rwSpiCallback::spiCallback: Write failed!" << std::endl;
|
||||
closeSpi(fileDescriptor, gpioId, &gpioIF, mutex);
|
||||
return RwHandler::SPI_WRITE_FAILURE;
|
||||
return rws::SPI_WRITE_FAILURE;
|
||||
}
|
||||
|
||||
/** Encoding and sending command */
|
||||
@ -101,7 +101,7 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
if (write(fileDescriptor, writeBuffer, writeSize) != static_cast<ssize_t>(writeSize)) {
|
||||
sif::error << "rwSpiCallback::spiCallback: Write failed!" << std::endl;
|
||||
closeSpi(fileDescriptor, gpioId, &gpioIF, mutex);
|
||||
return RwHandler::SPI_WRITE_FAILURE;
|
||||
return rws::SPI_WRITE_FAILURE;
|
||||
}
|
||||
idx++;
|
||||
}
|
||||
@ -113,7 +113,7 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
if (write(fileDescriptor, writeBuffer, writeSize) != static_cast<ssize_t>(writeSize)) {
|
||||
sif::error << "rwSpiCallback::spiCallback: Write failed!" << std::endl;
|
||||
closeSpi(fileDescriptor, gpioId, &gpioIF, mutex);
|
||||
return RwHandler::SPI_WRITE_FAILURE;
|
||||
return rws::SPI_WRITE_FAILURE;
|
||||
}
|
||||
|
||||
uint8_t* rxBuf = nullptr;
|
||||
@ -128,7 +128,7 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
// There must be a delay of at least 20 ms after sending the command.
|
||||
// Delay for 70 ms here and release the SPI bus for that duration.
|
||||
closeSpi(fileDescriptor, gpioId, &gpioIF, mutex);
|
||||
usleep(RwDefinitions::SPI_REPLY_DELAY);
|
||||
usleep(rws::SPI_REPLY_DELAY);
|
||||
result = openSpi(dev, O_RDWR, &gpioIF, gpioId, mutex, timeoutType, timeoutMs, fileDescriptor);
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
@ -139,17 +139,17 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
* However, receiving more than 5 empty frames will be interpreted as an error.
|
||||
*/
|
||||
uint8_t byteRead = 0;
|
||||
for (int idx = 0; idx < 10; idx++) {
|
||||
for (idx = 0; idx < 10; idx++) {
|
||||
if (read(fileDescriptor, &byteRead, 1) != 1) {
|
||||
sif::error << "rwSpiCallback::spiCallback: Read failed" << std::endl;
|
||||
closeSpi(fileDescriptor, gpioId, &gpioIF, mutex);
|
||||
return RwHandler::SPI_READ_FAILURE;
|
||||
return rws::SPI_READ_FAILURE;
|
||||
}
|
||||
if (idx == 0) {
|
||||
if (byteRead != FLAG_BYTE) {
|
||||
sif::error << "Invalid data, expected start marker" << std::endl;
|
||||
closeSpi(fileDescriptor, gpioId, &gpioIF, mutex);
|
||||
return RwHandler::NO_START_MARKER;
|
||||
return rws::NO_START_MARKER;
|
||||
}
|
||||
}
|
||||
|
||||
@ -160,7 +160,7 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
if (idx == 9) {
|
||||
sif::error << "rwSpiCallback::spiCallback: Empty frame timeout" << std::endl;
|
||||
closeSpi(fileDescriptor, gpioId, &gpioIF, mutex);
|
||||
return RwHandler::NO_REPLY;
|
||||
return rws::NO_REPLY;
|
||||
}
|
||||
}
|
||||
|
||||
@ -175,7 +175,7 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
byteRead = 0;
|
||||
if (read(fileDescriptor, &byteRead, 1) != 1) {
|
||||
sif::error << "rwSpiCallback::spiCallback: Read failed" << std::endl;
|
||||
result = RwHandler::SPI_READ_FAILURE;
|
||||
result = rws::SPI_READ_FAILURE;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@ -186,7 +186,7 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
} else if (byteRead == 0x7D) {
|
||||
if (read(fileDescriptor, &byteRead, 1) != 1) {
|
||||
sif::error << "rwSpiCallback::spiCallback: Read failed" << std::endl;
|
||||
result = RwHandler::SPI_READ_FAILURE;
|
||||
result = rws::SPI_READ_FAILURE;
|
||||
break;
|
||||
}
|
||||
if (byteRead == 0x5E) {
|
||||
@ -200,7 +200,7 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
} else {
|
||||
sif::error << "rwSpiCallback::spiCallback: Invalid substitute" << std::endl;
|
||||
closeSpi(fileDescriptor, gpioId, &gpioIF, mutex);
|
||||
result = RwHandler::INVALID_SUBSTITUTE;
|
||||
result = rws::INVALID_SUBSTITUTE;
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
@ -217,14 +217,14 @@ ReturnValue_t spiCallback(SpiComIF* comIf, SpiCookie* cookie, const uint8_t* sen
|
||||
if (decodedFrameLen == replyBufferSize) {
|
||||
if (read(fileDescriptor, &byteRead, 1) != 1) {
|
||||
sif::error << "rwSpiCallback::spiCallback: Failed to read last byte" << std::endl;
|
||||
result = RwHandler::SPI_READ_FAILURE;
|
||||
result = rws::SPI_READ_FAILURE;
|
||||
break;
|
||||
}
|
||||
if (byteRead != FLAG_BYTE) {
|
||||
sif::error << "rwSpiCallback::spiCallback: Missing end sign " << static_cast<int>(FLAG_BYTE)
|
||||
<< std::endl;
|
||||
decodedFrameLen--;
|
||||
result = RwHandler::MISSING_END_SIGN;
|
||||
result = rws::MISSING_END_SIGN;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
target_sources(${OBSW_NAME} PRIVATE CoreController.cpp scheduling.cpp
|
||||
ObjectFactory.cpp)
|
||||
ObjectFactory.cpp WatchdogHandler.cpp)
|
||||
|
||||
target_sources(${SIMPLE_OBSW_NAME} PRIVATE scheduling.cpp)
|
||||
|
@ -5,7 +5,7 @@
|
||||
#include <fsfw/ipc/QueueFactory.h>
|
||||
#include <fsfw/tasks/TaskFactory.h>
|
||||
|
||||
#include "OBSWVersion.h"
|
||||
#include "commonConfig.h"
|
||||
#include "fsfw/serviceinterface/ServiceInterface.h"
|
||||
#include "fsfw/timemanager/Stopwatch.h"
|
||||
#include "fsfw/version.h"
|
||||
@ -31,14 +31,17 @@
|
||||
xsc::Chip CoreController::CURRENT_CHIP = xsc::Chip::NO_CHIP;
|
||||
xsc::Copy CoreController::CURRENT_COPY = xsc::Copy::NO_COPY;
|
||||
|
||||
CoreController::CoreController(object_id_t objectId)
|
||||
: ExtendedControllerBase(objectId, 5), opDivider5(5), opDivider10(10), hkSet(this) {
|
||||
ReturnValue_t result = returnvalue::OK;
|
||||
CoreController::CoreController(object_id_t objectId, const std::atomic_uint16_t &i2cErrors)
|
||||
: ExtendedControllerBase(objectId, 5),
|
||||
cmdExecutor(4096),
|
||||
cmdReplyBuf(4096, true),
|
||||
cmdRepliesSizes(128),
|
||||
opDivider5(5),
|
||||
opDivider10(10),
|
||||
hkSet(this),
|
||||
i2cErrors(i2cErrors) {
|
||||
cmdExecutor.setRingBuffer(&cmdReplyBuf, &cmdRepliesSizes);
|
||||
try {
|
||||
result = initWatchdogFifo();
|
||||
if (result != returnvalue::OK) {
|
||||
sif::warning << "CoreController::CoreController: Watchdog FIFO init failed" << std::endl;
|
||||
}
|
||||
sdcMan = SdCardManager::instance();
|
||||
if (sdcMan == nullptr) {
|
||||
sif::error << "CoreController::CoreController: SD card manager invalid!" << std::endl;
|
||||
@ -47,11 +50,37 @@ CoreController::CoreController(object_id_t objectId)
|
||||
if (not BLOCKING_SD_INIT) {
|
||||
sdcMan->setBlocking(false);
|
||||
}
|
||||
// Set up state of SD card manager and own initial state.
|
||||
// Stopwatch watch;
|
||||
sdcMan->updateSdCardStateFile();
|
||||
sdcMan->updateSdStatePair();
|
||||
SdCardManager::SdStatePair sdStates;
|
||||
sdcMan->getSdCardsStatus(sdStates);
|
||||
auto sdCard = sdcMan->getPreferredSdCard();
|
||||
if (not sdCard.has_value()) {
|
||||
sif::error << "CoreController::initializeAfterTaskCreation: "
|
||||
"Issues getting preferred SD card, setting to 0"
|
||||
<< std::endl;
|
||||
sdCard = sd::SdCard::SLOT_0;
|
||||
}
|
||||
sdInfo.active = sdCard.value();
|
||||
if (sdStates.first == sd::SdState::MOUNTED) {
|
||||
sdcMan->setActiveSdCard(sd::SdCard::SLOT_0);
|
||||
} else if (sdStates.second == sd::SdState::MOUNTED) {
|
||||
sdcMan->setActiveSdCard(sd::SdCard::SLOT_1);
|
||||
}
|
||||
currMntPrefix = sdcMan->getCurrentMountPrefix();
|
||||
|
||||
getCurrentBootCopy(CURRENT_CHIP, CURRENT_COPY);
|
||||
|
||||
initClockFromTimeFile();
|
||||
} catch (const std::filesystem::filesystem_error &e) {
|
||||
sif::error << "CoreController::CoreController: Failed with exception " << e.what() << std::endl;
|
||||
}
|
||||
// Add script folder to path
|
||||
char *currentEnvPath = getenv("PATH");
|
||||
std::string updatedEnvPath = std::string(currentEnvPath) + ":/home/root/scripts:/usr/local/bin";
|
||||
setenv("PATH", updatedEnvPath.c_str(), true);
|
||||
sdCardCheckCd.timeOut();
|
||||
eventQueue = QueueFactory::instance()->createMessageQueue(5, EventMessage::MAX_MESSAGE_SIZE);
|
||||
}
|
||||
@ -63,6 +92,9 @@ ReturnValue_t CoreController::handleCommandMessage(CommandMessage *message) {
|
||||
}
|
||||
|
||||
void CoreController::performControlOperation() {
|
||||
#if OBSW_THREAD_TRACING == 1
|
||||
trace::threadTrace(opCounter, "CORE CTRL");
|
||||
#endif
|
||||
EventMessage event;
|
||||
for (ReturnValue_t result = eventQueue->receiveMessage(&event); result == returnvalue::OK;
|
||||
result = eventQueue->receiveMessage(&event)) {
|
||||
@ -73,20 +105,28 @@ void CoreController::performControlOperation() {
|
||||
}
|
||||
}
|
||||
}
|
||||
performWatchdogControlOperation();
|
||||
sdStateMachine();
|
||||
performMountedSdCardOperations();
|
||||
if (sdCardCheckCd.hasTimedOut()) {
|
||||
if (shortSdCardCdCounter < 2) {
|
||||
shortSdCardCdCounter++;
|
||||
}
|
||||
if (shortSdCardCdCounter == 2) {
|
||||
sdCardCheckCd.setTimeout(DEFAULT_SD_CARD_CHECK_TIMEOUT);
|
||||
}
|
||||
performSdCardCheck();
|
||||
sdCardCheckCd.resetTimer();
|
||||
}
|
||||
readHkData();
|
||||
if (i2cErrors >= 5) {
|
||||
bool protOpPerformed = false;
|
||||
triggerEvent(I2C_UNAVAILABLE_REBOOT);
|
||||
gracefulShutdownTasks(CURRENT_CHIP, CURRENT_COPY, protOpPerformed);
|
||||
std::system("xsc_boot_copy -r");
|
||||
}
|
||||
if (shellCmdIsExecuting) {
|
||||
bool replyReceived = false;
|
||||
// TODO: We could read the data in the ring buffer and send it as an action data reply.
|
||||
if (cmdExecutor.check(replyReceived) == CommandExecutor::EXECUTION_FINISHED) {
|
||||
actionHelper.finish(true, successRecipient, EXECUTE_SHELL_CMD);
|
||||
shellCmdIsExecuting = false;
|
||||
cmdReplyBuf.clear();
|
||||
while (not cmdRepliesSizes.empty()) {
|
||||
cmdRepliesSizes.pop();
|
||||
}
|
||||
successRecipient = MessageQueueIF::NO_QUEUE;
|
||||
}
|
||||
}
|
||||
opDivider5.checkAndIncrement();
|
||||
opDivider10.checkAndIncrement();
|
||||
}
|
||||
@ -143,21 +183,8 @@ ReturnValue_t CoreController::initialize() {
|
||||
|
||||
ReturnValue_t CoreController::initializeAfterTaskCreation() {
|
||||
ReturnValue_t result = returnvalue::OK;
|
||||
auto sdCard = sdcMan->getPreferredSdCard();
|
||||
if (not sdCard) {
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
sdInfo.active = sdCard.value();
|
||||
if (sdInfo.active == sd::SdCard::NONE) {
|
||||
sif::error << "CoreController::initializeAfterTaskCreation: "
|
||||
"Issues getting preferred SD card, setting to 0"
|
||||
<< std::endl;
|
||||
sdInfo.active = sd::SdCard::SLOT_0;
|
||||
}
|
||||
sdcMan->setActiveSdCard(sdInfo.active);
|
||||
currMntPrefix = sdcMan->getCurrentMountPrefix();
|
||||
if (BLOCKING_SD_INIT) {
|
||||
ReturnValue_t result = initSdCardBlocking();
|
||||
result = initSdCardBlocking();
|
||||
if (result != returnvalue::OK and result != SdCardManager::ALREADY_MOUNTED) {
|
||||
sif::warning << "CoreController::CoreController: SD card init failed" << std::endl;
|
||||
}
|
||||
@ -167,18 +194,37 @@ ReturnValue_t CoreController::initializeAfterTaskCreation() {
|
||||
if (result != returnvalue::OK) {
|
||||
sif::warning << "CoreController::initialize: Version initialization failed" << std::endl;
|
||||
}
|
||||
// Add script folder to path
|
||||
char *currentEnvPath = getenv("PATH");
|
||||
std::string updatedEnvPath = std::string(currentEnvPath) + ":/home/root/scripts:/usr/local/bin";
|
||||
setenv("PATH", updatedEnvPath.c_str(), true);
|
||||
updateProtInfo();
|
||||
initPrint();
|
||||
return ExtendedControllerBase::initializeAfterTaskCreation();
|
||||
}
|
||||
|
||||
ReturnValue_t CoreController::executeAction(ActionId_t actionId, MessageQueueId_t commandedBy,
|
||||
const uint8_t *data, size_t size) {
|
||||
switch (actionId) {
|
||||
case (ANNOUNCE_VERSION): {
|
||||
uint32_t p1 = (common::OBSW_VERSION_MAJOR << 24) | (common::OBSW_VERSION_MINOR << 16) |
|
||||
(common::OBSW_VERSION_REVISION << 8);
|
||||
uint32_t p2 = 0;
|
||||
if (strcmp("", common::OBSW_VERSION_CST_GIT_SHA1) != 0) {
|
||||
p1 |= 1;
|
||||
auto shaAsStr = std::string(common::OBSW_VERSION_CST_GIT_SHA1);
|
||||
size_t posDash = shaAsStr.find("-");
|
||||
auto gitHash = shaAsStr.substr(posDash + 2, 4);
|
||||
// Only copy first 4 letters of git hash
|
||||
memcpy(&p2, gitHash.c_str(), 4);
|
||||
}
|
||||
|
||||
triggerEvent(VERSION_INFO, p1, p2);
|
||||
return HasActionsIF::EXECUTION_FINISHED;
|
||||
}
|
||||
case (ANNOUNCE_BOOT_COUNTS): {
|
||||
announceBootCounts();
|
||||
return HasActionsIF::EXECUTION_FINISHED;
|
||||
}
|
||||
case (ANNOUNCE_CURRENT_IMAGE): {
|
||||
triggerEvent(CURRENT_IMAGE_INFO, CURRENT_CHIP, CURRENT_COPY);
|
||||
return HasActionsIF::EXECUTION_FINISHED;
|
||||
}
|
||||
case (LIST_DIRECTORY_INTO_FILE): {
|
||||
return actionListDirectoryIntoFile(actionId, commandedBy, data, size);
|
||||
}
|
||||
@ -282,6 +328,21 @@ ReturnValue_t CoreController::executeAction(ActionId_t actionId, MessageQueueId_
|
||||
// Warning: This function will never return, because it reboots the system
|
||||
return actionReboot(data, size);
|
||||
}
|
||||
case (EXECUTE_SHELL_CMD): {
|
||||
std::string cmd = std::string(cmd, size);
|
||||
if (cmdExecutor.getCurrentState() == CommandExecutor::States::PENDING or
|
||||
shellCmdIsExecuting) {
|
||||
return HasActionsIF::IS_BUSY;
|
||||
}
|
||||
cmdExecutor.load(cmd, false, false);
|
||||
ReturnValue_t result = cmdExecutor.execute();
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
shellCmdIsExecuting = true;
|
||||
successRecipient = commandedBy;
|
||||
return returnvalue::OK;
|
||||
}
|
||||
default: {
|
||||
return HasActionsIF::INVALID_ACTION_ID;
|
||||
}
|
||||
@ -366,7 +427,7 @@ ReturnValue_t CoreController::sdStateMachine() {
|
||||
sdInfo.cycleCount = 0;
|
||||
return true;
|
||||
} else if (sdInfo.cycleCount > 4) {
|
||||
sif::warning << "CoreController::sdInitStateMachine: " << opPrintout << " takes too long"
|
||||
sif::warning << "CoreController::sdStateMachine: " << opPrintout << " takes too long"
|
||||
<< std::endl;
|
||||
return false;
|
||||
}
|
||||
@ -378,10 +439,12 @@ ReturnValue_t CoreController::sdStateMachine() {
|
||||
// Create updated status file
|
||||
result = sdcMan->updateSdCardStateFile();
|
||||
if (result != returnvalue::OK) {
|
||||
sif::warning << "CoreController::initialize: Updating SD card state file failed"
|
||||
sif::warning << "CoreController::sdStateMachine: Updating SD card state file failed"
|
||||
<< std::endl;
|
||||
}
|
||||
sdInfo.commandExecuted = true;
|
||||
sdFsmState = SdStates::SET_STATE_SELF;
|
||||
sdInfo.commandExecuted = false;
|
||||
sdInfo.cycleCount = 0;
|
||||
} else {
|
||||
nonBlockingOpChecking(SdStates::SET_STATE_SELF, 4, "Updating SDC file");
|
||||
}
|
||||
@ -524,10 +587,6 @@ ReturnValue_t CoreController::sdStateMachine() {
|
||||
if (sdFsmState == SdStates::SKIP_CYCLE_BEFORE_INFO_UPDATE) {
|
||||
sdFsmState = SdStates::UPDATE_INFO;
|
||||
} else if (sdFsmState == SdStates::UPDATE_INFO) {
|
||||
// It is assumed that all tasks are running by the point this section is reached.
|
||||
// Therefore, perform this operation in blocking mode because it does not take long
|
||||
// and the ready state of the SD card is available sooner
|
||||
sdcMan->setBlocking(true);
|
||||
// Update status file
|
||||
result = sdcMan->updateSdCardStateFile();
|
||||
if (result != returnvalue::OK) {
|
||||
@ -586,7 +645,8 @@ ReturnValue_t CoreController::sdCardSetup(sd::SdCard sdCard, sd::SdState targetS
|
||||
sif::info << "Unmounting SD card " << sdChar << std::endl;
|
||||
return sdcMan->unmountSdCard(sdCard);
|
||||
} else {
|
||||
if (std::filesystem::exists(mountString)) {
|
||||
std::error_code e;
|
||||
if (std::filesystem::exists(mountString, e)) {
|
||||
sif::info << "SD card " << sdChar << " already on and mounted at " << mountString
|
||||
<< std::endl;
|
||||
return SdCardManager::ALREADY_MOUNTED;
|
||||
@ -673,9 +733,9 @@ ReturnValue_t CoreController::initVersionFile() {
|
||||
sif::warning << "CoreController::versionFileInit: Retrieving uname line failed" << std::endl;
|
||||
}
|
||||
|
||||
std::string fullObswVersionString = "OBSW: v" + std::to_string(SW_VERSION) + "." +
|
||||
std::to_string(SW_SUBVERSION) + "." +
|
||||
std::to_string(SW_REVISION);
|
||||
std::string fullObswVersionString = "OBSW: v" + std::to_string(common::OBSW_VERSION_MAJOR) + "." +
|
||||
std::to_string(common::OBSW_VERSION_MINOR) + "." +
|
||||
std::to_string(common::OBSW_VERSION_REVISION);
|
||||
char versionString[16] = {};
|
||||
fsfw::FSFW_VERSION.getVersion(versionString, sizeof(versionString));
|
||||
std::string fullFsfwVersionString = "FSFW: v" + std::string(versionString);
|
||||
@ -683,7 +743,8 @@ ReturnValue_t CoreController::initVersionFile() {
|
||||
std::string versionFilePath = currMntPrefix + VERSION_FILE;
|
||||
std::fstream versionFile;
|
||||
|
||||
if (not std::filesystem::exists(versionFilePath)) {
|
||||
std::error_code e;
|
||||
if (not std::filesystem::exists(versionFilePath, e)) {
|
||||
sif::info << "Writing version file " << versionFilePath << ".." << std::endl;
|
||||
versionFile.open(versionFilePath, std::ios_base::out);
|
||||
versionFile << fullObswVersionString << std::endl;
|
||||
@ -795,7 +856,8 @@ ReturnValue_t CoreController::actionListDirectoryIntoFile(ActionId_t actionId,
|
||||
}
|
||||
|
||||
ReturnValue_t CoreController::initBootCopyFile() {
|
||||
if (not std::filesystem::exists(CURR_COPY_FILE)) {
|
||||
std::error_code e;
|
||||
if (not std::filesystem::exists(CURR_COPY_FILE, e)) {
|
||||
// This file is created by the systemd service eive-early-config so this should
|
||||
// not happen normally
|
||||
std::string cmd = "xsc_boot_copy > " + std::string(CURR_COPY_FILE);
|
||||
@ -816,36 +878,6 @@ void CoreController::getCurrentBootCopy(xsc::Chip &chip, xsc::Copy ©) {
|
||||
copy = static_cast<xsc::Copy>(xscCopy);
|
||||
}
|
||||
|
||||
ReturnValue_t CoreController::initWatchdogFifo() {
|
||||
if (not std::filesystem::exists(watchdog::FIFO_NAME)) {
|
||||
// Still return returnvalue::OK for now
|
||||
sif::info << "Watchdog FIFO " << watchdog::FIFO_NAME << " does not exist, can't initiate"
|
||||
<< " watchdog" << std::endl;
|
||||
return returnvalue::OK;
|
||||
}
|
||||
// Open FIFO write only and non-blocking to prevent SW from killing itself.
|
||||
watchdogFifoFd = open(watchdog::FIFO_NAME.c_str(), O_WRONLY | O_NONBLOCK);
|
||||
if (watchdogFifoFd < 0) {
|
||||
if (errno == ENXIO) {
|
||||
watchdogFifoFd = RETRY_FIFO_OPEN;
|
||||
sif::info << "eive-watchdog not running. FIFO can not be opened" << std::endl;
|
||||
} else {
|
||||
sif::error << "Opening pipe " << watchdog::FIFO_NAME << " write-only failed with " << errno
|
||||
<< ": " << strerror(errno) << std::endl;
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void CoreController::initPrint() {
|
||||
#if OBSW_VERBOSE_LEVEL >= 1
|
||||
if (watchdogFifoFd > 0) {
|
||||
sif::info << "Opened watchdog FIFO successfully.." << std::endl;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
ReturnValue_t CoreController::actionXscReboot(const uint8_t *data, size_t size) {
|
||||
if (size < 1) {
|
||||
return HasActionsIF::INVALID_PARAMETERS;
|
||||
@ -1129,7 +1161,8 @@ ReturnValue_t CoreController::updateProtInfo(bool regenerateChipStateFile) {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
if (not filesystem::exists(CHIP_STATE_FILE)) {
|
||||
std::error_code e;
|
||||
if (not filesystem::exists(CHIP_STATE_FILE, e)) {
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
ifstream chipStateFile(CHIP_STATE_FILE);
|
||||
@ -1140,7 +1173,7 @@ ReturnValue_t CoreController::updateProtInfo(bool regenerateChipStateFile) {
|
||||
uint8_t lineCounter = 0;
|
||||
string word;
|
||||
while (getline(chipStateFile, nextLine)) {
|
||||
ReturnValue_t result = handleProtInfoUpdateLine(nextLine);
|
||||
result = handleProtInfoUpdateLine(nextLine);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::warning << "CoreController::updateProtInfo: Protection info update failed!" << std::endl;
|
||||
return result;
|
||||
@ -1196,38 +1229,11 @@ ReturnValue_t CoreController::handleProtInfoUpdateLine(std::string nextLine) {
|
||||
}
|
||||
}
|
||||
wordIdx++;
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void CoreController::performWatchdogControlOperation() {
|
||||
// Only perform each fifth iteration
|
||||
if (watchdogFifoFd != 0 and opDivider5.check()) {
|
||||
if (watchdogFifoFd == RETRY_FIFO_OPEN) {
|
||||
// Open FIFO write only and non-blocking
|
||||
watchdogFifoFd = open(watchdog::FIFO_NAME.c_str(), O_WRONLY | O_NONBLOCK);
|
||||
if (watchdogFifoFd < 0) {
|
||||
if (errno == ENXIO) {
|
||||
watchdogFifoFd = RETRY_FIFO_OPEN;
|
||||
// No printout for now, would be spam
|
||||
return;
|
||||
} else {
|
||||
sif::error << "Opening pipe " << watchdog::FIFO_NAME << " write-only failed with "
|
||||
<< errno << ": " << strerror(errno) << std::endl;
|
||||
return;
|
||||
}
|
||||
}
|
||||
sif::info << "Opened " << watchdog::FIFO_NAME << " successfully" << std::endl;
|
||||
} else if (watchdogFifoFd > 0) {
|
||||
// Write to OBSW watchdog FIFO here
|
||||
const char writeChar = 'a';
|
||||
ssize_t writtenBytes = write(watchdogFifoFd, &writeChar, 1);
|
||||
if (writtenBytes < 0) {
|
||||
sif::error << "Errors writing to watchdog FIFO, code " << errno << ": " << strerror(errno)
|
||||
<< std::endl;
|
||||
}
|
||||
if (wordIdx >= 10) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void CoreController::performMountedSdCardOperations() {
|
||||
@ -1235,18 +1241,26 @@ void CoreController::performMountedSdCardOperations() {
|
||||
if (not performOneShotSdCardOpsSwitch) {
|
||||
std::ostringstream path;
|
||||
path << mntPoint << "/" << CONF_FOLDER;
|
||||
if (not std::filesystem::exists(path.str())) {
|
||||
std::filesystem::create_directory(path.str());
|
||||
std::error_code e;
|
||||
if (not std::filesystem::exists(path.str()), e) {
|
||||
bool created = std::filesystem::create_directory(path.str(), e);
|
||||
if (not created) {
|
||||
sif::error << "Could not create CONF folder at " << path.str() << ": " << e.message()
|
||||
<< std::endl;
|
||||
return;
|
||||
}
|
||||
}
|
||||
initVersionFile();
|
||||
ReturnValue_t result = initBootCopyFile();
|
||||
if (result != returnvalue::OK) {
|
||||
sif::warning << "CoreController::CoreController: Boot copy init" << std::endl;
|
||||
}
|
||||
initClockFromTimeFile();
|
||||
if (not timeFileInitDone) {
|
||||
initClockFromTimeFile();
|
||||
}
|
||||
performRebootFileHandling(false);
|
||||
}
|
||||
timeFileHandler();
|
||||
backupTimeFileHandler();
|
||||
};
|
||||
bool someSdCardActive = false;
|
||||
if (sdInfo.active == sd::SdCard::SLOT_0 and sdcMan->isSdCardUsable(sd::SdCard::SLOT_0)) {
|
||||
@ -1319,7 +1333,8 @@ ReturnValue_t CoreController::performSdCardCheck() {
|
||||
void CoreController::performRebootFileHandling(bool recreateFile) {
|
||||
using namespace std;
|
||||
std::string path = currMntPrefix + REBOOT_FILE;
|
||||
if (not std::filesystem::exists(path) or recreateFile) {
|
||||
std::error_code e;
|
||||
if (not std::filesystem::exists(path, e) or recreateFile) {
|
||||
#if OBSW_VERBOSE_LEVEL >= 1
|
||||
sif::info << "CoreController::performRebootFileHandling: Recreating reboot file" << std::endl;
|
||||
#endif
|
||||
@ -1361,13 +1376,13 @@ void CoreController::performRebootFileHandling(bool recreateFile) {
|
||||
if (rebootFile.bootFlag) {
|
||||
// Trigger event to inform ground that a reboot was triggered
|
||||
uint32_t p1 = rebootFile.lastChip << 16 | rebootFile.lastCopy;
|
||||
uint32_t p2 = rebootFile.img00Cnt << 24 | rebootFile.img01Cnt << 16 | rebootFile.img10Cnt << 8 |
|
||||
rebootFile.img11Cnt;
|
||||
triggerEvent(REBOOT_MECHANISM_TRIGGERED, p1, p2);
|
||||
triggerEvent(REBOOT_MECHANISM_TRIGGERED, p1, 0);
|
||||
// Clear the boot flag
|
||||
rebootFile.bootFlag = false;
|
||||
}
|
||||
|
||||
announceBootCounts();
|
||||
|
||||
if (rebootFile.mechanismNextChip != xsc::NO_CHIP and
|
||||
rebootFile.mechanismNextCopy != xsc::NO_COPY) {
|
||||
if (CURRENT_CHIP != rebootFile.mechanismNextChip or
|
||||
@ -1760,7 +1775,7 @@ void CoreController::setRebootMechanismLock(bool lock, xsc::Chip tgtChip, xsc::C
|
||||
rewriteRebootFile(rebootFile);
|
||||
}
|
||||
|
||||
ReturnValue_t CoreController::timeFileHandler() {
|
||||
ReturnValue_t CoreController::backupTimeFileHandler() {
|
||||
// Always set time. We could only set it if it is updated by GPS, but then the backup time would
|
||||
// become obsolete on GPS problems.
|
||||
if (opDivider10.check()) {
|
||||
@ -1770,14 +1785,14 @@ ReturnValue_t CoreController::timeFileHandler() {
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
std::string fileName = currMntPrefix + TIME_FILE;
|
||||
std::string fileName = currMntPrefix + BACKUP_TIME_FILE;
|
||||
std::ofstream timeFile(fileName);
|
||||
if (not timeFile.good()) {
|
||||
sif::error << "CoreController::timeFileHandler: Error opening time file: " << strerror(errno)
|
||||
<< std::endl;
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
timeFile << "UNIX SECONDS: " << currentTime.tv_sec << std::endl;
|
||||
timeFile << "UNIX SECONDS: " << currentTime.tv_sec + BOOT_OFFSET_SECONDS << std::endl;
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
@ -1785,8 +1800,9 @@ ReturnValue_t CoreController::timeFileHandler() {
|
||||
ReturnValue_t CoreController::initClockFromTimeFile() {
|
||||
using namespace GpsHyperion;
|
||||
using namespace std;
|
||||
std::string fileName = currMntPrefix + TIME_FILE;
|
||||
if (std::filesystem::exists(fileName) and
|
||||
std::string fileName = currMntPrefix + BACKUP_TIME_FILE;
|
||||
std::error_code e;
|
||||
if (sdcMan->isSdCardUsable(std::nullopt) and std::filesystem::exists(fileName, e) and
|
||||
((gpsFix == FixMode::UNKNOWN or gpsFix == FixMode::NOT_SEEN) or
|
||||
not utility::timeSanityCheck())) {
|
||||
ifstream timeFile(fileName);
|
||||
@ -1814,6 +1830,7 @@ ReturnValue_t CoreController::initClockFromTimeFile() {
|
||||
sif::info << "Setting system time from time files: " << std::put_time(time, "%c %Z")
|
||||
<< std::endl;
|
||||
#endif
|
||||
timeFileInitDone = true;
|
||||
return Clock::setClock(¤tTime);
|
||||
}
|
||||
return returnvalue::OK;
|
||||
@ -1910,7 +1927,8 @@ ReturnValue_t CoreController::executeSwUpdate(SwUpdateSources sourceDir, const u
|
||||
prefixPath = path("/tmp");
|
||||
}
|
||||
path archivePath = prefixPath / path(config::OBSW_UPDATE_ARCHIVE_FILE_NAME);
|
||||
if (not exists(archivePath)) {
|
||||
std::error_code e;
|
||||
if (not exists(archivePath, e)) {
|
||||
return HasFileSystemIF::FILE_DOES_NOT_EXIST;
|
||||
}
|
||||
ostringstream cmd("tar -xJf", ios::app);
|
||||
@ -1920,12 +1938,12 @@ ReturnValue_t CoreController::executeSwUpdate(SwUpdateSources sourceDir, const u
|
||||
utility::handleSystemError(result, "CoreController::executeAction: SW Update Decompression");
|
||||
}
|
||||
path strippedImagePath = prefixPath / path(config::STRIPPED_OBSW_BINARY_FILE_NAME);
|
||||
if (!exists(strippedImagePath)) {
|
||||
if (!exists(strippedImagePath, e)) {
|
||||
// TODO: Custom returnvalue?
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
path obswVersionFilePath = prefixPath / path(config::OBSW_VERSION_FILE_NAME);
|
||||
if (!exists(obswVersionFilePath)) {
|
||||
if (!exists(obswVersionFilePath, e)) {
|
||||
// TODO: Custom returnvalue?
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
@ -2022,6 +2040,15 @@ bool CoreController::startSdStateMachine(sd::SdCard targetActiveSd, SdCfgMode mo
|
||||
return true;
|
||||
}
|
||||
|
||||
void CoreController::announceBootCounts() {
|
||||
uint64_t totalBootCount =
|
||||
rebootFile.img00Cnt + rebootFile.img01Cnt + rebootFile.img10Cnt + rebootFile.img11Cnt;
|
||||
uint32_t individualBootCountsP1 = (rebootFile.img00Cnt << 16) | rebootFile.img01Cnt;
|
||||
uint32_t individualBootCountsP2 = (rebootFile.img10Cnt << 16) | rebootFile.img11Cnt;
|
||||
triggerEvent(INDIVIDUAL_BOOT_COUNTS, individualBootCountsP1, individualBootCountsP2);
|
||||
triggerEvent(REBOOT_COUNTER, (totalBootCount >> 32) & 0xffffffff, totalBootCount & 0xffffffff);
|
||||
}
|
||||
|
||||
bool CoreController::isNumber(const std::string &s) {
|
||||
return !s.empty() && std::find_if(s.begin(), s.end(),
|
||||
[](unsigned char c) { return !std::isdigit(c); }) == s.end();
|
||||
|
@ -1,9 +1,12 @@
|
||||
#ifndef BSP_Q7S_CORE_CORECONTROLLER_H_
|
||||
#define BSP_Q7S_CORE_CORECONTROLLER_H_
|
||||
|
||||
#include <fsfw/container/DynamicFIFO.h>
|
||||
#include <fsfw/container/SimpleRingBuffer.h>
|
||||
#include <fsfw/globalfunctions/PeriodicOperationDivider.h>
|
||||
#include <libxiphos.h>
|
||||
|
||||
#include <atomic>
|
||||
#include <cstddef>
|
||||
|
||||
#include "CoreDefinitions.h"
|
||||
@ -12,6 +15,7 @@
|
||||
#include "events/subsystemIdRanges.h"
|
||||
#include "fsfw/controller/ExtendedControllerBase.h"
|
||||
#include "mission/devices/devicedefinitions/GPSDefinitions.h"
|
||||
#include "mission/trace.h"
|
||||
|
||||
class Timer;
|
||||
class SdCardManager;
|
||||
@ -57,13 +61,14 @@ class CoreController : public ExtendedControllerBase {
|
||||
|
||||
static constexpr char VERSION_FILE_NAME[] = "version.txt";
|
||||
static constexpr char REBOOT_FILE_NAME[] = "reboot.txt";
|
||||
static constexpr char TIME_FILE_NAME[] = "time.txt";
|
||||
static constexpr char TIME_FILE_NAME[] = "time_backup.txt";
|
||||
|
||||
const std::string VERSION_FILE =
|
||||
"/" + std::string(CONF_FOLDER) + "/" + std::string(VERSION_FILE_NAME);
|
||||
const std::string REBOOT_FILE =
|
||||
"/" + std::string(CONF_FOLDER) + "/" + std::string(REBOOT_FILE_NAME);
|
||||
const std::string TIME_FILE = "/" + std::string(CONF_FOLDER) + "/" + std::string(TIME_FILE_NAME);
|
||||
const std::string BACKUP_TIME_FILE =
|
||||
"/" + std::string(CONF_FOLDER) + "/" + std::string(TIME_FILE_NAME);
|
||||
|
||||
static constexpr char CHIP_0_COPY_0_MOUNT_DIR[] = "/tmp/mntupdate-xdi-qspi0-nom-rootfs";
|
||||
static constexpr char CHIP_0_COPY_1_MOUNT_DIR[] = "/tmp/mntupdate-xdi-qspi0-gold-rootfs";
|
||||
@ -74,6 +79,9 @@ class CoreController : public ExtendedControllerBase {
|
||||
static constexpr dur_millis_t DEFAULT_SD_CARD_CHECK_TIMEOUT = 60000;
|
||||
|
||||
static constexpr ActionId_t LIST_DIRECTORY_INTO_FILE = 0;
|
||||
static constexpr ActionId_t ANNOUNCE_VERSION = 1;
|
||||
static constexpr ActionId_t ANNOUNCE_CURRENT_IMAGE = 2;
|
||||
static constexpr ActionId_t ANNOUNCE_BOOT_COUNTS = 3;
|
||||
static constexpr ActionId_t SWITCH_REBOOT_FILE_HANDLING = 5;
|
||||
static constexpr ActionId_t RESET_REBOOT_COUNTERS = 6;
|
||||
static constexpr ActionId_t SWITCH_IMG_LOCK = 7;
|
||||
@ -93,12 +101,14 @@ class CoreController : public ExtendedControllerBase {
|
||||
//! Reboot using the reboot command
|
||||
static constexpr ActionId_t REBOOT_OBC = 34;
|
||||
|
||||
static constexpr ActionId_t EXECUTE_SHELL_CMD = 40;
|
||||
|
||||
static constexpr uint8_t SUBSYSTEM_ID = SUBSYSTEM_ID::CORE;
|
||||
|
||||
static constexpr Event ALLOC_FAILURE = event::makeEvent(SUBSYSTEM_ID, 0, severity::MEDIUM);
|
||||
//! [EXPORT] : [COMMENT] Software reboot occurred. Can also be a systemd reboot.
|
||||
//! P1: Current Chip, P2: Current Copy
|
||||
static constexpr Event REBOOT_SW = event::makeEvent(SUBSYSTEM_ID, 1, severity::MEDIUM);
|
||||
static constexpr Event REBOOT_SW = event::makeEvent(SUBSYSTEM_ID, 1, severity::LOW);
|
||||
//! [EXPORT] : [COMMENT] The reboot mechanism was triggered.
|
||||
//! P1: First 16 bits: Last Chip, Last 16 bits: Last Copy,
|
||||
//! P2: Each byte is the respective reboot count for the slots
|
||||
@ -109,8 +119,23 @@ class CoreController : public ExtendedControllerBase {
|
||||
//! [EXPORT] : [COMMENT] No SD card was active. Core controller will attempt to re-initialize
|
||||
//! a SD card.
|
||||
static constexpr Event NO_SD_CARD_ACTIVE = event::makeEvent(SUBSYSTEM_ID, 4, severity::HIGH);
|
||||
//! [EXPORT] : [COMMENT]
|
||||
//! P1: Byte 0: Major, Byte 1: Minor, Byte 2: Patch, Byte 3: Has Git Hash
|
||||
//! P2: First four letters of Git SHA is the last byte of P1 is set.
|
||||
static constexpr Event VERSION_INFO = event::makeEvent(SUBSYSTEM_ID, 5, severity::INFO);
|
||||
//! [EXPORT] : [COMMENT] P1: Current Chip, P2: Current Copy
|
||||
static constexpr Event CURRENT_IMAGE_INFO = event::makeEvent(SUBSYSTEM_ID, 6, severity::INFO);
|
||||
//! [EXPORT] : [COMMENT] Total reboot counter, which is the sum of the boot count of all
|
||||
//! individual images.
|
||||
static constexpr Event REBOOT_COUNTER = event::makeEvent(SUBSYSTEM_ID, 7, severity::INFO);
|
||||
//! [EXPORT] : [COMMENT] Get the boot count of the individual images.
|
||||
//! P1: First 16 bits boot count of image 0 0, last 16 bits boot count of image 0 1.
|
||||
//! P2: First 16 bits boot count of image 1 0, last 16 bits boot count of image 1 1.
|
||||
static constexpr Event INDIVIDUAL_BOOT_COUNTS = event::makeEvent(SUBSYSTEM_ID, 8, severity::INFO);
|
||||
static constexpr Event I2C_UNAVAILABLE_REBOOT =
|
||||
event::makeEvent(SUBSYSTEM_ID, 10, severity::MEDIUM);
|
||||
|
||||
CoreController(object_id_t objectId);
|
||||
CoreController(object_id_t objectId, const std::atomic_uint16_t& i2cErrors);
|
||||
virtual ~CoreController();
|
||||
|
||||
ReturnValue_t initialize() override;
|
||||
@ -151,11 +176,9 @@ class CoreController : public ExtendedControllerBase {
|
||||
bool sdInitFinished() const;
|
||||
|
||||
private:
|
||||
static constexpr uint32_t BOOT_OFFSET_SECONDS = 15;
|
||||
static constexpr MutexIF::TimeoutType TIMEOUT_TYPE = MutexIF::TimeoutType::WAITING;
|
||||
static constexpr uint32_t MUTEX_TIMEOUT = 20;
|
||||
// Designated value for rechecking FIFO open
|
||||
static constexpr int RETRY_FIFO_OPEN = -2;
|
||||
int watchdogFifoFd = 0;
|
||||
GpsHyperion::FixMode gpsFix = GpsHyperion::FixMode::UNKNOWN;
|
||||
|
||||
// States for SD state machine, which is used in non-blocking mode
|
||||
@ -211,9 +234,20 @@ class CoreController : public ExtendedControllerBase {
|
||||
} sdCommandingInfo;
|
||||
|
||||
RebootFile rebootFile = {};
|
||||
|
||||
CommandExecutor cmdExecutor;
|
||||
SimpleRingBuffer cmdReplyBuf;
|
||||
DynamicFIFO<uint16_t> cmdRepliesSizes;
|
||||
bool shellCmdIsExecuting = false;
|
||||
MessageQueueId_t successRecipient = MessageQueueIF::NO_QUEUE;
|
||||
|
||||
std::string currMntPrefix;
|
||||
bool timeFileInitDone = false;
|
||||
bool performOneShotSdCardOpsSwitch = false;
|
||||
uint8_t shortSdCardCdCounter = 0;
|
||||
#if OBSW_THREAD_TRACING == 1
|
||||
uint32_t opCounter;
|
||||
#endif
|
||||
Countdown sdCardCheckCd = Countdown(INIT_SD_CARD_CHECK_TIMEOUT);
|
||||
|
||||
/**
|
||||
@ -231,6 +265,7 @@ class CoreController : public ExtendedControllerBase {
|
||||
PoolEntry<float> plVoltageEntry = PoolEntry<float>(0.0);
|
||||
|
||||
core::HkSet hkSet;
|
||||
const std::atomic_uint16_t& i2cErrors;
|
||||
|
||||
#if OBSW_SD_CARD_MUST_BE_ON == 1
|
||||
bool remountAttemptFlag = true;
|
||||
@ -246,9 +281,8 @@ class CoreController : public ExtendedControllerBase {
|
||||
|
||||
ReturnValue_t initClockFromTimeFile();
|
||||
ReturnValue_t performSdCardCheck();
|
||||
ReturnValue_t timeFileHandler();
|
||||
ReturnValue_t backupTimeFileHandler();
|
||||
ReturnValue_t initBootCopyFile();
|
||||
ReturnValue_t initWatchdogFifo();
|
||||
ReturnValue_t initSdCardBlocking();
|
||||
bool startSdStateMachine(sd::SdCard targetActiveSd, SdCfgMode mode, MessageQueueId_t commander,
|
||||
DeviceCommandId_t actionId);
|
||||
@ -273,8 +307,6 @@ class CoreController : public ExtendedControllerBase {
|
||||
|
||||
ReturnValue_t gracefulShutdownTasks(xsc::Chip chip, xsc::Copy copy, bool& protOpPerformed);
|
||||
|
||||
void performWatchdogControlOperation();
|
||||
|
||||
ReturnValue_t handleProtInfoUpdateLine(std::string nextLine);
|
||||
int handleBootCopyProtAtIndex(xsc::Chip targetChip, xsc::Copy targetCopy, bool protect,
|
||||
bool& protOperationPerformed, bool selfChip, bool selfCopy,
|
||||
@ -285,6 +317,7 @@ class CoreController : public ExtendedControllerBase {
|
||||
void setRebootMechanismLock(bool lock, xsc::Chip tgtChip, xsc::Copy tgtCopy);
|
||||
bool parseRebootFile(std::string path, RebootFile& file);
|
||||
void rewriteRebootFile(RebootFile file);
|
||||
void announceBootCounts();
|
||||
void readHkData();
|
||||
bool isNumber(const std::string& s);
|
||||
};
|
||||
|
@ -1,7 +1,20 @@
|
||||
#include "ObjectFactory.h"
|
||||
|
||||
#include <fsfw/subsystem/Subsystem.h>
|
||||
#include <linux/devices/AcsBoardPolling.h>
|
||||
#include <linux/devices/ImtqPollingTask.h>
|
||||
#include <linux/devices/RwPollingTask.h>
|
||||
#include <mission/devices/GyrL3gCustomHandler.h>
|
||||
#include <mission/devices/MgmLis3CustomHandler.h>
|
||||
#include <mission/devices/MgmRm3100CustomHandler.h>
|
||||
#include <mission/system/fdir/StrFdir.h>
|
||||
#include <mission/system/objects/CamSwitcher.h>
|
||||
#include <mission/system/objects/ImtqAssembly.h>
|
||||
#include <mission/system/objects/StrAssembly.h>
|
||||
#include <mission/system/objects/SyrlinksAssembly.h>
|
||||
#include <mission/tmtc/LiveTmTask.h>
|
||||
#include <mission/tmtc/PersistentLogTmStoreTask.h>
|
||||
#include <mission/tmtc/PersistentSingleTmStoreTask.h>
|
||||
|
||||
#include "OBSWConfig.h"
|
||||
#include "bsp_q7s/boardtest/Q7STestTask.h"
|
||||
@ -23,7 +36,7 @@
|
||||
#include "linux/boardtest/UartTestClass.h"
|
||||
#include "linux/callbacks/gpioCallbacks.h"
|
||||
#include "linux/csp/CspComIF.h"
|
||||
#include "linux/devices/GPSHyperionLinuxController.h"
|
||||
#include "linux/devices/GpsHyperionLinuxController.h"
|
||||
#include "linux/devices/ScexUartReader.h"
|
||||
#include "linux/devices/devicedefinitions/PlocMPSoCDefinitions.h"
|
||||
#include "linux/devices/devicedefinitions/StarTrackerDefinitions.h"
|
||||
@ -38,6 +51,7 @@
|
||||
#include "linux/ipcore/PdecHandler.h"
|
||||
#include "linux/ipcore/Ptme.h"
|
||||
#include "linux/ipcore/PtmeConfig.h"
|
||||
#include "mission/config/configfile.h"
|
||||
#include "mission/csp/CspCookie.h"
|
||||
#include "mission/system/fdir/AcsBoardFdir.h"
|
||||
#include "mission/system/fdir/GomspacePowerFdir.h"
|
||||
@ -51,13 +65,23 @@
|
||||
#include "mission/system/tree/comModeTree.h"
|
||||
#include "mission/system/tree/payloadModeTree.h"
|
||||
#include "mission/system/tree/tcsModeTree.h"
|
||||
#include "mission/tmtc/tmFilters.h"
|
||||
#include "mission/utility/GlobalConfigHandler.h"
|
||||
#include "tmtc/pusIds.h"
|
||||
|
||||
using gpio::Direction;
|
||||
using gpio::Levels;
|
||||
#if OBSW_TEST_LIBGPIOD == 1
|
||||
#include "linux/boardtest/LibgpiodTest.h"
|
||||
#endif
|
||||
#include <mission/devices/GyrAdis1650XHandler.h>
|
||||
#include <mission/devices/ImtqHandler.h>
|
||||
#include <mission/devices/PcduHandler.h>
|
||||
#include <mission/devices/Pdu1Handler.h>
|
||||
#include <mission/devices/Pdu2Handler.h>
|
||||
#include <mission/devices/SyrlinksHandler.h>
|
||||
#include <mission/devices/devicedefinitions/rwHelpers.h>
|
||||
#include <mission/tmtc/VirtualChannelWithQueue.h>
|
||||
|
||||
#include <sstream>
|
||||
|
||||
@ -80,12 +104,9 @@
|
||||
#include "mission/core/GenericFactory.h"
|
||||
#include "mission/devices/ACUHandler.h"
|
||||
#include "mission/devices/BpxBatteryHandler.h"
|
||||
#include "mission/devices/GyroADIS1650XHandler.h"
|
||||
#include "mission/devices/HeaterHandler.h"
|
||||
#include "mission/devices/Max31865PT1000Handler.h"
|
||||
#include "mission/devices/P60DockHandler.h"
|
||||
#include "mission/devices/PDU1Handler.h"
|
||||
#include "mission/devices/PDU2Handler.h"
|
||||
#include "mission/devices/PayloadPcduHandler.h"
|
||||
#include "mission/devices/RadiationSensorHandler.h"
|
||||
#include "mission/devices/RwHandler.h"
|
||||
@ -94,15 +115,15 @@
|
||||
#include "mission/devices/devicedefinitions/GomspaceDefinitions.h"
|
||||
#include "mission/devices/devicedefinitions/Max31865Definitions.h"
|
||||
#include "mission/devices/devicedefinitions/RadSensorDefinitions.h"
|
||||
#include "mission/devices/devicedefinitions/RwDefinitions.h"
|
||||
#include "mission/devices/devicedefinitions/SyrlinksDefinitions.h"
|
||||
#include "mission/devices/devicedefinitions/payloadPcduDefinitions.h"
|
||||
#include "mission/system/objects/AcsBoardAssembly.h"
|
||||
#include "mission/tmtc/CcsdsIpCoreHandler.h"
|
||||
#include "mission/tmtc/TmFunnelHandler.h"
|
||||
#include "mission/tmtc/VirtualChannel.h"
|
||||
|
||||
ResetArgs RESET_ARGS_GNSS;
|
||||
std::atomic_bool LINK_STATE = CcsdsIpCoreHandler::LINK_DOWN;
|
||||
std::atomic_uint16_t I2C_FATAL_ERRORS = 0;
|
||||
|
||||
void Factory::setStaticFrameworkObjectIds() {
|
||||
PusServiceBase::PUS_DISTRIBUTOR = objects::PUS_PACKET_DISTRIBUTOR;
|
||||
@ -150,9 +171,8 @@ void ObjectFactory::createTmpComponents() {
|
||||
|
||||
void ObjectFactory::createCommunicationInterfaces(LinuxLibgpioIF** gpioComIF,
|
||||
SerialComIF** uartComIF, SpiComIF** spiMainComIF,
|
||||
I2cComIF** i2cComIF, SpiComIF** spiRWComIF) {
|
||||
if (gpioComIF == nullptr or uartComIF == nullptr or spiMainComIF == nullptr or
|
||||
spiRWComIF == nullptr) {
|
||||
I2cComIF** i2cComIF) {
|
||||
if (gpioComIF == nullptr or uartComIF == nullptr or spiMainComIF == nullptr) {
|
||||
sif::error << "ObjectFactory::createCommunicationInterfaces: Invalid passed ComIF pointer"
|
||||
<< std::endl;
|
||||
}
|
||||
@ -163,7 +183,7 @@ void ObjectFactory::createCommunicationInterfaces(LinuxLibgpioIF** gpioComIF,
|
||||
*i2cComIF = new I2cComIF(objects::I2C_COM_IF);
|
||||
*uartComIF = new SerialComIF(objects::UART_COM_IF);
|
||||
*spiMainComIF = new SpiComIF(objects::SPI_MAIN_COM_IF, q7s::SPI_DEFAULT_DEV, **gpioComIF);
|
||||
*spiRWComIF = new SpiComIF(objects::SPI_RW_COM_IF, q7s::SPI_RW_DEV, **gpioComIF);
|
||||
//*spiRWComIF = new SpiComIF(objects::SPI_RW_COM_IF, q7s::SPI_RW_DEV, **gpioComIF);
|
||||
}
|
||||
|
||||
void ObjectFactory::createPcduComponents(LinuxLibgpioIF* gpioComIF, PowerSwitchIF** pwrSwitcher) {
|
||||
@ -177,17 +197,17 @@ void ObjectFactory::createPcduComponents(LinuxLibgpioIF* gpioComIF, PowerSwitchI
|
||||
new P60DockHandler(objects::P60DOCK_HANDLER, objects::CSP_COM_IF, p60DockCspCookie, p60Fdir);
|
||||
|
||||
auto pdu1Fdir = new GomspacePowerFdir(objects::PDU1_HANDLER);
|
||||
PDU1Handler* pdu1handler =
|
||||
new PDU1Handler(objects::PDU1_HANDLER, objects::CSP_COM_IF, pdu1CspCookie, pdu1Fdir);
|
||||
Pdu1Handler* pdu1handler =
|
||||
new Pdu1Handler(objects::PDU1_HANDLER, objects::CSP_COM_IF, pdu1CspCookie, pdu1Fdir);
|
||||
|
||||
auto pdu2Fdir = new GomspacePowerFdir(objects::PDU2_HANDLER);
|
||||
PDU2Handler* pdu2handler =
|
||||
new PDU2Handler(objects::PDU2_HANDLER, objects::CSP_COM_IF, pdu2CspCookie, pdu2Fdir);
|
||||
Pdu2Handler* pdu2handler =
|
||||
new Pdu2Handler(objects::PDU2_HANDLER, objects::CSP_COM_IF, pdu2CspCookie, pdu2Fdir);
|
||||
|
||||
auto acuFdir = new GomspacePowerFdir(objects::ACU_HANDLER);
|
||||
ACUHandler* acuhandler =
|
||||
new ACUHandler(objects::ACU_HANDLER, objects::CSP_COM_IF, acuCspCookie, acuFdir);
|
||||
auto pcduHandler = new PCDUHandler(objects::PCDU_HANDLER, 50);
|
||||
auto pcduHandler = new PcduHandler(objects::PCDU_HANDLER, 50);
|
||||
|
||||
/**
|
||||
* Setting PCDU devices to mode normal immediately after start up because PCDU is always
|
||||
@ -238,120 +258,127 @@ ReturnValue_t ObjectFactory::createRadSensorComponent(LinuxLibgpioIF* gpioComIF,
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void ObjectFactory::createAcsBoardComponents(LinuxLibgpioIF* gpioComIF, SerialComIF* uartComIF,
|
||||
PowerSwitchIF* pwrSwitcher) {
|
||||
using namespace gpio;
|
||||
GpioCookie* gpioCookieAcsBoard = new GpioCookie();
|
||||
std::vector<std::reference_wrapper<DeviceHandlerBase>> assemblyChildren;
|
||||
|
||||
void ObjectFactory::createAcsBoardGpios(GpioCookie& cookie) {
|
||||
std::stringstream consumer;
|
||||
GpiodRegularByLineName* gpio = nullptr;
|
||||
consumer << "0x" << std::hex << objects::GYRO_0_ADIS_HANDLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::GYRO_0_ADIS_CS, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GYRO_0_ADIS_CS, gpio);
|
||||
cookie.addGpio(gpioIds::GYRO_0_ADIS_CS, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GYRO_1_L3G_HANDLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::GYRO_1_L3G_CS, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GYRO_1_L3G_CS, gpio);
|
||||
cookie.addGpio(gpioIds::GYRO_1_L3G_CS, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GYRO_2_ADIS_HANDLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::GYRO_2_ADIS_CS, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GYRO_2_ADIS_CS, gpio);
|
||||
cookie.addGpio(gpioIds::GYRO_2_ADIS_CS, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GYRO_3_L3G_HANDLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::GYRO_3_L3G_CS, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GYRO_3_L3G_CS, gpio);
|
||||
cookie.addGpio(gpioIds::GYRO_3_L3G_CS, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::MGM_0_LIS3_HANDLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::MGM_0_CS, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::MGM_0_LIS3_CS, gpio);
|
||||
cookie.addGpio(gpioIds::MGM_0_LIS3_CS, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::MGM_1_RM3100_HANDLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::MGM_1_CS, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::MGM_1_RM3100_CS, gpio);
|
||||
cookie.addGpio(gpioIds::MGM_1_RM3100_CS, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::MGM_2_LIS3_HANDLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::MGM_2_CS, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::MGM_2_LIS3_CS, gpio);
|
||||
cookie.addGpio(gpioIds::MGM_2_LIS3_CS, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::MGM_3_RM3100_HANDLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::MGM_3_CS, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::MGM_3_RM3100_CS, gpio);
|
||||
cookie.addGpio(gpioIds::MGM_3_RM3100_CS, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GPS_CONTROLLER;
|
||||
// GNSS reset pins are active low
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::RESET_GNSS_0, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GNSS_0_NRESET, gpio);
|
||||
cookie.addGpio(gpioIds::GNSS_0_NRESET, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GPS_CONTROLLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::RESET_GNSS_1, consumer.str(), Direction::OUT,
|
||||
Levels::HIGH);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GNSS_1_NRESET, gpio);
|
||||
cookie.addGpio(gpioIds::GNSS_1_NRESET, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GYRO_0_ADIS_HANDLER;
|
||||
// Enable pins must be pulled low for regular operations
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::GYRO_0_ENABLE, consumer.str(), Direction::OUT,
|
||||
Levels::LOW);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GYRO_0_ENABLE, gpio);
|
||||
cookie.addGpio(gpioIds::GYRO_0_ENABLE, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GYRO_2_ADIS_HANDLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::GYRO_2_ENABLE, consumer.str(), Direction::OUT,
|
||||
Levels::LOW);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GYRO_2_ENABLE, gpio);
|
||||
cookie.addGpio(gpioIds::GYRO_2_ENABLE, gpio);
|
||||
|
||||
// Enable pins for GNSS
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GPS_CONTROLLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::GNSS_0_ENABLE, consumer.str(), Direction::OUT,
|
||||
Levels::LOW);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GNSS_0_ENABLE, gpio);
|
||||
cookie.addGpio(gpioIds::GNSS_0_ENABLE, gpio);
|
||||
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GPS_CONTROLLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::GNSS_1_ENABLE, consumer.str(), Direction::OUT,
|
||||
Levels::LOW);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GNSS_1_ENABLE, gpio);
|
||||
cookie.addGpio(gpioIds::GNSS_1_ENABLE, gpio);
|
||||
|
||||
// Select pin. 0 for GPS side A, 1 for GPS side B
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::GPS_CONTROLLER;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::GNSS_SELECT, consumer.str(), Direction::OUT,
|
||||
Levels::LOW);
|
||||
gpioCookieAcsBoard->addGpio(gpioIds::GNSS_SELECT, gpio);
|
||||
cookie.addGpio(gpioIds::GNSS_SELECT, gpio);
|
||||
}
|
||||
|
||||
void ObjectFactory::createAcsBoardComponents(SpiComIF& spiComIF, LinuxLibgpioIF* gpioComIF,
|
||||
SerialComIF* uartComIF, PowerSwitchIF& pwrSwitcher) {
|
||||
using namespace gpio;
|
||||
GpioCookie* gpioCookieAcsBoard = new GpioCookie();
|
||||
createAcsBoardGpios(*gpioCookieAcsBoard);
|
||||
gpioChecker(gpioComIF->addGpios(gpioCookieAcsBoard), "ACS Board");
|
||||
|
||||
AcsBoardFdir* fdir = nullptr;
|
||||
static_cast<void>(fdir);
|
||||
|
||||
#if OBSW_ADD_ACS_BOARD == 1
|
||||
new AcsBoardPolling(objects::ACS_BOARD_POLLING_TASK, spiComIF, *gpioComIF);
|
||||
std::string spiDev = q7s::SPI_DEFAULT_DEV;
|
||||
std::array<DeviceHandlerBase*, 8> assemblyChildren;
|
||||
SpiCookie* spiCookie =
|
||||
new SpiCookie(addresses::MGM_0_LIS3, gpioIds::MGM_0_LIS3_CS, MGMLIS3MDL::MAX_BUFFER_SIZE,
|
||||
new SpiCookie(addresses::MGM_0_LIS3, gpioIds::MGM_0_LIS3_CS, mgmLis3::MAX_BUFFER_SIZE,
|
||||
spi::DEFAULT_LIS3_MODE, spi::DEFAULT_LIS3_SPEED);
|
||||
auto mgmLis3Handler0 = new MgmLIS3MDLHandler(
|
||||
objects::MGM_0_LIS3_HANDLER, objects::SPI_MAIN_COM_IF, spiCookie, spi::LIS3_TRANSITION_DELAY);
|
||||
spiCookie->setMutexParams(MutexIF::TimeoutType::WAITING, spi::ACS_BOARD_CS_TIMEOUT);
|
||||
auto mgmLis3Handler0 =
|
||||
new MgmLis3CustomHandler(objects::MGM_0_LIS3_HANDLER, objects::ACS_BOARD_POLLING_TASK,
|
||||
spiCookie, spi::LIS3_TRANSITION_DELAY);
|
||||
fdir = new AcsBoardFdir(objects::MGM_0_LIS3_HANDLER);
|
||||
mgmLis3Handler0->setCustomFdir(fdir);
|
||||
assemblyChildren.push_back(*mgmLis3Handler0);
|
||||
assemblyChildren[0] = mgmLis3Handler0;
|
||||
#if OBSW_TEST_ACS == 1
|
||||
mgmLis3Handler->setStartUpImmediately();
|
||||
mgmLis3Handler->setToGoToNormalMode(true);
|
||||
@ -360,14 +387,15 @@ void ObjectFactory::createAcsBoardComponents(LinuxLibgpioIF* gpioComIF, SerialCo
|
||||
mgmLis3Handler->enablePeriodicPrintouts(true, 10);
|
||||
#endif
|
||||
spiCookie =
|
||||
new SpiCookie(addresses::MGM_1_RM3100, gpioIds::MGM_1_RM3100_CS, RM3100::MAX_BUFFER_SIZE,
|
||||
new SpiCookie(addresses::MGM_1_RM3100, gpioIds::MGM_1_RM3100_CS, mgmRm3100::MAX_BUFFER_SIZE,
|
||||
spi::DEFAULT_RM3100_MODE, spi::DEFAULT_RM3100_SPEED);
|
||||
spiCookie->setMutexParams(MutexIF::TimeoutType::WAITING, spi::ACS_BOARD_CS_TIMEOUT);
|
||||
auto mgmRm3100Handler1 =
|
||||
new MgmRM3100Handler(objects::MGM_1_RM3100_HANDLER, objects::SPI_MAIN_COM_IF, spiCookie,
|
||||
spi::RM3100_TRANSITION_DELAY);
|
||||
new MgmRm3100CustomHandler(objects::MGM_1_RM3100_HANDLER, objects::ACS_BOARD_POLLING_TASK,
|
||||
spiCookie, spi::RM3100_TRANSITION_DELAY);
|
||||
fdir = new AcsBoardFdir(objects::MGM_1_RM3100_HANDLER);
|
||||
mgmRm3100Handler1->setCustomFdir(fdir);
|
||||
assemblyChildren.push_back(*mgmRm3100Handler1);
|
||||
assemblyChildren[1] = mgmRm3100Handler1;
|
||||
#if OBSW_TEST_ACS == 1
|
||||
mgmRm3100Handler->setStartUpImmediately();
|
||||
mgmRm3100Handler->setToGoToNormalMode(true);
|
||||
@ -375,14 +403,15 @@ void ObjectFactory::createAcsBoardComponents(LinuxLibgpioIF* gpioComIF, SerialCo
|
||||
#if OBSW_DEBUG_ACS == 1
|
||||
mgmRm3100Handler->enablePeriodicPrintouts(true, 10);
|
||||
#endif
|
||||
spiCookie =
|
||||
new SpiCookie(addresses::MGM_2_LIS3, gpioIds::MGM_2_LIS3_CS, MGMLIS3MDL::MAX_BUFFER_SIZE,
|
||||
spi::DEFAULT_LIS3_MODE, spi::DEFAULT_LIS3_SPEED);
|
||||
auto* mgmLis3Handler2 = new MgmLIS3MDLHandler(
|
||||
objects::MGM_2_LIS3_HANDLER, objects::SPI_MAIN_COM_IF, spiCookie, spi::LIS3_TRANSITION_DELAY);
|
||||
spiCookie = new SpiCookie(addresses::MGM_2_LIS3, gpioIds::MGM_2_LIS3_CS, mgmLis3::MAX_BUFFER_SIZE,
|
||||
spi::DEFAULT_LIS3_MODE, spi::DEFAULT_LIS3_SPEED);
|
||||
spiCookie->setMutexParams(MutexIF::TimeoutType::WAITING, spi::ACS_BOARD_CS_TIMEOUT);
|
||||
auto* mgmLis3Handler2 =
|
||||
new MgmLis3CustomHandler(objects::MGM_2_LIS3_HANDLER, objects::ACS_BOARD_POLLING_TASK,
|
||||
spiCookie, spi::LIS3_TRANSITION_DELAY);
|
||||
fdir = new AcsBoardFdir(objects::MGM_2_LIS3_HANDLER);
|
||||
mgmLis3Handler2->setCustomFdir(fdir);
|
||||
assemblyChildren.push_back(*mgmLis3Handler2);
|
||||
assemblyChildren[2] = mgmLis3Handler2;
|
||||
#if OBSW_TEST_ACS == 1
|
||||
mgmLis3Handler->setStartUpImmediately();
|
||||
mgmLis3Handler->setToGoToNormalMode(true);
|
||||
@ -391,14 +420,15 @@ void ObjectFactory::createAcsBoardComponents(LinuxLibgpioIF* gpioComIF, SerialCo
|
||||
mgmLis3Handler->enablePeriodicPrintouts(true, 10);
|
||||
#endif
|
||||
spiCookie =
|
||||
new SpiCookie(addresses::MGM_3_RM3100, gpioIds::MGM_3_RM3100_CS, RM3100::MAX_BUFFER_SIZE,
|
||||
new SpiCookie(addresses::MGM_3_RM3100, gpioIds::MGM_3_RM3100_CS, mgmRm3100::MAX_BUFFER_SIZE,
|
||||
spi::DEFAULT_RM3100_MODE, spi::DEFAULT_RM3100_SPEED);
|
||||
spiCookie->setMutexParams(MutexIF::TimeoutType::WAITING, spi::ACS_BOARD_CS_TIMEOUT);
|
||||
auto* mgmRm3100Handler3 =
|
||||
new MgmRM3100Handler(objects::MGM_3_RM3100_HANDLER, objects::SPI_MAIN_COM_IF, spiCookie,
|
||||
spi::RM3100_TRANSITION_DELAY);
|
||||
new MgmRm3100CustomHandler(objects::MGM_3_RM3100_HANDLER, objects::ACS_BOARD_POLLING_TASK,
|
||||
spiCookie, spi::RM3100_TRANSITION_DELAY);
|
||||
fdir = new AcsBoardFdir(objects::MGM_3_RM3100_HANDLER);
|
||||
mgmRm3100Handler3->setCustomFdir(fdir);
|
||||
assemblyChildren.push_back(*mgmRm3100Handler3);
|
||||
assemblyChildren[3] = mgmRm3100Handler3;
|
||||
#if OBSW_TEST_ACS == 1
|
||||
mgmRm3100Handler->setStartUpImmediately();
|
||||
mgmRm3100Handler->setToGoToNormalMode(true);
|
||||
@ -409,14 +439,15 @@ void ObjectFactory::createAcsBoardComponents(LinuxLibgpioIF* gpioComIF, SerialCo
|
||||
// Commented until ACS board V2 in in clean room again
|
||||
// Gyro 0 Side A
|
||||
spiCookie =
|
||||
new SpiCookie(addresses::GYRO_0_ADIS, gpioIds::GYRO_0_ADIS_CS, ADIS1650X::MAXIMUM_REPLY_SIZE,
|
||||
new SpiCookie(addresses::GYRO_0_ADIS, gpioIds::GYRO_0_ADIS_CS, adis1650x::MAXIMUM_REPLY_SIZE,
|
||||
spi::DEFAULT_ADIS16507_MODE, spi::DEFAULT_ADIS16507_SPEED);
|
||||
spiCookie->setMutexParams(MutexIF::TimeoutType::WAITING, spi::ACS_BOARD_CS_TIMEOUT);
|
||||
auto adisHandler =
|
||||
new GyroADIS1650XHandler(objects::GYRO_0_ADIS_HANDLER, objects::SPI_MAIN_COM_IF, spiCookie,
|
||||
ADIS1650X::Type::ADIS16505);
|
||||
new GyrAdis1650XHandler(objects::GYRO_0_ADIS_HANDLER, objects::ACS_BOARD_POLLING_TASK,
|
||||
spiCookie, adis1650x::Type::ADIS16505);
|
||||
fdir = new AcsBoardFdir(objects::GYRO_0_ADIS_HANDLER);
|
||||
adisHandler->setCustomFdir(fdir);
|
||||
assemblyChildren.push_back(*adisHandler);
|
||||
assemblyChildren[4] = adisHandler;
|
||||
#if OBSW_TEST_ACS == 1
|
||||
adisHandler->setStartUpImmediately();
|
||||
adisHandler->setToGoToNormalModeImmediately();
|
||||
@ -425,13 +456,15 @@ void ObjectFactory::createAcsBoardComponents(LinuxLibgpioIF* gpioComIF, SerialCo
|
||||
adisHandler->enablePeriodicPrintouts(true, 10);
|
||||
#endif
|
||||
// Gyro 1 Side A
|
||||
spiCookie = new SpiCookie(addresses::GYRO_1_L3G, gpioIds::GYRO_1_L3G_CS, L3GD20H::MAX_BUFFER_SIZE,
|
||||
spiCookie = new SpiCookie(addresses::GYRO_1_L3G, gpioIds::GYRO_1_L3G_CS, l3gd20h::MAX_BUFFER_SIZE,
|
||||
spi::DEFAULT_L3G_MODE, spi::DEFAULT_L3G_SPEED);
|
||||
auto gyroL3gHandler1 = new GyroHandlerL3GD20H(
|
||||
objects::GYRO_1_L3G_HANDLER, objects::SPI_MAIN_COM_IF, spiCookie, spi::L3G_TRANSITION_DELAY);
|
||||
spiCookie->setMutexParams(MutexIF::TimeoutType::WAITING, spi::ACS_BOARD_CS_TIMEOUT);
|
||||
auto gyroL3gHandler1 =
|
||||
new GyrL3gCustomHandler(objects::GYRO_1_L3G_HANDLER, objects::ACS_BOARD_POLLING_TASK,
|
||||
spiCookie, spi::L3G_TRANSITION_DELAY);
|
||||
fdir = new AcsBoardFdir(objects::GYRO_1_L3G_HANDLER);
|
||||
gyroL3gHandler1->setCustomFdir(fdir);
|
||||
assemblyChildren.push_back(*gyroL3gHandler1);
|
||||
assemblyChildren[5] = gyroL3gHandler1;
|
||||
#if OBSW_TEST_ACS == 1
|
||||
gyroL3gHandler->setStartUpImmediately();
|
||||
gyroL3gHandler->setToGoToNormalMode(true);
|
||||
@ -441,25 +474,29 @@ void ObjectFactory::createAcsBoardComponents(LinuxLibgpioIF* gpioComIF, SerialCo
|
||||
#endif
|
||||
// Gyro 2 Side B
|
||||
spiCookie =
|
||||
new SpiCookie(addresses::GYRO_2_ADIS, gpioIds::GYRO_2_ADIS_CS, ADIS1650X::MAXIMUM_REPLY_SIZE,
|
||||
new SpiCookie(addresses::GYRO_2_ADIS, gpioIds::GYRO_2_ADIS_CS, adis1650x::MAXIMUM_REPLY_SIZE,
|
||||
spi::DEFAULT_ADIS16507_MODE, spi::DEFAULT_ADIS16507_SPEED);
|
||||
adisHandler = new GyroADIS1650XHandler(objects::GYRO_2_ADIS_HANDLER, objects::SPI_MAIN_COM_IF,
|
||||
spiCookie, ADIS1650X::Type::ADIS16505);
|
||||
spiCookie->setMutexParams(MutexIF::TimeoutType::WAITING, spi::ACS_BOARD_CS_TIMEOUT);
|
||||
adisHandler =
|
||||
new GyrAdis1650XHandler(objects::GYRO_2_ADIS_HANDLER, objects::ACS_BOARD_POLLING_TASK,
|
||||
spiCookie, adis1650x::Type::ADIS16505);
|
||||
fdir = new AcsBoardFdir(objects::GYRO_2_ADIS_HANDLER);
|
||||
adisHandler->setCustomFdir(fdir);
|
||||
assemblyChildren.push_back(*adisHandler);
|
||||
assemblyChildren[6] = adisHandler;
|
||||
#if OBSW_TEST_ACS == 1
|
||||
adisHandler->setStartUpImmediately();
|
||||
adisHandler->setToGoToNormalModeImmediately();
|
||||
#endif
|
||||
// Gyro 3 Side B
|
||||
spiCookie = new SpiCookie(addresses::GYRO_3_L3G, gpioIds::GYRO_3_L3G_CS, L3GD20H::MAX_BUFFER_SIZE,
|
||||
spiCookie = new SpiCookie(addresses::GYRO_3_L3G, gpioIds::GYRO_3_L3G_CS, l3gd20h::MAX_BUFFER_SIZE,
|
||||
spi::DEFAULT_L3G_MODE, spi::DEFAULT_L3G_SPEED);
|
||||
auto gyroL3gHandler3 = new GyroHandlerL3GD20H(
|
||||
objects::GYRO_3_L3G_HANDLER, objects::SPI_MAIN_COM_IF, spiCookie, spi::L3G_TRANSITION_DELAY);
|
||||
spiCookie->setMutexParams(MutexIF::TimeoutType::WAITING, spi::ACS_BOARD_CS_TIMEOUT);
|
||||
auto gyroL3gHandler3 =
|
||||
new GyrL3gCustomHandler(objects::GYRO_3_L3G_HANDLER, objects::ACS_BOARD_POLLING_TASK,
|
||||
spiCookie, spi::L3G_TRANSITION_DELAY);
|
||||
fdir = new AcsBoardFdir(objects::GYRO_3_L3G_HANDLER);
|
||||
gyroL3gHandler3->setCustomFdir(fdir);
|
||||
assemblyChildren.push_back(*gyroL3gHandler3);
|
||||
assemblyChildren[7] = gyroL3gHandler3;
|
||||
#if OBSW_TEST_ACS == 1
|
||||
gyroL3gHandler->setStartUpImmediately();
|
||||
gyroL3gHandler->setToGoToNormalMode(true);
|
||||
@ -474,30 +511,16 @@ void ObjectFactory::createAcsBoardComponents(LinuxLibgpioIF* gpioComIF, SerialCo
|
||||
RESET_ARGS_GNSS.gpioComIF = gpioComIF;
|
||||
RESET_ARGS_GNSS.waitPeriodMs = 100;
|
||||
auto gpsCtrl =
|
||||
new GPSHyperionLinuxController(objects::GPS_CONTROLLER, objects::NO_OBJECT, debugGps);
|
||||
new GpsHyperionLinuxController(objects::GPS_CONTROLLER, objects::NO_OBJECT, debugGps);
|
||||
gpsCtrl->setResetPinTriggerFunction(gps::triggerGpioResetPin, &RESET_ARGS_GNSS);
|
||||
|
||||
AcsBoardHelper acsBoardHelper = AcsBoardHelper(
|
||||
objects::MGM_0_LIS3_HANDLER, objects::MGM_1_RM3100_HANDLER, objects::MGM_2_LIS3_HANDLER,
|
||||
objects::MGM_3_RM3100_HANDLER, objects::GYRO_0_ADIS_HANDLER, objects::GYRO_1_L3G_HANDLER,
|
||||
objects::GYRO_2_ADIS_HANDLER, objects::GYRO_3_L3G_HANDLER, objects::GPS_CONTROLLER);
|
||||
auto acsAss =
|
||||
new AcsBoardAssembly(objects::ACS_BOARD_ASS, pwrSwitcher, acsBoardHelper, gpioComIF);
|
||||
static_cast<void>(acsAss);
|
||||
for (auto& assChild : assemblyChildren) {
|
||||
ReturnValue_t result = assChild.get().connectModeTreeParent(*acsAss);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "Connecting assembly for ACS board component " << assChild.get().getObjectId()
|
||||
<< " failed" << std::endl;
|
||||
}
|
||||
}
|
||||
gpsCtrl->connectModeTreeParent(*acsAss);
|
||||
acsAss->connectModeTreeParent(satsystem::acs::ACS_SUBSYSTEM);
|
||||
ObjectFactory::createAcsBoardAssy(pwrSwitcher, assemblyChildren, gpsCtrl, gpioComIF);
|
||||
#endif /* OBSW_ADD_ACS_HANDLERS == 1 */
|
||||
}
|
||||
|
||||
void ObjectFactory::createHeaterComponents(GpioIF* gpioIF, PowerSwitchIF* pwrSwitcher,
|
||||
HealthTableIF* healthTable) {
|
||||
HealthTableIF* healthTable,
|
||||
HeaterHandler*& heaterHandler) {
|
||||
using namespace gpio;
|
||||
GpioCookie* heaterGpiosCookie = new GpioCookie;
|
||||
GpiodRegularByLineName* gpio = nullptr;
|
||||
@ -540,19 +563,7 @@ void ObjectFactory::createHeaterComponents(GpioIF* gpioIF, PowerSwitchIF* pwrSwi
|
||||
|
||||
gpioIF->addGpios(heaterGpiosCookie);
|
||||
|
||||
HeaterHelper helper({{
|
||||
{new HealthDevice(objects::HEATER_0_PLOC_PROC_BRD, MessageQueueIF::NO_QUEUE),
|
||||
gpioIds::HEATER_0},
|
||||
{new HealthDevice(objects::HEATER_1_PCDU_BRD, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_1},
|
||||
{new HealthDevice(objects::HEATER_2_ACS_BRD, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_2},
|
||||
{new HealthDevice(objects::HEATER_3_OBC_BRD, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_3},
|
||||
{new HealthDevice(objects::HEATER_4_CAMERA, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_4},
|
||||
{new HealthDevice(objects::HEATER_5_STR, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_5},
|
||||
{new HealthDevice(objects::HEATER_6_DRO, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_6},
|
||||
{new HealthDevice(objects::HEATER_7_HPA, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_7},
|
||||
}});
|
||||
new HeaterHandler(objects::HEATER_HANDLER, gpioIF, helper, pwrSwitcher,
|
||||
pcdu::Switches::PDU2_CH3_TCS_BOARD_HEATER_IN_8V);
|
||||
ObjectFactory::createGenericHeaterComponents(*gpioIF, *pwrSwitcher, heaterHandler);
|
||||
}
|
||||
|
||||
void ObjectFactory::createSolarArrayDeploymentComponents(PowerSwitchIF& pwrSwitcher,
|
||||
@ -585,13 +596,14 @@ void ObjectFactory::createSyrlinksComponents(PowerSwitchIF* pwrSwitcher) {
|
||||
syrlinks::MAX_REPLY_SIZE, UartModes::NON_CANONICAL);
|
||||
syrlinksUartCookie->setParityEven();
|
||||
|
||||
auto* syrlinksAssy = new SyrlinksAssembly(objects::SYRLINKS_ASSY);
|
||||
syrlinksAssy->connectModeTreeParent(satsystem::com::SUBSYSTEM);
|
||||
auto syrlinksFdir = new SyrlinksFdir(objects::SYRLINKS_HANDLER);
|
||||
auto syrlinksHandler =
|
||||
new SyrlinksHandler(objects::SYRLINKS_HANDLER, objects::UART_COM_IF, syrlinksUartCookie,
|
||||
pcdu::PDU1_CH1_SYRLINKS_12V, syrlinksFdir);
|
||||
syrlinksHandler->setPowerSwitcher(pwrSwitcher);
|
||||
syrlinksHandler->setStartUpImmediately();
|
||||
syrlinksHandler->connectModeTreeParent(satsystem::com::SUBSYSTEM);
|
||||
syrlinksHandler->connectModeTreeParent(*syrlinksAssy);
|
||||
#if OBSW_DEBUG_SYRLINKS == 1
|
||||
syrlinksHandler->setDebugMode(true);
|
||||
#endif
|
||||
@ -602,7 +614,7 @@ void ObjectFactory::createPayloadComponents(LinuxLibgpioIF* gpioComIF, PowerSwit
|
||||
std::stringstream consumer;
|
||||
auto* camSwitcher =
|
||||
new CamSwitcher(objects::CAM_SWITCHER, pwrSwitch, pcdu::PDU2_CH8_PAYLOAD_CAMERA);
|
||||
camSwitcher->connectModeTreeParent(satsystem::pl::SUBSYSTEM);
|
||||
camSwitcher->connectModeTreeParent(satsystem::payload::SUBSYSTEM);
|
||||
#if OBSW_ADD_PLOC_MPSOC == 1
|
||||
consumer << "0x" << std::hex << objects::PLOC_MPSOC_HANDLER;
|
||||
auto gpioConfigMPSoC = new GpiodRegularByLineName(q7s::gpioNames::ENABLE_MPSOC_UART,
|
||||
@ -618,7 +630,7 @@ void ObjectFactory::createPayloadComponents(LinuxLibgpioIF* gpioComIF, PowerSwit
|
||||
auto* mpsocHandler = new PlocMPSoCHandler(
|
||||
objects::PLOC_MPSOC_HANDLER, objects::UART_COM_IF, mpsocCookie, plocMpsocHelper,
|
||||
Gpio(gpioIds::ENABLE_MPSOC_UART, gpioComIF), objects::PLOC_SUPERVISOR_HANDLER);
|
||||
mpsocHandler->connectModeTreeParent(satsystem::pl::SUBSYSTEM);
|
||||
mpsocHandler->connectModeTreeParent(satsystem::payload::SUBSYSTEM);
|
||||
#endif /* OBSW_ADD_PLOC_MPSOC == 1 */
|
||||
#if OBSW_ADD_PLOC_SUPERVISOR == 1
|
||||
consumer << "0x" << std::hex << objects::PLOC_SUPERVISOR_HANDLER;
|
||||
@ -635,7 +647,7 @@ void ObjectFactory::createPayloadComponents(LinuxLibgpioIF* gpioComIF, PowerSwit
|
||||
auto* supvHandler = new PlocSupervisorHandler(objects::PLOC_SUPERVISOR_HANDLER, supervisorCookie,
|
||||
Gpio(gpioIds::ENABLE_SUPV_UART, gpioComIF),
|
||||
pcdu::PDU1_CH6_PLOC_12V, *supvHelper);
|
||||
supvHandler->connectModeTreeParent(satsystem::pl::SUBSYSTEM);
|
||||
supvHandler->connectModeTreeParent(satsystem::payload::SUBSYSTEM);
|
||||
#endif /* OBSW_ADD_PLOC_SUPERVISOR == 1 */
|
||||
static_cast<void>(consumer);
|
||||
}
|
||||
@ -695,85 +707,67 @@ void ObjectFactory::createReactionWheelComponents(LinuxLibgpioIF* gpioComIF,
|
||||
std::array<object_id_t, 4> rwIds = {objects::RW1, objects::RW2, objects::RW3, objects::RW4};
|
||||
std::array<gpioId_t, 4> rwGpioIds = {gpioIds::EN_RW1, gpioIds::EN_RW2, gpioIds::EN_RW3,
|
||||
gpioIds::EN_RW4};
|
||||
std::array<RwHandler*, 4> rws = {};
|
||||
std::array<DeviceHandlerBase*, 4> rws = {};
|
||||
new RwPollingTask(objects::RW_POLLING_TASK, q7s::SPI_RW_DEV, *gpioComIF);
|
||||
for (uint8_t idx = 0; idx < rwCookies.size(); idx++) {
|
||||
rwCookies[idx] = new SpiCookie(rwCookieParams[idx].first, rwCookieParams[idx].second,
|
||||
RwDefinitions::MAX_REPLY_SIZE, spi::RW_MODE, spi::RW_SPEED,
|
||||
&rwSpiCallback::spiCallback, nullptr);
|
||||
rws[idx] = new RwHandler(rwIds[idx], objects::SPI_RW_COM_IF, rwCookies[idx], gpioComIF,
|
||||
rwGpioIds[idx]);
|
||||
rwCookies[idx]->setCallbackArgs(rws[idx]);
|
||||
rwCookies[idx] = new RwCookie(idx, rwCookieParams[idx].first, rwCookieParams[idx].second,
|
||||
rws::MAX_REPLY_SIZE, spi::RW_MODE, spi::RW_SPEED);
|
||||
auto* rwHandler = new RwHandler(rwIds[idx], objects::RW_POLLING_TASK, rwCookies[idx], gpioComIF,
|
||||
rwGpioIds[idx], idx);
|
||||
#if OBSW_TEST_RW == 1
|
||||
rws[idx]->setStartUpImmediately();
|
||||
#endif
|
||||
#if OBSW_DEBUG_RW == 1
|
||||
rws[idx]->setDebugMode(true);
|
||||
rwHandler->setDebugMode(true);
|
||||
#endif
|
||||
rws[idx] = rwHandler;
|
||||
}
|
||||
|
||||
RwHelper rwHelper(rwIds);
|
||||
auto* rwAss =
|
||||
new RwAssembly(objects::RW_ASS, pwrSwitcher, pcdu::Switches::PDU2_CH2_RW_5V, rwHelper);
|
||||
for (uint8_t idx = 0; idx < rws.size(); idx++) {
|
||||
ReturnValue_t result = rws[idx]->connectModeTreeParent(*rwAss);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "Connecting RW " << static_cast<int>(idx) << " to RW assembly failed"
|
||||
<< std::endl;
|
||||
}
|
||||
}
|
||||
rwAss->connectModeTreeParent(satsystem::acs::ACS_SUBSYSTEM);
|
||||
createRwAssy(*pwrSwitcher, pcdu::Switches::PDU2_CH2_RW_5V, rws, rwIds);
|
||||
#endif /* OBSW_ADD_RW == 1 */
|
||||
}
|
||||
|
||||
ReturnValue_t ObjectFactory::createCcsdsComponents(LinuxLibgpioIF* gpioComIF,
|
||||
CcsdsIpCoreHandler** ipCoreHandler) {
|
||||
ReturnValue_t ObjectFactory::createCcsdsComponents(CcsdsComponentArgs& args) {
|
||||
using namespace gpio;
|
||||
// GPIO definitions of signals connected to the virtual channel interfaces of the PTME IP Core
|
||||
GpioCookie* gpioCookiePtmeIp = new GpioCookie;
|
||||
GpiodRegularByLineName* gpio = nullptr;
|
||||
std::stringstream consumer;
|
||||
consumer.str("PAPB VC0");
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_BUSY_SIGNAL_VC0, consumer.str());
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_BUSY_SIGNAL_VC0, "PAPB VC0");
|
||||
gpioCookiePtmeIp->addGpio(gpioIds::VC0_PAPB_BUSY, gpio);
|
||||
consumer.str("PAPB VC0");
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_EMPTY_SIGNAL_VC0, consumer.str());
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_EMPTY_SIGNAL_VC0, "PAPB VC0");
|
||||
gpioCookiePtmeIp->addGpio(gpioIds::VC0_PAPB_EMPTY, gpio);
|
||||
consumer.str("PAPB VC 1");
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_BUSY_SIGNAL_VC1, consumer.str());
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_BUSY_SIGNAL_VC1, "PAPB VC1");
|
||||
gpioCookiePtmeIp->addGpio(gpioIds::VC1_PAPB_BUSY, gpio);
|
||||
consumer.str("");
|
||||
consumer.str("PAPB VC 1");
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_EMPTY_SIGNAL_VC1, "PAPB VC1");
|
||||
gpioCookiePtmeIp->addGpio(gpioIds::VC1_PAPB_EMPTY, gpio);
|
||||
consumer.str("");
|
||||
consumer.str("PAPB VC 2");
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_BUSY_SIGNAL_VC2, consumer.str());
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_BUSY_SIGNAL_VC2, "PAPB VC2");
|
||||
gpioCookiePtmeIp->addGpio(gpioIds::VC2_PAPB_BUSY, gpio);
|
||||
consumer.str("");
|
||||
consumer.str("PAPB VC 2");
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_EMPTY_SIGNAL_VC2, consumer.str());
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_EMPTY_SIGNAL_VC2, "PAPB VC2");
|
||||
gpioCookiePtmeIp->addGpio(gpioIds::VC2_PAPB_EMPTY, gpio);
|
||||
consumer.str("");
|
||||
consumer.str("PAPB VC 3");
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_BUSY_SIGNAL_VC3, consumer.str());
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_BUSY_SIGNAL_VC3, "PAPB VC3");
|
||||
gpioCookiePtmeIp->addGpio(gpioIds::VC3_PAPB_BUSY, gpio);
|
||||
consumer.str("");
|
||||
consumer.str("PAPB VC 3");
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_EMPTY_SIGNAL_VC3, consumer.str());
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PAPB_EMPTY_SIGNAL_VC3, "PAPB VC3");
|
||||
gpioCookiePtmeIp->addGpio(gpioIds::VC3_PAPB_EMPTY, gpio);
|
||||
gpioChecker(gpioComIF->addGpios(gpioCookiePtmeIp), "PTME PAPB VCs");
|
||||
// Initialise to low and then pull high to do a PTME reset, which puts the PTME in reset
|
||||
// state. It will be put out of reset in the CCSDS handler initialize function.
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PTME_RESETN, "PTME RESETN",
|
||||
gpio::Direction::OUT, gpio::Levels::LOW);
|
||||
gpioCookiePtmeIp->addGpio(gpioIds::PTME_RESETN, gpio);
|
||||
gpioChecker(args.gpioComIF.addGpios(gpioCookiePtmeIp), "PTME PAPB VCs");
|
||||
|
||||
// Creating virtual channel interfaces
|
||||
VcInterfaceIF* vc0 =
|
||||
new PapbVcInterface(gpioComIF, gpioIds::VC0_PAPB_BUSY, gpioIds::VC0_PAPB_EMPTY, q7s::UIO_PTME,
|
||||
q7s::uiomapids::PTME_VC0);
|
||||
VcInterfaceIF* vc1 =
|
||||
new PapbVcInterface(gpioComIF, gpioIds::VC1_PAPB_BUSY, gpioIds::VC1_PAPB_EMPTY, q7s::UIO_PTME,
|
||||
q7s::uiomapids::PTME_VC1);
|
||||
VcInterfaceIF* vc2 =
|
||||
new PapbVcInterface(gpioComIF, gpioIds::VC2_PAPB_BUSY, gpioIds::VC2_PAPB_EMPTY, q7s::UIO_PTME,
|
||||
q7s::uiomapids::PTME_VC2);
|
||||
VcInterfaceIF* vc3 =
|
||||
new PapbVcInterface(gpioComIF, gpioIds::VC3_PAPB_BUSY, gpioIds::VC3_PAPB_EMPTY, q7s::UIO_PTME,
|
||||
q7s::uiomapids::PTME_VC3);
|
||||
VirtualChannelIF* vc0 =
|
||||
new PapbVcInterface(&args.gpioComIF, gpioIds::VC0_PAPB_BUSY, gpioIds::VC0_PAPB_EMPTY,
|
||||
q7s::UIO_PTME, q7s::uiomapids::PTME_VC0);
|
||||
VirtualChannelIF* vc1 =
|
||||
new PapbVcInterface(&args.gpioComIF, gpioIds::VC1_PAPB_BUSY, gpioIds::VC1_PAPB_EMPTY,
|
||||
q7s::UIO_PTME, q7s::uiomapids::PTME_VC1);
|
||||
VirtualChannelIF* vc2 =
|
||||
new PapbVcInterface(&args.gpioComIF, gpioIds::VC2_PAPB_BUSY, gpioIds::VC2_PAPB_EMPTY,
|
||||
q7s::UIO_PTME, q7s::uiomapids::PTME_VC2);
|
||||
VirtualChannelIF* vc3 =
|
||||
new PapbVcInterface(&args.gpioComIF, gpioIds::VC3_PAPB_BUSY, gpioIds::VC3_PAPB_EMPTY,
|
||||
q7s::UIO_PTME, q7s::uiomapids::PTME_VC3);
|
||||
// Creating ptme object and adding virtual channel interfaces
|
||||
Ptme* ptme = new Ptme(objects::PTME);
|
||||
ptme->addVcInterface(ccsds::VC0, vc0);
|
||||
@ -783,26 +777,44 @@ ReturnValue_t ObjectFactory::createCcsdsComponents(LinuxLibgpioIF* gpioComIF,
|
||||
AxiPtmeConfig* axiPtmeConfig =
|
||||
new AxiPtmeConfig(objects::AXI_PTME_CONFIG, q7s::UIO_PTME, q7s::uiomapids::PTME_CONFIG);
|
||||
PtmeConfig* ptmeConfig = new PtmeConfig(objects::PTME_CONFIG, axiPtmeConfig);
|
||||
#if OBSW_ENABLE_SYRLINKS_TRANSMIT_TIMEOUT == 1
|
||||
// Set to high value when not sending via syrlinks
|
||||
static const uint32_t TRANSMITTER_TIMEOUT = 86400000; // 1 day
|
||||
#else
|
||||
static const uint32_t TRANSMITTER_TIMEOUT = 900000; // 15 minutes
|
||||
#endif
|
||||
*ipCoreHandler = new CcsdsIpCoreHandler(
|
||||
objects::CCSDS_HANDLER, objects::PTME, objects::CCSDS_PACKET_DISTRIBUTOR, ptmeConfig,
|
||||
gpioComIF, gpioIds::RS485_EN_TX_CLOCK, gpioIds::RS485_EN_TX_DATA, TRANSMITTER_TIMEOUT);
|
||||
VirtualChannel* vc = nullptr;
|
||||
vc = new VirtualChannel(ccsds::VC0, config::VC0_QUEUE_SIZE, objects::CCSDS_HANDLER);
|
||||
(*ipCoreHandler)->addVirtualChannel(ccsds::VC0, vc);
|
||||
vc = new VirtualChannel(ccsds::VC1, config::VC1_QUEUE_SIZE, objects::CCSDS_HANDLER);
|
||||
(*ipCoreHandler)->addVirtualChannel(ccsds::VC1, vc);
|
||||
vc = new VirtualChannel(ccsds::VC2, config::VC2_QUEUE_SIZE, objects::CCSDS_HANDLER);
|
||||
(*ipCoreHandler)->addVirtualChannel(ccsds::VC2, vc);
|
||||
vc = new VirtualChannel(ccsds::VC3, config::VC3_QUEUE_SIZE, objects::CCSDS_HANDLER);
|
||||
(*ipCoreHandler)->addVirtualChannel(ccsds::VC3, vc);
|
||||
|
||||
ReturnValue_t result = (*ipCoreHandler)->connectModeTreeParent(satsystem::com::SUBSYSTEM);
|
||||
PtmeGpios gpios;
|
||||
gpios.enableTxClock = gpioIds::RS485_EN_TX_CLOCK;
|
||||
gpios.enableTxData = gpioIds::RS485_EN_TX_DATA;
|
||||
gpios.ptmeResetn = gpioIds::PTME_RESETN;
|
||||
|
||||
*args.ipCoreHandler =
|
||||
new CcsdsIpCoreHandler(objects::CCSDS_HANDLER, objects::CCSDS_PACKET_DISTRIBUTOR, *ptmeConfig,
|
||||
LINK_STATE, &args.gpioComIF, gpios);
|
||||
// This VC will receive all live TM
|
||||
auto* vcWithQueue =
|
||||
new VirtualChannelWithQueue(objects::PTME_VC0_LIVE_TM, ccsds::VC0, "PTME VC0 LIVE TM", *ptme,
|
||||
LINK_STATE, args.tmStore, 500);
|
||||
args.liveDestination = vcWithQueue;
|
||||
new LiveTmTask(objects::LIVE_TM_TASK, args.pusFunnel, args.cfdpFunnel, *vcWithQueue);
|
||||
|
||||
// Set up log store.
|
||||
auto* vc = new VirtualChannel(objects::PTME_VC1_LOG_TM, ccsds::VC1, "PTME VC1 LOG TM", *ptme,
|
||||
LINK_STATE);
|
||||
LogStores logStores(args.stores);
|
||||
// Core task which handles the LOG store and takes care of dumping it as TM using a VC directly
|
||||
new PersistentLogTmStoreTask(objects::LOG_STORE_AND_TM_TASK, args.ipcStore, logStores, *vc,
|
||||
*SdCardManager::instance());
|
||||
|
||||
vc = new VirtualChannel(objects::PTME_VC2_HK_TM, ccsds::VC2, "PTME VC2 HK TM", *ptme, LINK_STATE);
|
||||
// Core task which handles the HK store and takes care of dumping it as TM using a VC directly
|
||||
new PersistentSingleTmStoreTask(objects::HK_STORE_AND_TM_TASK, args.ipcStore,
|
||||
*args.stores.hkStore, *vc, persTmStore::DUMP_HK_STORE_DONE,
|
||||
*SdCardManager::instance());
|
||||
|
||||
vc = new VirtualChannel(objects::PTME_VC3_CFDP_TM, ccsds::VC3, "PTME VC3 CFDP TM", *ptme,
|
||||
LINK_STATE);
|
||||
// Core task which handles the CFDP store and takes care of dumping it as TM using a VC directly
|
||||
new PersistentSingleTmStoreTask(objects::CFDP_STORE_AND_TM_TASK, args.ipcStore,
|
||||
*args.stores.cfdpStore, *vc, persTmStore::DUMP_CFDP_STORE_DONE,
|
||||
*SdCardManager::instance());
|
||||
|
||||
ReturnValue_t result = (*args.ipCoreHandler)->connectModeTreeParent(satsystem::com::SUBSYSTEM);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error
|
||||
<< "ObjectFactory::createCcsdsComponents: Connecting COM subsystem to CCSDS handler failed"
|
||||
@ -810,20 +822,18 @@ ReturnValue_t ObjectFactory::createCcsdsComponents(LinuxLibgpioIF* gpioComIF,
|
||||
}
|
||||
|
||||
GpioCookie* gpioCookiePdec = new GpioCookie;
|
||||
consumer.str("");
|
||||
consumer << "0x" << std::hex << objects::PDEC_HANDLER;
|
||||
// GPIO also low after linux boot (specified by device-tree)
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PDEC_RESET, consumer.str(), Direction::OUT,
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::PDEC_RESET, "PDEC Handler", Direction::OUT,
|
||||
Levels::LOW);
|
||||
gpioCookiePdec->addGpio(gpioIds::PDEC_RESET, gpio);
|
||||
gpioChecker(gpioComIF->addGpios(gpioCookiePdec), "PDEC");
|
||||
gpioChecker(args.gpioComIF.addGpios(gpioCookiePdec), "PDEC");
|
||||
struct UioNames uioNames {};
|
||||
uioNames.configMemory = q7s::UIO_PDEC_CONFIG_MEMORY;
|
||||
uioNames.ramMemory = q7s::UIO_PDEC_RAM;
|
||||
uioNames.registers = q7s::UIO_PDEC_REGISTERS;
|
||||
uioNames.irq = q7s::UIO_PDEC_IRQ;
|
||||
new PdecHandler(objects::PDEC_HANDLER, objects::CCSDS_HANDLER, gpioComIF, gpioIds::PDEC_RESET,
|
||||
uioNames);
|
||||
new PdecHandler(objects::PDEC_HANDLER, objects::CCSDS_HANDLER, &args.gpioComIF,
|
||||
gpioIds::PDEC_RESET, uioNames);
|
||||
GpioCookie* gpioRS485Chip = new GpioCookie;
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::RS485_EN_TX_CLOCK, "RS485 Transceiver",
|
||||
Direction::OUT, Levels::LOW);
|
||||
@ -838,7 +848,7 @@ ReturnValue_t ObjectFactory::createCcsdsComponents(LinuxLibgpioIF* gpioComIF,
|
||||
gpio = new GpiodRegularByLineName(q7s::gpioNames::RS485_EN_RX_DATA, "RS485 Transceiver",
|
||||
Direction::OUT, Levels::LOW);
|
||||
gpioRS485Chip->addGpio(gpioIds::RS485_EN_RX_DATA, gpio);
|
||||
gpioChecker(gpioComIF->addGpios(gpioRS485Chip), "RS485 Transceiver");
|
||||
gpioChecker(args.gpioComIF.addGpios(gpioRS485Chip), "RS485 Transceiver");
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
@ -903,7 +913,7 @@ void ObjectFactory::createPlPcduComponents(LinuxLibgpioIF* gpioComIF, SpiComIF*
|
||||
plPcduHandler->setToGoToNormalModeImmediately(true);
|
||||
plPcduHandler->enablePeriodicPrintout(true, 10);
|
||||
#endif
|
||||
plPcduHandler->connectModeTreeParent(satsystem::pl::SUBSYSTEM);
|
||||
plPcduHandler->connectModeTreeParent(satsystem::payload::SUBSYSTEM);
|
||||
}
|
||||
|
||||
void ObjectFactory::createTestComponents(LinuxLibgpioIF* gpioComIF) {
|
||||
@ -921,24 +931,47 @@ void ObjectFactory::createTestComponents(LinuxLibgpioIF* gpioComIF) {
|
||||
}
|
||||
|
||||
void ObjectFactory::createStrComponents(PowerSwitchIF* pwrSwitcher) {
|
||||
auto* strAssy = new StrAssembly(objects::STR_ASSY);
|
||||
strAssy->connectModeTreeParent(satsystem::acs::ACS_SUBSYSTEM);
|
||||
auto* starTrackerCookie =
|
||||
new SerialCookie(objects::STAR_TRACKER, q7s::UART_STAR_TRACKER_DEV, uart::STAR_TRACKER_BAUD,
|
||||
startracker::MAX_FRAME_SIZE * 2 + 2, UartModes::NON_CANONICAL);
|
||||
starTrackerCookie->setNoFixedSizeReply();
|
||||
StrHelper* strHelper = new StrHelper(objects::STR_HELPER);
|
||||
|
||||
const char* paramJsonFile = nullptr;
|
||||
#ifdef EGSE
|
||||
paramJsonFile = "/home/pi/arcsec/json/flight-config.json";
|
||||
#else
|
||||
#if OBSW_STAR_TRACKER_GROUND_CONFIG == 1
|
||||
paramJsonFile = "/mnt/sd0/startracker/ground-config.json";
|
||||
#else
|
||||
paramJsonFile = "/mnt/sd0/startracker/flight-config.json";
|
||||
#endif
|
||||
#endif
|
||||
if (paramJsonFile == nullptr) {
|
||||
sif::error << "No valid Star Tracker parameter JSON file" << std::endl;
|
||||
}
|
||||
auto strFdir = new StrFdir(objects::STAR_TRACKER);
|
||||
auto starTracker =
|
||||
new StarTrackerHandler(objects::STAR_TRACKER, objects::UART_COM_IF, starTrackerCookie,
|
||||
strHelper, pcdu::PDU1_CH2_STAR_TRACKER_5V);
|
||||
paramJsonFile, strHelper, pcdu::PDU1_CH2_STAR_TRACKER_5V);
|
||||
starTracker->setPowerSwitcher(pwrSwitcher);
|
||||
starTracker->connectModeTreeParent(satsystem::acs::ACS_SUBSYSTEM);
|
||||
starTracker->connectModeTreeParent(*strAssy);
|
||||
starTracker->setCustomFdir(strFdir);
|
||||
}
|
||||
|
||||
void ObjectFactory::createImtqComponents(PowerSwitchIF* pwrSwitcher) {
|
||||
I2cCookie* imtqI2cCookie = new I2cCookie(addresses::IMTQ, IMTQ::MAX_REPLY_SIZE, q7s::I2C_PL_EIVE);
|
||||
auto imtqHandler = new ImtqHandler(objects::IMTQ_HANDLER, objects::I2C_COM_IF, imtqI2cCookie,
|
||||
auto* imtqAssy = new ImtqAssembly(objects::IMTQ_ASSY);
|
||||
imtqAssy->connectModeTreeParent(satsystem::acs::ACS_SUBSYSTEM);
|
||||
|
||||
new ImtqPollingTask(objects::IMTQ_POLLING, I2C_FATAL_ERRORS);
|
||||
I2cCookie* imtqI2cCookie = new I2cCookie(addresses::IMTQ, imtq::MAX_REPLY_SIZE, q7s::I2C_PL_EIVE);
|
||||
auto imtqHandler = new ImtqHandler(objects::IMTQ_HANDLER, objects::IMTQ_POLLING, imtqI2cCookie,
|
||||
pcdu::Switches::PDU1_CH3_MGT_5V);
|
||||
imtqHandler->enableThermalModule(ThermalStateCfg());
|
||||
imtqHandler->setPowerSwitcher(pwrSwitcher);
|
||||
imtqHandler->connectModeTreeParent(satsystem::acs::ACS_SUBSYSTEM);
|
||||
imtqHandler->connectModeTreeParent(*imtqAssy);
|
||||
static_cast<void>(imtqHandler);
|
||||
#if OBSW_TEST_IMTQ == 1
|
||||
imtqHandler->setStartUpImmediately();
|
||||
|
@ -2,11 +2,16 @@
|
||||
#define BSP_Q7S_OBJECTFACTORY_H_
|
||||
|
||||
#include <fsfw/returnvalues/returnvalue.h>
|
||||
#include <fsfw_hal/linux/spi/SpiComIF.h>
|
||||
#include <mission/core/GenericFactory.h>
|
||||
#include <mission/devices/HeaterHandler.h>
|
||||
#include <mission/system/objects/Stack5VHandler.h>
|
||||
#include <mission/tmtc/CcsdsIpCoreHandler.h>
|
||||
#include <mission/tmtc/CfdpTmFunnel.h>
|
||||
#include <mission/tmtc/PersistentLogTmStoreTask.h>
|
||||
#include <mission/tmtc/PusTmFunnel.h>
|
||||
|
||||
#include <atomic>
|
||||
#include <string>
|
||||
|
||||
class LinuxLibgpioIF;
|
||||
@ -18,22 +23,46 @@ class HealthTableIF;
|
||||
class AcsBoardAssembly;
|
||||
class GpioIF;
|
||||
|
||||
extern std::atomic_uint16_t I2C_FATAL_ERRORS;
|
||||
|
||||
namespace ObjectFactory {
|
||||
|
||||
struct CcsdsComponentArgs {
|
||||
CcsdsComponentArgs(LinuxLibgpioIF& gpioIF, StorageManagerIF& ipcStore, StorageManagerIF& tmStore,
|
||||
PersistentTmStores& stores, PusTmFunnel& pusFunnel, CfdpTmFunnel& cfdpFunnel,
|
||||
CcsdsIpCoreHandler** ipCoreHandler)
|
||||
: gpioComIF(gpioIF),
|
||||
ipcStore(ipcStore),
|
||||
tmStore(tmStore),
|
||||
stores(stores),
|
||||
pusFunnel(pusFunnel),
|
||||
cfdpFunnel(cfdpFunnel),
|
||||
ipCoreHandler(ipCoreHandler) {}
|
||||
LinuxLibgpioIF& gpioComIF;
|
||||
StorageManagerIF& ipcStore;
|
||||
StorageManagerIF& tmStore;
|
||||
PersistentTmStores& stores;
|
||||
PusTmFunnel& pusFunnel;
|
||||
CfdpTmFunnel& cfdpFunnel;
|
||||
CcsdsIpCoreHandler** ipCoreHandler;
|
||||
AcceptsTelemetryIF* liveDestination = nullptr;
|
||||
};
|
||||
|
||||
void setStatics();
|
||||
void produce(void* args);
|
||||
|
||||
void createCommunicationInterfaces(LinuxLibgpioIF** gpioComIF, SerialComIF** uartComIF,
|
||||
SpiComIF** spiMainComIF, I2cComIF** i2cComIF,
|
||||
SpiComIF** spiRwComIF);
|
||||
SpiComIF** spiMainComIF, I2cComIF** i2cComIF);
|
||||
void createPcduComponents(LinuxLibgpioIF* gpioComIF, PowerSwitchIF** pwrSwitcher);
|
||||
void createPlPcduComponents(LinuxLibgpioIF* gpioComIF, SpiComIF* spiComIF,
|
||||
PowerSwitchIF* pwrSwitcher, Stack5VHandler& stackHandler);
|
||||
void createTmpComponents();
|
||||
ReturnValue_t createRadSensorComponent(LinuxLibgpioIF* gpioComIF, Stack5VHandler& handler);
|
||||
void createAcsBoardComponents(LinuxLibgpioIF* gpioComIF, SerialComIF* uartComIF,
|
||||
PowerSwitchIF* pwrSwitcher);
|
||||
void createHeaterComponents(GpioIF* gpioIF, PowerSwitchIF* pwrSwitcher, HealthTableIF* healthTable);
|
||||
void createAcsBoardGpios(GpioCookie& cookie);
|
||||
void createAcsBoardComponents(SpiComIF& spiComIF, LinuxLibgpioIF* gpioComIF, SerialComIF* uartComIF,
|
||||
PowerSwitchIF& pwrSwitcher);
|
||||
void createHeaterComponents(GpioIF* gpioIF, PowerSwitchIF* pwrSwitcher, HealthTableIF* healthTable,
|
||||
HeaterHandler*& heaterHandler);
|
||||
void createImtqComponents(PowerSwitchIF* pwrSwitcher);
|
||||
void createBpxBatteryComponent();
|
||||
void createStrComponents(PowerSwitchIF* pwrSwitcher);
|
||||
@ -41,7 +70,7 @@ void createSolarArrayDeploymentComponents(PowerSwitchIF& pwrSwitcher, GpioIF& gp
|
||||
void createSyrlinksComponents(PowerSwitchIF* pwrSwitcher);
|
||||
void createPayloadComponents(LinuxLibgpioIF* gpioComIF, PowerSwitchIF& pwrSwitcher);
|
||||
void createReactionWheelComponents(LinuxLibgpioIF* gpioComIF, PowerSwitchIF* pwrSwitcher);
|
||||
ReturnValue_t createCcsdsComponents(LinuxLibgpioIF* gpioComIF, CcsdsIpCoreHandler** ipCoreHandler);
|
||||
ReturnValue_t createCcsdsComponents(CcsdsComponentArgs& args);
|
||||
void createMiscComponents();
|
||||
|
||||
void createTestComponents(LinuxLibgpioIF* gpioComIF);
|
||||
|
87
bsp_q7s/core/WatchdogHandler.cpp
Normal file
87
bsp_q7s/core/WatchdogHandler.cpp
Normal file
@ -0,0 +1,87 @@
|
||||
#include "WatchdogHandler.h"
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include <cerrno>
|
||||
#include <cstring>
|
||||
#include <filesystem>
|
||||
|
||||
#include "fsfw/serviceinterface.h"
|
||||
#include "watchdog/definitions.h"
|
||||
|
||||
WatchdogHandler::WatchdogHandler() {}
|
||||
|
||||
void WatchdogHandler::periodicOperation() {
|
||||
if (watchdogFifoFd != 0) {
|
||||
if (watchdogFifoFd == RETRY_FIFO_OPEN) {
|
||||
// Open FIFO write only and non-blocking
|
||||
watchdogFifoFd = open(watchdog::FIFO_NAME.c_str(), O_WRONLY | O_NONBLOCK);
|
||||
if (watchdogFifoFd < 0) {
|
||||
if (errno == ENXIO) {
|
||||
watchdogFifoFd = RETRY_FIFO_OPEN;
|
||||
// No printout for now, would be spam
|
||||
return;
|
||||
} else {
|
||||
sif::error << "Opening pipe " << watchdog::FIFO_NAME << " write-only failed with "
|
||||
<< errno << ": " << strerror(errno) << std::endl;
|
||||
return;
|
||||
}
|
||||
}
|
||||
sif::info << "Opened " << watchdog::FIFO_NAME << " successfully" << std::endl;
|
||||
performStartHandling();
|
||||
} else if (watchdogFifoFd > 0) {
|
||||
// Write to OBSW watchdog FIFO here
|
||||
const char writeChar = watchdog::first::IDLE_CHAR;
|
||||
ssize_t writtenBytes = write(watchdogFifoFd, &writeChar, 1);
|
||||
if (writtenBytes < 0) {
|
||||
sif::error << "Errors writing to watchdog FIFO, code " << errno << ": " << strerror(errno)
|
||||
<< std::endl;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ReturnValue_t WatchdogHandler::initialize(bool enableWatchdogFunction) {
|
||||
using namespace std::filesystem;
|
||||
this->enableWatchFunction = enableWatchdogFunction;
|
||||
std::error_code e;
|
||||
if (not std::filesystem::exists(watchdog::FIFO_NAME, e)) {
|
||||
// Still return returnvalue::OK for now
|
||||
sif::info << "Watchdog FIFO " << watchdog::FIFO_NAME << " does not exist, can't initiate"
|
||||
<< " watchdog" << std::endl;
|
||||
return returnvalue::OK;
|
||||
}
|
||||
// Open FIFO write only and non-blocking to prevent SW from killing itself.
|
||||
watchdogFifoFd = open(watchdog::FIFO_NAME.c_str(), O_WRONLY | O_NONBLOCK);
|
||||
if (watchdogFifoFd < 0) {
|
||||
if (errno == ENXIO) {
|
||||
watchdogFifoFd = RETRY_FIFO_OPEN;
|
||||
sif::info << "eive-watchdog not running. FIFO can not be opened" << std::endl;
|
||||
} else {
|
||||
sif::error << "Opening pipe " << watchdog::FIFO_NAME << " write-only failed with " << errno
|
||||
<< ": " << strerror(errno) << std::endl;
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
}
|
||||
return performStartHandling();
|
||||
}
|
||||
|
||||
ReturnValue_t WatchdogHandler::performStartHandling() {
|
||||
char startBuf[2];
|
||||
ssize_t writeLen = 1;
|
||||
startBuf[0] = watchdog::first::START_CHAR;
|
||||
if (enableWatchFunction) {
|
||||
writeLen += 1;
|
||||
startBuf[1] = watchdog::second::WATCH_FLAG;
|
||||
}
|
||||
ssize_t writtenBytes = write(watchdogFifoFd, &startBuf, writeLen);
|
||||
if (writtenBytes < 0) {
|
||||
sif::error << "WatchdogHandler: Errors writing to watchdog FIFO, code " << errno << ": "
|
||||
<< strerror(errno) << std::endl;
|
||||
return returnvalue::FAILED;
|
||||
} else if (writtenBytes != writeLen) {
|
||||
sif::warning << "WatchdogHandler: Not all bytes were written, possible error" << std::endl;
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
23
bsp_q7s/core/WatchdogHandler.h
Normal file
23
bsp_q7s/core/WatchdogHandler.h
Normal file
@ -0,0 +1,23 @@
|
||||
#ifndef BSP_Q7S_CORE_WATCHDOGHANDLER_H_
|
||||
#define BSP_Q7S_CORE_WATCHDOGHANDLER_H_
|
||||
|
||||
#include "fsfw/returnvalues/returnvalue.h"
|
||||
|
||||
class WatchdogHandler {
|
||||
public:
|
||||
WatchdogHandler();
|
||||
|
||||
ReturnValue_t initialize(bool enableWatchFunction);
|
||||
void periodicOperation();
|
||||
|
||||
private:
|
||||
// Designated value for rechecking FIFO open
|
||||
static constexpr int RETRY_FIFO_OPEN = -2;
|
||||
|
||||
int watchdogFifoFd = 0;
|
||||
bool enableWatchFunction = false;
|
||||
|
||||
ReturnValue_t performStartHandling();
|
||||
};
|
||||
|
||||
#endif /* BSP_Q7S_CORE_WATCHDOGHANDLER_H_ */
|
@ -17,9 +17,10 @@
|
||||
#include "fsfw/tasks/FixedTimeslotTaskIF.h"
|
||||
#include "fsfw/tasks/PeriodicTaskIF.h"
|
||||
#include "fsfw/tasks/TaskFactory.h"
|
||||
#include "mission/core/pollingSeqTables.h"
|
||||
#include "mission/core/scheduling.h"
|
||||
#include "mission/devices/devicedefinitions/Max31865Definitions.h"
|
||||
#include "mission/utility/InitMission.h"
|
||||
#include "pollingsequence/pollingSequenceFactory.h"
|
||||
|
||||
/* This is configured for linux without CR */
|
||||
#ifdef PLATFORM_UNIX
|
||||
@ -79,16 +80,12 @@ void scheduling::initTasks() {
|
||||
}
|
||||
#endif
|
||||
|
||||
PeriodicTaskIF* sysTask = factory->createPeriodicTask(
|
||||
PeriodicTaskIF* coreCtrlTask = factory->createPeriodicTask(
|
||||
"CORE_CTRL", 60, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.4, missedDeadlineFunc);
|
||||
result = sysTask->addComponent(objects::CORE_CONTROLLER);
|
||||
result = coreCtrlTask->addComponent(objects::CORE_CONTROLLER);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("CORE_CTRL", objects::CORE_CONTROLLER);
|
||||
}
|
||||
result = sysTask->addComponent(objects::PL_SUBSYSTEM);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PL_SUBSYSTEM", objects::PL_SUBSYSTEM);
|
||||
}
|
||||
|
||||
/* TMTC Distribution */
|
||||
PeriodicTaskIF* tmTcDistributor = factory->createPeriodicTask(
|
||||
@ -119,10 +116,6 @@ void scheduling::initTasks() {
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("CFDP_DISTRIBUTOR", objects::CFDP_DISTRIBUTOR);
|
||||
}
|
||||
result = tmTcDistributor->addComponent(objects::TM_FUNNEL);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("TM_FUNNEL", objects::TM_FUNNEL);
|
||||
}
|
||||
|
||||
#if OBSW_ADD_TCPIP_SERVERS == 1
|
||||
#if OBSW_ADD_TMTC_UDP_SERVER == 1
|
||||
@ -143,14 +136,35 @@ void scheduling::initTasks() {
|
||||
#endif
|
||||
#endif
|
||||
|
||||
PeriodicTaskIF* comTask = factory->createPeriodicTask(
|
||||
"CCSDS_HANDLER", 50, PeriodicTaskIF::MINIMUM_STACK_SIZE, 2.0, missedDeadlineFunc);
|
||||
result = comTask->addComponent(objects::COM_SUBSYSTEM);
|
||||
PeriodicTaskIF* genericSysTask = factory->createPeriodicTask(
|
||||
"SYSTEM_TASK", 50, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.5, missedDeadlineFunc);
|
||||
result = genericSysTask->addComponent(objects::EIVE_SYSTEM);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("COM subsystem", objects::COM_SUBSYSTEM);
|
||||
scheduling::printAddObjectError("EIVE_SYSTEM", objects::EIVE_SYSTEM);
|
||||
}
|
||||
result = genericSysTask->addComponent(objects::COM_SUBSYSTEM);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("COM_SUBSYSTEM", objects::COM_SUBSYSTEM);
|
||||
}
|
||||
result = genericSysTask->addComponent(objects::SYRLINKS_ASSY);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("SYRLINKS_ASSY", objects::SYRLINKS_ASSY);
|
||||
}
|
||||
result = genericSysTask->addComponent(objects::PL_SUBSYSTEM);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PL_SUBSYSTEM", objects::PL_SUBSYSTEM);
|
||||
}
|
||||
result = genericSysTask->addComponent(objects::INTERNAL_ERROR_REPORTER);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("ERROR_REPORTER", objects::INTERNAL_ERROR_REPORTER);
|
||||
}
|
||||
result = genericSysTask->addComponent(objects::PUS_SERVICE_17_TEST);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_17", objects::PUS_SERVICE_17_TEST);
|
||||
}
|
||||
|
||||
#if OBSW_ADD_CCSDS_IP_CORES == 1
|
||||
result = comTask->addComponent(objects::CCSDS_HANDLER);
|
||||
result = genericSysTask->addComponent(objects::CCSDS_HANDLER);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("CCSDS Handler", objects::CCSDS_HANDLER);
|
||||
}
|
||||
@ -162,7 +176,33 @@ void scheduling::initTasks() {
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PDEC Handler", objects::PDEC_HANDLER);
|
||||
}
|
||||
|
||||
#endif /* OBSW_ADD_CCSDS_IP_CORE == 1 */
|
||||
// All the TM store tasks run in permanent loops, frequency does not matter
|
||||
PeriodicTaskIF* liveTmTask =
|
||||
factory->createPeriodicTask("LIVE_TM", 55, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.0, nullptr);
|
||||
result = liveTmTask->addComponent(objects::LIVE_TM_TASK);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("LIVE_TM", objects::LIVE_TM_TASK);
|
||||
}
|
||||
PeriodicTaskIF* logTmTask = factory->createPeriodicTask(
|
||||
"LOG_STORE_AND_TM", 45, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.0, nullptr);
|
||||
result = logTmTask->addComponent(objects::LOG_STORE_AND_TM_TASK);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("LOG_STORE_AND_TM", objects::LOG_STORE_AND_TM_TASK);
|
||||
}
|
||||
PeriodicTaskIF* hkTmTask = factory->createPeriodicTask(
|
||||
"HK_STORE_AND_TM", 45, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.0, nullptr);
|
||||
result = hkTmTask->addComponent(objects::HK_STORE_AND_TM_TASK);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("HK_STORE_AND_TM", objects::HK_STORE_AND_TM_TASK);
|
||||
}
|
||||
PeriodicTaskIF* cfdpTmTask = factory->createPeriodicTask(
|
||||
"CFDP_STORE_AND_TM", 45, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.0, nullptr);
|
||||
result = cfdpTmTask->addComponent(objects::CFDP_STORE_AND_TM_TASK);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("CFDP_STORE_AND_TM", objects::CFDP_STORE_AND_TM_TASK);
|
||||
}
|
||||
|
||||
#if OBSW_ADD_CFDP_COMPONENTS == 1
|
||||
PeriodicTaskIF* cfdpTask = factory->createPeriodicTask(
|
||||
@ -173,127 +213,86 @@ void scheduling::initTasks() {
|
||||
}
|
||||
#endif
|
||||
|
||||
PeriodicTaskIF* acsCtrlTask = factory->createPeriodicTask(
|
||||
"ACS_TASK", 50, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 0.4, missedDeadlineFunc);
|
||||
#if OBSW_ADD_GPS_CTRL == 1
|
||||
result = acsCtrlTask->addComponent(objects::GPS_CONTROLLER);
|
||||
PeriodicTaskIF* gpsTask = factory->createPeriodicTask(
|
||||
"GPS_TASK", 50, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 0.4, missedDeadlineFunc);
|
||||
result = gpsTask->addComponent(objects::GPS_CONTROLLER);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("GPS_CTRL", objects::GPS_CONTROLLER);
|
||||
}
|
||||
#endif /* OBSW_ADD_GPS_CTRL */
|
||||
|
||||
#if OBSW_ADD_ACS_CTRL == 1
|
||||
acsCtrlTask->addComponent(objects::ACS_CONTROLLER);
|
||||
#if OBSW_ADD_ACS_BOARD == 1
|
||||
PeriodicTaskIF* acsBrdPolling = factory->createPeriodicTask(
|
||||
"ACS_BOARD_POLLING", 85, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 0.4, missedDeadlineFunc);
|
||||
result = acsBrdPolling->addComponent(objects::ACS_BOARD_POLLING_TASK);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("ACS_CTRL", objects::ACS_CONTROLLER);
|
||||
scheduling::printAddObjectError("ACS_BOARD_POLLING", objects::ACS_BOARD_POLLING_TASK);
|
||||
}
|
||||
#endif
|
||||
#if OBSW_Q7S_EM == 1
|
||||
acsCtrlTask->addComponent(objects::MGM_0_LIS3_HANDLER);
|
||||
acsCtrlTask->addComponent(objects::MGM_1_RM3100_HANDLER);
|
||||
acsCtrlTask->addComponent(objects::MGM_2_LIS3_HANDLER);
|
||||
acsCtrlTask->addComponent(objects::MGM_3_RM3100_HANDLER);
|
||||
acsCtrlTask->addComponent(objects::IMTQ_HANDLER);
|
||||
acsCtrlTask->addComponent(objects::SUS_0_N_LOC_XFYFZM_PT_XF);
|
||||
acsCtrlTask->addComponent(objects::SUS_6_R_LOC_XFYBZM_PT_XF);
|
||||
acsCtrlTask->addComponent(objects::SUS_1_N_LOC_XBYFZM_PT_XB);
|
||||
acsCtrlTask->addComponent(objects::SUS_7_R_LOC_XBYBZM_PT_XB);
|
||||
acsCtrlTask->addComponent(objects::SUS_2_N_LOC_XFYBZB_PT_YB);
|
||||
acsCtrlTask->addComponent(objects::SUS_8_R_LOC_XBYBZB_PT_YB);
|
||||
acsCtrlTask->addComponent(objects::SUS_3_N_LOC_XFYBZF_PT_YF);
|
||||
acsCtrlTask->addComponent(objects::SUS_9_R_LOC_XBYBZB_PT_YF);
|
||||
acsCtrlTask->addComponent(objects::SUS_4_N_LOC_XMYFZF_PT_ZF);
|
||||
acsCtrlTask->addComponent(objects::SUS_10_N_LOC_XMYBZF_PT_ZF);
|
||||
acsCtrlTask->addComponent(objects::SUS_5_N_LOC_XFYMZB_PT_ZB);
|
||||
acsCtrlTask->addComponent(objects::SUS_11_R_LOC_XBYMZB_PT_ZB);
|
||||
acsCtrlTask->addComponent(objects::GYRO_0_ADIS_HANDLER);
|
||||
acsCtrlTask->addComponent(objects::GYRO_1_L3G_HANDLER);
|
||||
acsCtrlTask->addComponent(objects::GYRO_2_ADIS_HANDLER);
|
||||
acsCtrlTask->addComponent(objects::GYRO_3_L3G_HANDLER);
|
||||
acsCtrlTask->addComponent(objects::GPS_CONTROLLER);
|
||||
acsCtrlTask->addComponent(objects::STAR_TRACKER);
|
||||
acsCtrlTask->addComponent(objects::RW1);
|
||||
acsCtrlTask->addComponent(objects::RW2);
|
||||
acsCtrlTask->addComponent(objects::RW3);
|
||||
acsCtrlTask->addComponent(objects::RW4);
|
||||
|
||||
#if OBSW_ADD_RW == 1
|
||||
PeriodicTaskIF* rwPolling = factory->createPeriodicTask(
|
||||
"RW_POLLING_TASK", 85, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 0.4, missedDeadlineFunc);
|
||||
result = rwPolling->addComponent(objects::RW_POLLING_TASK);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("RW_POLLING_TASK", objects::RW_POLLING_TASK);
|
||||
}
|
||||
#endif
|
||||
#if OBSW_ADD_MGT == 1
|
||||
PeriodicTaskIF* imtqPolling = factory->createPeriodicTask(
|
||||
"IMTQ_POLLING_TASK", 85, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 0.4, missedDeadlineFunc);
|
||||
result = imtqPolling->addComponent(objects::IMTQ_POLLING);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("IMTQ_POLLING_TASK", objects::IMTQ_POLLING);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if OBSW_ADD_SUN_SENSORS == 1
|
||||
PeriodicTaskIF* susPolling = factory->createPeriodicTask(
|
||||
"SUS_POLLING_TASK", 85, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 0.4, missedDeadlineFunc);
|
||||
result = susPolling->addComponent(objects::SUS_POLLING_TASK);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("SUS_POLLING_TASK", objects::SUS_POLLING_TASK);
|
||||
}
|
||||
#endif
|
||||
|
||||
PeriodicTaskIF* acsSysTask = factory->createPeriodicTask(
|
||||
"SYS_TASK", 40, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 0.4, missedDeadlineFunc);
|
||||
static_cast<void>(acsSysTask);
|
||||
#if OBSW_ADD_ACS_BOARD == 1
|
||||
result = acsSysTask->addComponent(objects::ACS_BOARD_ASS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("ACS_BOARD_ASS", objects::ACS_BOARD_ASS);
|
||||
}
|
||||
#endif /* OBSW_ADD_ACS_HANDLERS */
|
||||
#if OBSW_ADD_RW == 1
|
||||
result = acsSysTask->addComponent(objects::RW_ASS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("RW_ASS", objects::RW_ASS);
|
||||
}
|
||||
#endif
|
||||
#if OBSW_ADD_SUS_BOARD_ASS == 1
|
||||
result = acsSysTask->addComponent(objects::SUS_BOARD_ASS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("SUS_BOARD_ASS", objects::SUS_BOARD_ASS);
|
||||
}
|
||||
#endif
|
||||
"ACS_SYS_TASK", 55, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 0.4, missedDeadlineFunc);
|
||||
result = acsSysTask->addComponent(objects::ACS_SUBSYSTEM);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("ACS_SUBSYSTEM", objects::ACS_SUBSYSTEM);
|
||||
}
|
||||
|
||||
#if OBSW_ADD_RTD_DEVICES == 1
|
||||
PeriodicTaskIF* tcsPollingTask = factory->createPeriodicTask(
|
||||
"TCS_POLLING_TASK", 70, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 0.5, missedDeadlineFunc);
|
||||
result = tcsPollingTask->addComponent(objects::SPI_RTD_COM_IF);
|
||||
result = acsSysTask->addComponent(objects::IMTQ_ASSY);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("SPI_RTD_POLLING", objects::SPI_RTD_COM_IF);
|
||||
scheduling::printAddObjectError("IMTQ_ASSY", objects::IMTQ_ASSY);
|
||||
}
|
||||
|
||||
PeriodicTaskIF* tcsTask = factory->createPeriodicTask(
|
||||
"TCS_TASK", 45, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.8, missedDeadlineFunc);
|
||||
std::array<object_id_t, EiveMax31855::NUM_RTDS> rtdIds = {
|
||||
objects::RTD_0_IC3_PLOC_HEATSPREADER,
|
||||
objects::RTD_1_IC4_PLOC_MISSIONBOARD,
|
||||
objects::RTD_2_IC5_4K_CAMERA,
|
||||
objects::RTD_3_IC6_DAC_HEATSPREADER,
|
||||
objects::RTD_4_IC7_STARTRACKER,
|
||||
objects::RTD_5_IC8_RW1_MX_MY,
|
||||
objects::RTD_6_IC9_DRO,
|
||||
objects::RTD_7_IC10_SCEX,
|
||||
objects::RTD_8_IC11_X8,
|
||||
objects::RTD_9_IC12_HPA,
|
||||
objects::RTD_10_IC13_PL_TX,
|
||||
objects::RTD_11_IC14_MPA,
|
||||
objects::RTD_12_IC15_ACU,
|
||||
objects::RTD_13_IC16_PLPCDU_HEATSPREADER,
|
||||
objects::RTD_14_IC17_TCS_BOARD,
|
||||
objects::RTD_15_IC18_IMTQ,
|
||||
};
|
||||
|
||||
for (const auto& rtd : rtdIds) {
|
||||
tcsTask->addComponent(rtd, DeviceHandlerIF::PERFORM_OPERATION);
|
||||
tcsTask->addComponent(rtd, DeviceHandlerIF::SEND_WRITE);
|
||||
tcsTask->addComponent(rtd, DeviceHandlerIF::GET_WRITE);
|
||||
tcsTask->addComponent(rtd, DeviceHandlerIF::SEND_READ);
|
||||
tcsTask->addComponent(rtd, DeviceHandlerIF::GET_READ);
|
||||
result = acsSysTask->addComponent(objects::ACS_BOARD_ASS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("ACS_BOARD_ASS", objects::ACS_BOARD_ASS);
|
||||
}
|
||||
result = acsSysTask->addComponent(objects::RW_ASSY);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("RW_ASS", objects::RW_ASSY);
|
||||
}
|
||||
result = acsSysTask->addComponent(objects::SUS_BOARD_ASS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("SUS_BOARD_ASS", objects::SUS_BOARD_ASS);
|
||||
}
|
||||
result = acsSysTask->addComponent(objects::STR_ASSY);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("STR_ASSY", objects::STR_ASSY);
|
||||
}
|
||||
#endif
|
||||
|
||||
PeriodicTaskIF* tcsSystemTask = factory->createPeriodicTask(
|
||||
"TCS_TASK", 45, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.5, missedDeadlineFunc);
|
||||
"TCS_TASK", 55, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.5, missedDeadlineFunc);
|
||||
scheduling::scheduleRtdSensors(tcsSystemTask);
|
||||
result = tcsSystemTask->addComponent(objects::TCS_SUBSYSTEM);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("TCS_SUBSYSTEM", objects::TCS_SUBSYSTEM);
|
||||
}
|
||||
#if OBSW_ADD_RTD_DEVICES == 1
|
||||
result = tcsSystemTask->addComponent(objects::TCS_BOARD_ASS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("TCS_BOARD_ASS", objects::TCS_BOARD_ASS);
|
||||
}
|
||||
#endif /* OBSW_ADD_RTD_DEVICES */
|
||||
#if OBSW_ADD_TCS_CTRL == 1
|
||||
result = tcsSystemTask->addComponent(objects::THERMAL_CONTROLLER);
|
||||
if (result != returnvalue::OK) {
|
||||
@ -335,20 +334,21 @@ void scheduling::initTasks() {
|
||||
#endif /* OBSW_ADD_PLOC_SUPERVISOR */
|
||||
|
||||
PeriodicTaskIF* plTask = factory->createPeriodicTask(
|
||||
"PL_TASK", 25, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.0, missedDeadlineFunc);
|
||||
scheduling::addMpsocSupvHandlers(plTask);
|
||||
"PL_TASK", 30, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.8, missedDeadlineFunc);
|
||||
plTask->addComponent(objects::CAM_SWITCHER);
|
||||
scheduling::addMpsocSupvHandlers(plTask);
|
||||
scheduling::scheduleScexDev(plTask);
|
||||
|
||||
#if OBSW_ADD_SCEX_DEVICE == 1
|
||||
PeriodicTaskIF* scexDevHandler;
|
||||
PeriodicTaskIF* scexReaderTask;
|
||||
scheduling::schedulingScex(*factory, scexDevHandler, scexReaderTask);
|
||||
scheduling::scheduleScexReader(*factory, scexReaderTask);
|
||||
#endif
|
||||
|
||||
std::vector<PeriodicTaskIF*> pusTasks;
|
||||
createPusTasks(*factory, missedDeadlineFunc, pusTasks);
|
||||
std::vector<PeriodicTaskIF*> pstTasks;
|
||||
createPstTasks(*factory, missedDeadlineFunc, pstTasks);
|
||||
AcsPstCfg cfg;
|
||||
createPstTasks(*factory, missedDeadlineFunc, pstTasks, cfg);
|
||||
|
||||
#if OBSW_ADD_TEST_CODE == 1
|
||||
#if OBSW_TEST_CCSDS_BRIDGE == 1
|
||||
@ -385,20 +385,32 @@ void scheduling::initTasks() {
|
||||
#endif
|
||||
#endif
|
||||
|
||||
comTask->startTask();
|
||||
genericSysTask->startTask();
|
||||
#if OBSW_ADD_CCSDS_IP_CORES == 1
|
||||
pdecHandlerTask->startTask();
|
||||
#endif /* OBSW_ADD_CCSDS_IP_CORES == 1 */
|
||||
liveTmTask->startTask();
|
||||
logTmTask->startTask();
|
||||
hkTmTask->startTask();
|
||||
cfdpTmTask->startTask();
|
||||
|
||||
sysTask->startTask();
|
||||
coreCtrlTask->startTask();
|
||||
#if OBSW_ADD_SA_DEPL == 1
|
||||
solarArrayDeplTask->startTask();
|
||||
#endif
|
||||
#if OBSW_ADD_ACS_BOARD == 1
|
||||
acsBrdPolling->startTask();
|
||||
#endif
|
||||
#if OBSW_ADD_MGT == 1
|
||||
imtqPolling->startTask();
|
||||
#endif
|
||||
#if OBSW_ADD_SUN_SENSORS == 1
|
||||
susPolling->startTask();
|
||||
#endif
|
||||
|
||||
taskStarter(pstTasks, "PST task vector");
|
||||
taskStarter(pusTasks, "PUS task vector");
|
||||
#if OBSW_ADD_SCEX_DEVICE == 1
|
||||
scexDevHandler->startTask();
|
||||
scexReaderTask->startTask();
|
||||
#endif
|
||||
|
||||
@ -414,12 +426,11 @@ void scheduling::initTasks() {
|
||||
strHelperTask->startTask();
|
||||
#endif /* OBSW_ADD_STAR_TRACKER == 1 */
|
||||
|
||||
acsCtrlTask->startTask();
|
||||
#if OBSW_ADD_RW == 1
|
||||
rwPolling->startTask();
|
||||
#endif
|
||||
gpsTask->startTask();
|
||||
acsSysTask->startTask();
|
||||
#if OBSW_ADD_RTD_DEVICES == 1
|
||||
tcsPollingTask->startTask();
|
||||
tcsTask->startTask();
|
||||
#endif /* OBSW_ADD_RTD_DEVICES == 1 */
|
||||
if (not tcsSystemTask->isEmpty()) {
|
||||
tcsSystemTask->startTask();
|
||||
}
|
||||
@ -436,13 +447,32 @@ void scheduling::initTasks() {
|
||||
}
|
||||
|
||||
void scheduling::createPstTasks(TaskFactory& factory, TaskDeadlineMissedFunction missedDeadlineFunc,
|
||||
std::vector<PeriodicTaskIF*>& taskVec) {
|
||||
std::vector<PeriodicTaskIF*>& taskVec, AcsPstCfg cfg) {
|
||||
ReturnValue_t result = returnvalue::OK;
|
||||
|
||||
#ifdef RELEASE_BUILD
|
||||
static constexpr float acsPstPeriod = 0.4;
|
||||
#else
|
||||
static constexpr float acsPstPeriod = 0.4;
|
||||
#endif
|
||||
FixedTimeslotTaskIF* acsTcsPst = factory.createFixedTimeslotTask(
|
||||
"ACS_TCS_PST", 80, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, acsPstPeriod, missedDeadlineFunc);
|
||||
result = pst::pstTcsAndAcs(acsTcsPst, cfg);
|
||||
if (result != returnvalue::OK) {
|
||||
if (result == FixedTimeslotTaskIF::SLOT_LIST_EMPTY) {
|
||||
sif::warning << "scheduling::initTasks: ACS PST is empty" << std::endl;
|
||||
} else {
|
||||
sif::error << "scheduling::initTasks: Creating ACS PST failed!" << std::endl;
|
||||
}
|
||||
} else {
|
||||
taskVec.push_back(acsTcsPst);
|
||||
}
|
||||
|
||||
/* Polling Sequence Table Default */
|
||||
#if OBSW_ADD_SPI_TEST_CODE == 0
|
||||
FixedTimeslotTaskIF* spiPst = factory.createFixedTimeslotTask(
|
||||
"MAIN_SPI", 75, PeriodicTaskIF::MINIMUM_STACK_SIZE * 4, 0.5, missedDeadlineFunc);
|
||||
result = pst::pstSpi(spiPst);
|
||||
FixedTimeslotTaskIF* syrlinksPst = factory.createFixedTimeslotTask(
|
||||
"SYRLINKS", 45, PeriodicTaskIF::MINIMUM_STACK_SIZE * 4, 0.5, missedDeadlineFunc);
|
||||
result = pst::pstSyrlinks(syrlinksPst);
|
||||
if (result != returnvalue::OK) {
|
||||
if (result == FixedTimeslotTaskIF::SLOT_LIST_EMPTY) {
|
||||
sif::warning << "scheduling::initTasks: SPI PST is empty" << std::endl;
|
||||
@ -450,42 +480,14 @@ void scheduling::createPstTasks(TaskFactory& factory, TaskDeadlineMissedFunction
|
||||
sif::error << "scheduling::initTasks: Creating SPI PST failed!" << std::endl;
|
||||
}
|
||||
} else {
|
||||
taskVec.push_back(spiPst);
|
||||
taskVec.push_back(syrlinksPst);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if OBSW_ADD_RW == 1
|
||||
FixedTimeslotTaskIF* rwPstTask = factory.createFixedTimeslotTask(
|
||||
"RW_SPI", 65, PeriodicTaskIF::MINIMUM_STACK_SIZE * 2, 1.0, missedDeadlineFunc);
|
||||
result = pst::pstSpiRw(rwPstTask);
|
||||
if (result != returnvalue::OK) {
|
||||
if (result == FixedTimeslotTaskIF::SLOT_LIST_EMPTY) {
|
||||
sif::warning << "scheduling::initTasks: SPI PST is empty" << std::endl;
|
||||
} else {
|
||||
sif::error << "scheduling::initTasks: Creating SPI PST failed!" << std::endl;
|
||||
}
|
||||
} else {
|
||||
taskVec.push_back(rwPstTask);
|
||||
}
|
||||
#endif
|
||||
|
||||
FixedTimeslotTaskIF* uartPst = factory.createFixedTimeslotTask(
|
||||
"UART_PST", 65, PeriodicTaskIF::MINIMUM_STACK_SIZE * 4, 0.2, missedDeadlineFunc);
|
||||
result = pst::pstUart(uartPst);
|
||||
if (result != returnvalue::OK) {
|
||||
if (result == FixedTimeslotTaskIF::SLOT_LIST_EMPTY) {
|
||||
sif::warning << "scheduling::initTasks: UART PST is empty" << std::endl;
|
||||
} else {
|
||||
sif::error << "scheduling::initTasks: Creating UART PST failed!" << std::endl;
|
||||
}
|
||||
} else {
|
||||
taskVec.push_back(uartPst);
|
||||
}
|
||||
|
||||
#if OBSW_ADD_I2C_TEST_CODE == 0
|
||||
FixedTimeslotTaskIF* i2cPst = factory.createFixedTimeslotTask(
|
||||
"I2C_PST", 65, PeriodicTaskIF::MINIMUM_STACK_SIZE * 4, 0.2, missedDeadlineFunc);
|
||||
result = pst::pstI2c(i2cPst);
|
||||
"I2C_PST", 50, PeriodicTaskIF::MINIMUM_STACK_SIZE * 4, 0.4, missedDeadlineFunc);
|
||||
result = pst::pstI2cProcessingSystem(i2cPst);
|
||||
if (result != returnvalue::OK) {
|
||||
if (result == FixedTimeslotTaskIF::SLOT_LIST_EMPTY) {
|
||||
sif::warning << "scheduling::initTasks: I2C PST is empty" << std::endl;
|
||||
@ -497,9 +499,8 @@ void scheduling::createPstTasks(TaskFactory& factory, TaskDeadlineMissedFunction
|
||||
}
|
||||
#endif
|
||||
|
||||
#if OBSW_ADD_GOMSPACE_PCDU == 1
|
||||
FixedTimeslotTaskIF* gomSpacePstTask = factory.createFixedTimeslotTask(
|
||||
"GS_PST_TASK", 70, PeriodicTaskIF::MINIMUM_STACK_SIZE * 4, 1.0, missedDeadlineFunc);
|
||||
"GS_PST_TASK", 65, PeriodicTaskIF::MINIMUM_STACK_SIZE * 4, 0.5, missedDeadlineFunc);
|
||||
result = pst::pstGompaceCan(gomSpacePstTask);
|
||||
if (result != returnvalue::OK) {
|
||||
if (result != FixedTimeslotTaskIF::SLOT_LIST_EMPTY) {
|
||||
@ -507,49 +508,34 @@ void scheduling::createPstTasks(TaskFactory& factory, TaskDeadlineMissedFunction
|
||||
}
|
||||
}
|
||||
taskVec.push_back(gomSpacePstTask);
|
||||
#endif
|
||||
}
|
||||
|
||||
void scheduling::createPusTasks(TaskFactory& factory, TaskDeadlineMissedFunction missedDeadlineFunc,
|
||||
std::vector<PeriodicTaskIF*>& taskVec) {
|
||||
ReturnValue_t result = returnvalue::OK;
|
||||
/* PUS Services */
|
||||
PeriodicTaskIF* pusVerification = factory.createPeriodicTask(
|
||||
"PUS_VERIF", 40, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.200, missedDeadlineFunc);
|
||||
result = pusVerification->addComponent(objects::PUS_SERVICE_1_VERIFICATION);
|
||||
PeriodicTaskIF* pusHighPrio = factory.createPeriodicTask(
|
||||
"PUS_HIGH_PRIO", 60, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.2, missedDeadlineFunc);
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_1_VERIFICATION);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_VERIF", objects::PUS_SERVICE_1_VERIFICATION);
|
||||
}
|
||||
taskVec.push_back(pusVerification);
|
||||
|
||||
PeriodicTaskIF* pusEvents = factory.createPeriodicTask(
|
||||
"PUS_EVENTS", 60, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.200, missedDeadlineFunc);
|
||||
result = pusEvents->addComponent(objects::PUS_SERVICE_5_EVENT_REPORTING);
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_5_EVENT_REPORTING);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_EVENTS", objects::PUS_SERVICE_5_EVENT_REPORTING);
|
||||
}
|
||||
result = pusEvents->addComponent(objects::EVENT_MANAGER);
|
||||
result = pusHighPrio->addComponent(objects::EVENT_MANAGER);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_MGMT", objects::EVENT_MANAGER);
|
||||
}
|
||||
taskVec.push_back(pusEvents);
|
||||
|
||||
PeriodicTaskIF* pusHighPrio = factory.createPeriodicTask(
|
||||
"PUS_HIGH_PRIO", 50, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.2, missedDeadlineFunc);
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_2_DEVICE_ACCESS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_2", objects::PUS_SERVICE_2_DEVICE_ACCESS);
|
||||
}
|
||||
result = pusHighPrio->addComponent(objects::PUS_SERVICE_9_TIME_MGMT);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_9", objects::PUS_SERVICE_9_TIME_MGMT);
|
||||
}
|
||||
|
||||
taskVec.push_back(pusHighPrio);
|
||||
|
||||
PeriodicTaskIF* pusMedPrio = factory.createPeriodicTask(
|
||||
"PUS_MED_PRIO", 40, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.8, missedDeadlineFunc);
|
||||
|
||||
result = pusMedPrio->addComponent(objects::PUS_SERVICE_3_HOUSEKEEPING);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_3", objects::PUS_SERVICE_3_HOUSEKEEPING);
|
||||
@ -558,6 +544,10 @@ void scheduling::createPusTasks(TaskFactory& factory, TaskDeadlineMissedFunction
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_8", objects::PUS_SERVICE_8_FUNCTION_MGMT);
|
||||
}
|
||||
result = pusMedPrio->addComponent(objects::PUS_SERVICE_15_TM_STORAGE);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_15", objects::PUS_SERVICE_15_TM_STORAGE);
|
||||
}
|
||||
result = pusMedPrio->addComponent(objects::PUS_SERVICE_11_TC_SCHEDULER);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_11", objects::PUS_SERVICE_11_TC_SCHEDULER);
|
||||
@ -574,20 +564,11 @@ void scheduling::createPusTasks(TaskFactory& factory, TaskDeadlineMissedFunction
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_201", objects::PUS_SERVICE_201_HEALTH);
|
||||
}
|
||||
// Used for connection tests, therefore use higher priority
|
||||
result = pusMedPrio->addComponent(objects::PUS_SERVICE_17_TEST);
|
||||
result = pusMedPrio->addComponent(objects::PUS_SERVICE_2_DEVICE_ACCESS);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("PUS_17", objects::PUS_SERVICE_17_TEST);
|
||||
scheduling::printAddObjectError("PUS_2", objects::PUS_SERVICE_2_DEVICE_ACCESS);
|
||||
}
|
||||
taskVec.push_back(pusMedPrio);
|
||||
|
||||
PeriodicTaskIF* pusLowPrio = factory.createPeriodicTask(
|
||||
"PUS_LOW_PRIO", 30, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.6, missedDeadlineFunc);
|
||||
result = pusLowPrio->addComponent(objects::INTERNAL_ERROR_REPORTER);
|
||||
if (result != returnvalue::OK) {
|
||||
scheduling::printAddObjectError("ERROR_REPORTER", objects::INTERNAL_ERROR_REPORTER);
|
||||
}
|
||||
taskVec.push_back(pusLowPrio);
|
||||
}
|
||||
|
||||
void scheduling::createTestTasks(TaskFactory& factory,
|
||||
|
@ -4,6 +4,9 @@
|
||||
#include <vector>
|
||||
|
||||
#include "fsfw/tasks/definitions.h"
|
||||
#include "mission/core/pollingSeqTables.h"
|
||||
|
||||
using pst::AcsPstCfg;
|
||||
|
||||
class PeriodicTaskIF;
|
||||
class TaskFactory;
|
||||
@ -13,7 +16,7 @@ void initMission();
|
||||
void initTasks();
|
||||
|
||||
void createPstTasks(TaskFactory& factory, TaskDeadlineMissedFunction missedDeadlineFunc,
|
||||
std::vector<PeriodicTaskIF*>& taskVec);
|
||||
std::vector<PeriodicTaskIF*>& taskVec, AcsPstCfg cfg);
|
||||
void createPusTasks(TaskFactory& factory, TaskDeadlineMissedFunction missedDeadlineFunc,
|
||||
std::vector<PeriodicTaskIF*>& taskVec);
|
||||
void createTestTasks(TaskFactory& factory, TaskDeadlineMissedFunction missedDeadlineFunc,
|
||||
|
@ -1,7 +1,12 @@
|
||||
#include <bsp_q7s/callbacks/q7sGpioCallbacks.h>
|
||||
#include <dummies/ComCookieDummy.h>
|
||||
#include <dummies/PcduHandlerDummy.h>
|
||||
#include <fsfw/health/HealthTableIF.h>
|
||||
#include <fsfw/power/DummyPowerSwitcher.h>
|
||||
#include <fsfw_hal/common/gpio/GpioCookie.h>
|
||||
#include <mission/devices/devicedefinitions/GomspaceDefinitions.h>
|
||||
#include <mission/system/tree/system.h>
|
||||
#include <mission/utility/DummySdCardManager.h>
|
||||
|
||||
#include "OBSWConfig.h"
|
||||
#include "bsp_q7s/core/CoreController.h"
|
||||
@ -21,14 +26,18 @@ void ObjectFactory::produce(void* args) {
|
||||
HealthTableIF* healthTable = nullptr;
|
||||
PusTmFunnel* pusFunnel = nullptr;
|
||||
CfdpTmFunnel* cfdpFunnel = nullptr;
|
||||
ObjectFactory::produceGenericObjects(&healthTable, &pusFunnel, &cfdpFunnel);
|
||||
StorageManagerIF* ipcStore = nullptr;
|
||||
StorageManagerIF* tmStore = nullptr;
|
||||
|
||||
PersistentTmStores stores;
|
||||
ObjectFactory::produceGenericObjects(&healthTable, &pusFunnel, &cfdpFunnel,
|
||||
*SdCardManager::instance(), &ipcStore, &tmStore, stores);
|
||||
|
||||
LinuxLibgpioIF* gpioComIF = nullptr;
|
||||
SerialComIF* uartComIF = nullptr;
|
||||
SpiComIF* spiMainComIF = nullptr;
|
||||
I2cComIF* i2cComIF = nullptr;
|
||||
SpiComIF* spiRwComIF = nullptr;
|
||||
createCommunicationInterfaces(&gpioComIF, &uartComIF, &spiMainComIF, &i2cComIF, &spiRwComIF);
|
||||
createCommunicationInterfaces(&gpioComIF, &uartComIF, &spiMainComIF, &i2cComIF);
|
||||
/* Adding gpios for chip select decoding to the gpioComIf */
|
||||
q7s::gpioCallbacks::initSpiCsDecoder(gpioComIF);
|
||||
gpioCallbacks::disableAllDecoder(gpioComIF);
|
||||
@ -43,17 +52,21 @@ void ObjectFactory::produce(void* args) {
|
||||
#if OBSW_ADD_GOMSPACE_PCDU == 1
|
||||
dummyCfg.addPowerDummies = false;
|
||||
#endif
|
||||
#if OBSW_ADD_ACS_BOARD == 1
|
||||
dummyCfg.addAcsBoardDummies = false;
|
||||
#endif
|
||||
|
||||
PowerSwitchIF* pwrSwitcher = nullptr;
|
||||
#if OBSW_ADD_GOMSPACE_PCDU == 0
|
||||
pwrSwitcher = new DummyPowerSwitcher(objects::PCDU_HANDLER, 18, 0);
|
||||
auto* comCookieDummy = new ComCookieDummy();
|
||||
pwrSwitcher = new PcduHandlerDummy(objects::PCDU_HANDLER, objects::DUMMY_COM_IF, comCookieDummy);
|
||||
#else
|
||||
createPcduComponents(gpioComIF, &pwrSwitcher);
|
||||
#endif
|
||||
|
||||
dummy::createDummies(dummyCfg, *pwrSwitcher);
|
||||
dummy::createDummies(dummyCfg, *pwrSwitcher, gpioComIF);
|
||||
|
||||
new CoreController(objects::CORE_CONTROLLER);
|
||||
new CoreController(objects::CORE_CONTROLLER, I2C_FATAL_ERRORS);
|
||||
|
||||
// Regular FM code, does not work for EM if the hardware is not connected
|
||||
// createPcduComponents(gpioComIF, &pwrSwitcher);
|
||||
@ -71,7 +84,12 @@ void ObjectFactory::produce(void* args) {
|
||||
// createRadSensorComponent(gpioComIF);
|
||||
|
||||
#if OBSW_ADD_ACS_BOARD == 1
|
||||
createAcsBoardComponents(gpioComIF, uartComIF, pwrSwitcher);
|
||||
createAcsBoardComponents(gpioComIF, uartComIF, *pwrSwitcher);
|
||||
#else
|
||||
// Still add all GPIOs for EM.
|
||||
GpioCookie* acsBoardGpios = new GpioCookie();
|
||||
createAcsBoardGpios(*acsBoardGpios);
|
||||
gpioChecker(gpioComIF->addGpios(acsBoardGpios), "ACS Board");
|
||||
#endif
|
||||
|
||||
#if OBSW_ADD_MGT == 1
|
||||
@ -93,11 +111,16 @@ void ObjectFactory::produce(void* args) {
|
||||
#if OBSW_ADD_STAR_TRACKER == 1
|
||||
createStrComponents(pwrSwitcher);
|
||||
#endif /* OBSW_ADD_STAR_TRACKER == 1 */
|
||||
|
||||
#if OBSW_ADD_CCSDS_IP_CORES == 1
|
||||
CcsdsIpCoreHandler* ipCoreHandler = nullptr;
|
||||
createCcsdsComponents(gpioComIF, &ipCoreHandler);
|
||||
CcsdsComponentArgs ccsdsArgs(*gpioComIF, *ipcStore, *tmStore, stores, *pusFunnel, *cfdpFunnel,
|
||||
&ipCoreHandler);
|
||||
createCcsdsComponents(ccsdsArgs);
|
||||
#if OBSW_TM_TO_PTME == 1
|
||||
ObjectFactory::addTmtcIpCoresToFunnels(*ipCoreHandler, *pusFunnel, *cfdpFunnel);
|
||||
if (ccsdsArgs.liveDestination != nullptr) {
|
||||
pusFunnel->addLiveDestination("VC0 LIVE TM", *ccsdsArgs.liveDestination, 0);
|
||||
}
|
||||
#endif
|
||||
#endif /* OBSW_ADD_CCSDS_IP_CORES == 1 */
|
||||
/* Test Task */
|
||||
@ -109,5 +132,8 @@ void ObjectFactory::produce(void* args) {
|
||||
pcdu::Switches::PDU1_CH5_SOLAR_CELL_EXP_5V);
|
||||
#endif
|
||||
createAcsController(true);
|
||||
satsystem::com::init();
|
||||
HeaterHandler* heaterHandler = nullptr;
|
||||
ObjectFactory::createGenericHeaterComponents(*gpioComIF, *pwrSwitcher, heaterHandler);
|
||||
createThermalController(*heaterHandler);
|
||||
satsystem::init();
|
||||
}
|
||||
|
@ -1,4 +1,6 @@
|
||||
#include <bsp_q7s/callbacks/q7sGpioCallbacks.h>
|
||||
#include <fsfw/storagemanager/LocalPool.h>
|
||||
#include <fsfw/storagemanager/PoolManager.h>
|
||||
#include <mission/devices/devicedefinitions/GomspaceDefinitions.h>
|
||||
|
||||
#include "OBSWConfig.h"
|
||||
@ -12,26 +14,31 @@
|
||||
#include "linux/callbacks/gpioCallbacks.h"
|
||||
#include "mission/core/GenericFactory.h"
|
||||
#include "mission/system/tree/system.h"
|
||||
#include "mission/tmtc/tmFilters.h"
|
||||
|
||||
void ObjectFactory::produce(void* args) {
|
||||
ObjectFactory::setStatics();
|
||||
HealthTableIF* healthTable = nullptr;
|
||||
PusTmFunnel* pusFunnel = nullptr;
|
||||
CfdpTmFunnel* cfdpFunnel = nullptr;
|
||||
ObjectFactory::produceGenericObjects(&healthTable, &pusFunnel, &cfdpFunnel);
|
||||
StorageManagerIF* ipcStore = nullptr;
|
||||
StorageManagerIF* tmStore = nullptr;
|
||||
|
||||
PersistentTmStores stores;
|
||||
ObjectFactory::produceGenericObjects(&healthTable, &pusFunnel, &cfdpFunnel,
|
||||
*SdCardManager::instance(), &ipcStore, &tmStore, stores);
|
||||
|
||||
LinuxLibgpioIF* gpioComIF = nullptr;
|
||||
SerialComIF* uartComIF = nullptr;
|
||||
SpiComIF* spiMainComIF = nullptr;
|
||||
I2cComIF* i2cComIF = nullptr;
|
||||
PowerSwitchIF* pwrSwitcher = nullptr;
|
||||
SpiComIF* spiRwComIF = nullptr;
|
||||
createCommunicationInterfaces(&gpioComIF, &uartComIF, &spiMainComIF, &i2cComIF, &spiRwComIF);
|
||||
createCommunicationInterfaces(&gpioComIF, &uartComIF, &spiMainComIF, &i2cComIF);
|
||||
/* Adding gpios for chip select decoding to the gpioComIf */
|
||||
q7s::gpioCallbacks::initSpiCsDecoder(gpioComIF);
|
||||
gpioCallbacks::disableAllDecoder(gpioComIF);
|
||||
|
||||
new CoreController(objects::CORE_CONTROLLER);
|
||||
new CoreController(objects::CORE_CONTROLLER, I2C_FATAL_ERRORS);
|
||||
createPcduComponents(gpioComIF, &pwrSwitcher);
|
||||
auto* stackHandler = new Stack5VHandler(*pwrSwitcher);
|
||||
|
||||
@ -39,13 +46,14 @@ void ObjectFactory::produce(void* args) {
|
||||
createRadSensorComponent(gpioComIF, *stackHandler);
|
||||
#endif
|
||||
#if OBSW_ADD_SUN_SENSORS == 1
|
||||
createSunSensorComponents(gpioComIF, spiMainComIF, pwrSwitcher, q7s::SPI_DEFAULT_DEV, true);
|
||||
createSunSensorComponents(gpioComIF, spiMainComIF, *pwrSwitcher, q7s::SPI_DEFAULT_DEV, true);
|
||||
#endif
|
||||
|
||||
#if OBSW_ADD_ACS_BOARD == 1
|
||||
createAcsBoardComponents(gpioComIF, uartComIF, pwrSwitcher);
|
||||
createAcsBoardComponents(*spiMainComIF, gpioComIF, uartComIF, *pwrSwitcher);
|
||||
#endif
|
||||
createHeaterComponents(gpioComIF, pwrSwitcher, healthTable);
|
||||
HeaterHandler* heaterHandler;
|
||||
createHeaterComponents(gpioComIF, pwrSwitcher, healthTable, heaterHandler);
|
||||
#if OBSW_ADD_TMP_DEVICES == 1
|
||||
createTmpComponents();
|
||||
#endif
|
||||
@ -69,11 +77,16 @@ void ObjectFactory::produce(void* args) {
|
||||
#if OBSW_ADD_STAR_TRACKER == 1
|
||||
createStrComponents(pwrSwitcher);
|
||||
#endif /* OBSW_ADD_STAR_TRACKER == 1 */
|
||||
|
||||
#if OBSW_ADD_CCSDS_IP_CORES == 1
|
||||
CcsdsIpCoreHandler* ipCoreHandler = nullptr;
|
||||
createCcsdsComponents(gpioComIF, &ipCoreHandler);
|
||||
CcsdsComponentArgs ccsdsArgs(*gpioComIF, *ipcStore, *tmStore, stores, *pusFunnel, *cfdpFunnel,
|
||||
&ipCoreHandler);
|
||||
createCcsdsComponents(ccsdsArgs);
|
||||
#if OBSW_TM_TO_PTME == 1
|
||||
addTmtcIpCoresToFunnels(*ipCoreHandler, *pusFunnel, *cfdpFunnel);
|
||||
if (ccsdsArgs.liveDestination != nullptr) {
|
||||
pusFunnel->addLiveDestination("VC0 LIVE TM", *ccsdsArgs.liveDestination, 0);
|
||||
}
|
||||
#endif
|
||||
#endif /* OBSW_ADD_CCSDS_IP_CORES == 1 */
|
||||
|
||||
@ -87,7 +100,7 @@ void ObjectFactory::produce(void* args) {
|
||||
#endif /* OBSW_ADD_TEST_CODE == 1 */
|
||||
|
||||
createMiscComponents();
|
||||
createThermalController();
|
||||
createThermalController(*heaterHandler);
|
||||
createAcsController(true);
|
||||
satsystem::init();
|
||||
}
|
||||
|
@ -22,7 +22,7 @@ ReturnValue_t FilesystemHelper::checkPath(std::string path) {
|
||||
}
|
||||
} else if (path.substr(0, sizeof(config::SD_1_MOUNT_POINT)) ==
|
||||
std::string(config::SD_1_MOUNT_POINT)) {
|
||||
if (!sdcMan->isSdCardUsable(sd::SLOT_0)) {
|
||||
if (!sdcMan->isSdCardUsable(sd::SLOT_1)) {
|
||||
sif::warning << "FilesystemHelper::checkPath: SD card 1 not mounted" << std::endl;
|
||||
return SD_NOT_MOUNTED;
|
||||
}
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
#include <fsfw/ipc/MutexGuard.h>
|
||||
#include <fsfw/timemanager/Countdown.h>
|
||||
#include <fsfw/timemanager/Stopwatch.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include <cstring>
|
||||
@ -20,31 +21,32 @@
|
||||
SdCardManager* SdCardManager::INSTANCE = nullptr;
|
||||
|
||||
SdCardManager::SdCardManager() : SystemObject(objects::SDC_MANAGER), cmdExecutor(256) {
|
||||
mutex = MutexFactory::instance()->createMutex();
|
||||
ReturnValue_t result = mutex->lockMutex();
|
||||
if (result != returnvalue::OK) {
|
||||
sdLock = MutexFactory::instance()->createMutex();
|
||||
prefLock = MutexFactory::instance()->createMutex();
|
||||
defaultLock = MutexFactory::instance()->createMutex();
|
||||
|
||||
MutexGuard mg(prefLock, LOCK_TYPE, OTHER_TIMEOUT, LOCK_CTX);
|
||||
if (mg.getLockResult() != returnvalue::OK) {
|
||||
sif::error << "SdCardManager::SdCardManager: Mutex lock failed" << std::endl;
|
||||
}
|
||||
uint8_t prefSdRaw = 0;
|
||||
result = scratch::readNumber(scratch::PREFERED_SDC_KEY, prefSdRaw);
|
||||
if (mutex->unlockMutex() != returnvalue::OK) {
|
||||
sif::error << "SdCardManager::SdCardManager: Mutex unlock failed" << std::endl;
|
||||
}
|
||||
ReturnValue_t result = scratch::readNumber(scratch::PREFERED_SDC_KEY, prefSdRaw);
|
||||
|
||||
if (result != returnvalue::OK) {
|
||||
if (result == scratch::KEY_NOT_FOUND) {
|
||||
sif::warning << "CoreController::sdCardInit: "
|
||||
"Preferred SD card not set. Setting to 0"
|
||||
<< std::endl;
|
||||
setPreferredSdCard(sd::SdCard::SLOT_0);
|
||||
sdInfo.pref = sd::SdCard::SLOT_0;
|
||||
scratch::writeNumber(scratch::PREFERED_SDC_KEY, static_cast<uint8_t>(sd::SdCard::SLOT_0));
|
||||
prefSdRaw = sd::SdCard::SLOT_0;
|
||||
|
||||
} else {
|
||||
// Should not happen.
|
||||
// TODO: Maybe trigger event?
|
||||
sif::error << "SdCardManager::SdCardManager: Reading preferred SD card from scratch"
|
||||
"buffer failed"
|
||||
<< std::endl;
|
||||
sdInfo.pref = sd::SdCard::SLOT_0;
|
||||
prefSdRaw = sd::SdCard::SLOT_0;
|
||||
}
|
||||
}
|
||||
sdInfo.pref = static_cast<sd::SdCard>(prefSdRaw);
|
||||
@ -193,28 +195,9 @@ ReturnValue_t SdCardManager::setSdCardState(sd::SdCard sdCard, bool on) {
|
||||
return result;
|
||||
}
|
||||
|
||||
ReturnValue_t SdCardManager::getSdCardsStatus(SdStatePair& active) {
|
||||
using namespace std;
|
||||
MutexGuard mg(mutex);
|
||||
if (not filesystem::exists(SD_STATE_FILE)) {
|
||||
return STATUS_FILE_NEXISTS;
|
||||
}
|
||||
|
||||
// Now the file should exist in any case. Still check whether it exists.
|
||||
fstream sdStatus(SD_STATE_FILE);
|
||||
if (not sdStatus.good()) {
|
||||
return STATUS_FILE_NEXISTS;
|
||||
}
|
||||
string line;
|
||||
uint8_t idx = 0;
|
||||
sd::SdCard currentSd = sd::SdCard::SLOT_0;
|
||||
// Process status file line by line
|
||||
while (std::getline(sdStatus, line)) {
|
||||
processSdStatusLine(active, line, idx, currentSd);
|
||||
}
|
||||
if (active.first != sd::SdState::MOUNTED && active.second != sd::SdState::MOUNTED) {
|
||||
sdCardActive = false;
|
||||
}
|
||||
ReturnValue_t SdCardManager::getSdCardsStatus(SdStatePair& sdStates) {
|
||||
MutexGuard mg(sdLock, LOCK_TYPE, SD_LOCK_TIMEOUT, LOCK_CTX);
|
||||
sdStates = this->sdStates;
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
@ -237,7 +220,8 @@ ReturnValue_t SdCardManager::mountSdCard(sd::SdCard sdCard) {
|
||||
mountDev = SD_1_DEV_NAME;
|
||||
mountPoint = config::SD_1_MOUNT_POINT;
|
||||
}
|
||||
if (not filesystem::exists(mountDev)) {
|
||||
std::error_code e;
|
||||
if (not filesystem::exists(mountDev, e)) {
|
||||
sif::warning << "SdCardManager::mountSdCard: Device file does not exists. Make sure to"
|
||||
" turn on the SD card"
|
||||
<< std::endl;
|
||||
@ -272,7 +256,8 @@ ReturnValue_t SdCardManager::unmountSdCard(sd::SdCard sdCard) {
|
||||
} else if (sdCard == sd::SdCard::SLOT_1) {
|
||||
mountPoint = config::SD_1_MOUNT_POINT;
|
||||
}
|
||||
if (not filesystem::exists(mountPoint)) {
|
||||
std::error_code e;
|
||||
if (not filesystem::exists(mountPoint, e)) {
|
||||
sif::error << "SdCardManager::unmountSdCard: Default mount point " << mountPoint
|
||||
<< "does not exist" << std::endl;
|
||||
return UNMOUNT_ERROR;
|
||||
@ -304,10 +289,9 @@ ReturnValue_t SdCardManager::sanitizeState(SdStatePair* statusPair, sd::SdCard p
|
||||
resetNonBlockingState = true;
|
||||
}
|
||||
if (statusPair == nullptr) {
|
||||
sdStatusPtr = std::make_unique<SdStatePair>();
|
||||
statusPair = sdStatusPtr.get();
|
||||
getSdCardsStatus(*statusPair);
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
getSdCardsStatus(*statusPair);
|
||||
|
||||
if (statusPair->first == sd::SdState::ON) {
|
||||
result = mountSdCard(prefSdCard);
|
||||
@ -325,8 +309,34 @@ void SdCardManager::resetState() {
|
||||
currentOp = Operations::IDLE;
|
||||
}
|
||||
|
||||
void SdCardManager::processSdStatusLine(std::pair<sd::SdState, sd::SdState>& active,
|
||||
std::string& line, uint8_t& idx, sd::SdCard& currentSd) {
|
||||
ReturnValue_t SdCardManager::updateSdStatePair() {
|
||||
using namespace std;
|
||||
|
||||
MutexGuard mg(sdLock, LOCK_TYPE, SD_LOCK_TIMEOUT, LOCK_CTX);
|
||||
std::error_code e;
|
||||
if (not filesystem::exists(SD_STATE_FILE, e)) {
|
||||
return STATUS_FILE_NEXISTS;
|
||||
}
|
||||
|
||||
// Now the file should exist in any case. Still check whether it exists.
|
||||
fstream sdStatus(SD_STATE_FILE);
|
||||
if (not sdStatus.good()) {
|
||||
return STATUS_FILE_NEXISTS;
|
||||
}
|
||||
string line;
|
||||
uint8_t idx = 0;
|
||||
sd::SdCard currentSd = sd::SdCard::SLOT_0;
|
||||
// Process status file line by line
|
||||
while (std::getline(sdStatus, line)) {
|
||||
processSdStatusLine(line, idx, currentSd);
|
||||
}
|
||||
if (sdStates.first != sd::SdState::MOUNTED && sdStates.second != sd::SdState::MOUNTED) {
|
||||
sdCardActive = false;
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void SdCardManager::processSdStatusLine(std::string& line, uint8_t& idx, sd::SdCard& currentSd) {
|
||||
using namespace std;
|
||||
istringstream iss(line);
|
||||
string word;
|
||||
@ -347,24 +357,24 @@ void SdCardManager::processSdStatusLine(std::pair<sd::SdState, sd::SdState>& act
|
||||
|
||||
if (word == "on") {
|
||||
if (currentSd == sd::SdCard::SLOT_0) {
|
||||
active.first = sd::SdState::ON;
|
||||
sdStates.first = sd::SdState::ON;
|
||||
} else {
|
||||
active.second = sd::SdState::ON;
|
||||
sdStates.second = sd::SdState::ON;
|
||||
}
|
||||
} else if (word == "off") {
|
||||
if (currentSd == sd::SdCard::SLOT_0) {
|
||||
active.first = sd::SdState::OFF;
|
||||
sdStates.first = sd::SdState::OFF;
|
||||
} else {
|
||||
active.second = sd::SdState::OFF;
|
||||
sdStates.second = sd::SdState::OFF;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (mountLine) {
|
||||
if (currentSd == sd::SdCard::SLOT_0) {
|
||||
active.first = sd::SdState::MOUNTED;
|
||||
sdStates.first = sd::SdState::MOUNTED;
|
||||
} else {
|
||||
active.second = sd::SdState::MOUNTED;
|
||||
sdStates.second = sd::SdState::MOUNTED;
|
||||
}
|
||||
}
|
||||
|
||||
@ -378,7 +388,7 @@ void SdCardManager::processSdStatusLine(std::pair<sd::SdState, sd::SdState>& act
|
||||
}
|
||||
|
||||
std::optional<sd::SdCard> SdCardManager::getPreferredSdCard() const {
|
||||
MutexGuard mg(mutex);
|
||||
MutexGuard mg(prefLock, LOCK_TYPE, OTHER_TIMEOUT, LOCK_CTX);
|
||||
auto res = mg.getLockResult();
|
||||
if (res != returnvalue::OK) {
|
||||
sif::error << "SdCardManager::getPreferredSdCard: Lock error" << std::endl;
|
||||
@ -387,7 +397,7 @@ std::optional<sd::SdCard> SdCardManager::getPreferredSdCard() const {
|
||||
}
|
||||
|
||||
ReturnValue_t SdCardManager::setPreferredSdCard(sd::SdCard sdCard) {
|
||||
MutexGuard mg(mutex);
|
||||
MutexGuard mg(prefLock, LOCK_TYPE, OTHER_TIMEOUT, LOCK_CTX);
|
||||
if (sdCard == sd::SdCard::BOTH) {
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
@ -399,10 +409,10 @@ ReturnValue_t SdCardManager::updateSdCardStateFile() {
|
||||
if (cmdExecutor.getCurrentState() == CommandExecutor::States::PENDING) {
|
||||
return CommandExecutor::COMMAND_PENDING;
|
||||
}
|
||||
MutexGuard mg(mutex);
|
||||
MutexGuard mg(sdLock, LOCK_TYPE, SD_LOCK_TIMEOUT, LOCK_CTX);
|
||||
// Use q7hw utility and pipe the command output into the state file
|
||||
std::string updateCmd = "q7hw sd info all > " + std::string(SD_STATE_FILE);
|
||||
cmdExecutor.load(updateCmd, blocking, printCmdOutput);
|
||||
cmdExecutor.load(updateCmd, true, printCmdOutput);
|
||||
ReturnValue_t result = cmdExecutor.execute();
|
||||
if (blocking and result != returnvalue::OK) {
|
||||
utility::handleSystemError(cmdExecutor.getLastError(), "SdCardManager::mountSdCard");
|
||||
@ -410,9 +420,12 @@ ReturnValue_t SdCardManager::updateSdCardStateFile() {
|
||||
return result;
|
||||
}
|
||||
|
||||
const std::string& SdCardManager::getCurrentMountPrefix() const {
|
||||
MutexGuard mg(mutex);
|
||||
return currentPrefix;
|
||||
const char* SdCardManager::getCurrentMountPrefix() const {
|
||||
MutexGuard mg(defaultLock, LOCK_TYPE, OTHER_TIMEOUT, LOCK_CTX);
|
||||
if (currentPrefix.has_value()) {
|
||||
return currentPrefix.value().c_str();
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
SdCardManager::OpStatus SdCardManager::checkCurrentOp(Operations& currentOp) {
|
||||
@ -461,41 +474,35 @@ void SdCardManager::setPrintCommandOutput(bool print) { this->printCmdOutput = p
|
||||
|
||||
bool SdCardManager::isSdCardUsable(std::optional<sd::SdCard> sdCard) {
|
||||
{
|
||||
MutexGuard mg(mutex);
|
||||
MutexGuard mg(defaultLock, LOCK_TYPE, OTHER_TIMEOUT, LOCK_CTX);
|
||||
if (markedUnusable) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
SdCardManager::SdStatePair active;
|
||||
ReturnValue_t result = this->getSdCardsStatus(active);
|
||||
|
||||
if (result != returnvalue::OK) {
|
||||
sif::debug << "SdCardManager::isSdCardMounted: Failed to get SD card active state";
|
||||
return false;
|
||||
}
|
||||
MutexGuard mg(sdLock, LOCK_TYPE, SD_LOCK_TIMEOUT, LOCK_CTX);
|
||||
if (not sdCard) {
|
||||
if (active.first == sd::MOUNTED or active.second == sd::MOUNTED) {
|
||||
if (sdStates.first == sd::MOUNTED or sdStates.second == sd::MOUNTED) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
if (sdCard == sd::SLOT_0) {
|
||||
if (active.first == sd::MOUNTED) {
|
||||
if (sdStates.first == sd::MOUNTED) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if (sdCard == sd::SLOT_1) {
|
||||
if (active.second == sd::MOUNTED) {
|
||||
if (sdStates.second == sd::MOUNTED) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if (sdCard == sd::BOTH) {
|
||||
if (active.first == sd::MOUNTED && active.second == sd::MOUNTED) {
|
||||
if (sdStates.first == sd::MOUNTED && sdStates.second == sd::MOUNTED) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@ -505,9 +512,9 @@ bool SdCardManager::isSdCardUsable(std::optional<sd::SdCard> sdCard) {
|
||||
ReturnValue_t SdCardManager::isSdCardMountedReadOnly(sd::SdCard sdcard, bool& readOnly) {
|
||||
std::ostringstream command;
|
||||
if (sdcard == sd::SdCard::SLOT_0) {
|
||||
command << "grep -q '" << config::SD_0_MOUNT_POINT << " vfat ro,' /proc/mounts";
|
||||
command << "grep -q '" << config::SD_0_MOUNT_POINT << " ext4 rw,' /proc/mounts";
|
||||
} else if (sdcard == sd::SdCard::SLOT_1) {
|
||||
command << "grep -q '" << config::SD_1_MOUNT_POINT << " vfat ro,' /proc/mounts";
|
||||
command << "grep -q '" << config::SD_1_MOUNT_POINT << " ext4 rw,' /proc/mounts";
|
||||
} else {
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
@ -516,18 +523,9 @@ ReturnValue_t SdCardManager::isSdCardMountedReadOnly(sd::SdCard sdcard, bool& re
|
||||
return result;
|
||||
}
|
||||
result = cmdExecutor.execute();
|
||||
if (result != returnvalue::OK) {
|
||||
int exitStatus = cmdExecutor.getLastError();
|
||||
if (exitStatus == 1) {
|
||||
readOnly = false;
|
||||
return returnvalue::OK;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
auto& readVec = cmdExecutor.getReadVector();
|
||||
size_t readLen = strnlen(readVec.data(), readVec.size());
|
||||
if (readLen == 0) {
|
||||
if (result == returnvalue::OK) {
|
||||
readOnly = false;
|
||||
return result;
|
||||
}
|
||||
readOnly = true;
|
||||
return returnvalue::OK;
|
||||
@ -566,7 +564,7 @@ ReturnValue_t SdCardManager::performFsck(sd::SdCard sdcard, bool printOutput, in
|
||||
}
|
||||
|
||||
void SdCardManager::setActiveSdCard(sd::SdCard sdCard) {
|
||||
MutexGuard mg(mutex);
|
||||
MutexGuard mg(defaultLock, LOCK_TYPE, OTHER_TIMEOUT, LOCK_CTX);
|
||||
sdInfo.active = sdCard;
|
||||
if (sdInfo.active == sd::SdCard::SLOT_0) {
|
||||
currentPrefix = config::SD_0_MOUNT_POINT;
|
||||
@ -576,7 +574,7 @@ void SdCardManager::setActiveSdCard(sd::SdCard sdCard) {
|
||||
}
|
||||
|
||||
std::optional<sd::SdCard> SdCardManager::getActiveSdCard() const {
|
||||
MutexGuard mg(mutex);
|
||||
MutexGuard mg(defaultLock, LOCK_TYPE, OTHER_TIMEOUT, LOCK_CTX);
|
||||
if (markedUnusable) {
|
||||
return std::nullopt;
|
||||
}
|
||||
@ -584,6 +582,6 @@ std::optional<sd::SdCard> SdCardManager::getActiveSdCard() const {
|
||||
}
|
||||
|
||||
void SdCardManager::markUnusable() {
|
||||
MutexGuard mg(mutex);
|
||||
MutexGuard mg(defaultLock, LOCK_TYPE, OTHER_TIMEOUT, LOCK_CTX);
|
||||
markedUnusable = true;
|
||||
}
|
||||
|
@ -25,7 +25,7 @@ class MutexIF;
|
||||
* state
|
||||
*/
|
||||
class SdCardManager : public SystemObject, public SdCardMountedIF {
|
||||
friend class SdCardAccess;
|
||||
friend class CoreController;
|
||||
|
||||
public:
|
||||
using mountInitCb = ReturnValue_t (*)(void* args);
|
||||
@ -187,7 +187,7 @@ class SdCardManager : public SystemObject, public SdCardMountedIF {
|
||||
* @param prefSdCardPtr
|
||||
* @return
|
||||
*/
|
||||
const std::string& getCurrentMountPrefix() const override;
|
||||
const char* getCurrentMountPrefix() const override;
|
||||
|
||||
OpStatus checkCurrentOp(Operations& currentOp);
|
||||
|
||||
@ -218,21 +218,29 @@ class SdCardManager : public SystemObject, public SdCardMountedIF {
|
||||
|
||||
private:
|
||||
CommandExecutor cmdExecutor;
|
||||
SdStatePair sdStates;
|
||||
Operations currentOp = Operations::IDLE;
|
||||
bool blocking = false;
|
||||
bool sdCardActive = true;
|
||||
bool printCmdOutput = true;
|
||||
bool markedUnusable = false;
|
||||
MutexIF* mutex = nullptr;
|
||||
MutexIF* sdLock = nullptr;
|
||||
MutexIF* prefLock = nullptr;
|
||||
MutexIF* defaultLock = nullptr;
|
||||
static constexpr MutexIF::TimeoutType LOCK_TYPE = MutexIF::TimeoutType::WAITING;
|
||||
static constexpr uint32_t SD_LOCK_TIMEOUT = 250;
|
||||
static constexpr uint32_t OTHER_TIMEOUT = 20;
|
||||
static constexpr char LOCK_CTX[] = "SdCardManager";
|
||||
|
||||
SdCardManager();
|
||||
|
||||
ReturnValue_t updateSdStatePair();
|
||||
|
||||
ReturnValue_t setSdCardState(sd::SdCard sdCard, bool on);
|
||||
|
||||
void processSdStatusLine(SdStatePair& active, std::string& line, uint8_t& idx,
|
||||
sd::SdCard& currentSd);
|
||||
void processSdStatusLine(std::string& line, uint8_t& idx, sd::SdCard& currentSd);
|
||||
|
||||
std::string currentPrefix;
|
||||
std::optional<std::string> currentPrefix;
|
||||
|
||||
static SdCardManager* INSTANCE;
|
||||
};
|
||||
|
@ -3,6 +3,9 @@
|
||||
std::filesystem::path fshelpers::getPrefixedPath(SdCardManager &man,
|
||||
std::filesystem::path pathWihtoutPrefix) {
|
||||
auto prefix = man.getCurrentMountPrefix();
|
||||
if (prefix == nullptr) {
|
||||
return pathWihtoutPrefix;
|
||||
}
|
||||
auto resPath = prefix / pathWihtoutPrefix;
|
||||
return resPath;
|
||||
}
|
||||
|
@ -12,10 +12,10 @@
|
||||
* @brief This is the main program for the target hardware.
|
||||
* @return
|
||||
*/
|
||||
int main(void) {
|
||||
int main(int argc, char* argv[]) {
|
||||
using namespace std;
|
||||
#if Q7S_SIMPLE_MODE == 0
|
||||
return obsw::obsw();
|
||||
return obsw::obsw(argc, argv);
|
||||
#else
|
||||
return simple::simple();
|
||||
#endif
|
||||
|
@ -1 +1 @@
|
||||
target_sources(${OBSW_NAME} PRIVATE scratchApi.cpp)
|
||||
target_sources(${OBSW_NAME} PRIVATE scratchApi.cpp LocalParameterHandler.cpp)
|
||||
|
41
bsp_q7s/memory/LocalParameterHandler.cpp
Normal file
41
bsp_q7s/memory/LocalParameterHandler.cpp
Normal file
@ -0,0 +1,41 @@
|
||||
#include "LocalParameterHandler.h"
|
||||
|
||||
#include <fsfw/serviceinterface/ServiceInterface.h>
|
||||
|
||||
LocalParameterHandler::LocalParameterHandler(std::string sdRelativeName, SdCardMountedIF* sdcMan)
|
||||
: NVMParameterBase(), sdRelativeName(sdRelativeName), sdcMan(sdcMan) {}
|
||||
|
||||
LocalParameterHandler::~LocalParameterHandler() {}
|
||||
|
||||
ReturnValue_t LocalParameterHandler::initialize() {
|
||||
ReturnValue_t result = updateFullName();
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
result = readJsonFile();
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t LocalParameterHandler::writeJsonFile() {
|
||||
ReturnValue_t result = updateFullName();
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
return NVMParameterBase::writeJsonFile();
|
||||
}
|
||||
|
||||
ReturnValue_t LocalParameterHandler::updateFullName() {
|
||||
std::string mountPrefix;
|
||||
auto activeSd = sdcMan->getActiveSdCard();
|
||||
if (activeSd and sdcMan->isSdCardUsable(activeSd.value())) {
|
||||
mountPrefix = sdcMan->getCurrentMountPrefix();
|
||||
} else {
|
||||
return SD_NOT_READY;
|
||||
}
|
||||
std::string fullname = mountPrefix + "/" + sdRelativeName;
|
||||
NVMParameterBase::setFullName(fullname);
|
||||
return returnvalue::OK;
|
||||
}
|
106
bsp_q7s/memory/LocalParameterHandler.h
Normal file
106
bsp_q7s/memory/LocalParameterHandler.h
Normal file
@ -0,0 +1,106 @@
|
||||
#ifndef BSP_Q7S_MEMORY_LOCALPARAMETERHANDLER_H_
|
||||
#define BSP_Q7S_MEMORY_LOCALPARAMETERHANDLER_H_
|
||||
|
||||
#include <mission/memory/NvmParameterBase.h>
|
||||
#include <mission/memory/SdCardMountedIF.h>
|
||||
|
||||
#include <string>
|
||||
|
||||
/**
|
||||
* @brief Class to handle persistent parameters
|
||||
*
|
||||
*/
|
||||
class LocalParameterHandler : public NVMParameterBase {
|
||||
public:
|
||||
static constexpr uint8_t INTERFACE_ID = CLASS_ID::LOCAL_PARAM_HANDLER;
|
||||
|
||||
static constexpr ReturnValue_t SD_NOT_READY = returnvalue::makeCode(INTERFACE_ID, 0);
|
||||
/**
|
||||
* @brief Constructor
|
||||
*
|
||||
* @param sdRelativeName Absolute name of json file relative to mount
|
||||
* directory
|
||||
* of SD card. E.g. conf/example.json
|
||||
* @param sdcMan Pointer to SD card manager
|
||||
*/
|
||||
LocalParameterHandler(std::string sdRelativeName, SdCardMountedIF* sdcMan);
|
||||
virtual ~LocalParameterHandler();
|
||||
|
||||
/**
|
||||
* @brief Will initialize the local parameter handler
|
||||
*
|
||||
* @return OK if successful, otherwise error return value
|
||||
*/
|
||||
ReturnValue_t initialize();
|
||||
|
||||
/**
|
||||
* @brief Function to add parameter to json file. If the json file does
|
||||
* not yet exist it will be created here.
|
||||
*
|
||||
* @param key The string to identify the parameter
|
||||
* @param value The value to set for this parameter
|
||||
*
|
||||
* @return OK if successful, otherwise error return value
|
||||
*
|
||||
* @details The function will add the parameter only if it is not already
|
||||
* present in the json file
|
||||
*/
|
||||
template <typename T>
|
||||
ReturnValue_t addParameter(std::string key, T value);
|
||||
|
||||
/**
|
||||
* @brief Function will update a parameter which already exists in the json
|
||||
* file
|
||||
*
|
||||
* @param key The unique string to identify the parameter to update
|
||||
* @param value The new new value to set
|
||||
*
|
||||
* @return OK if successful, otherwise error return value
|
||||
*/
|
||||
template <typename T>
|
||||
ReturnValue_t updateParameter(std::string key, T value);
|
||||
|
||||
private:
|
||||
// Name relative to mount point of SD card where parameters will be stored
|
||||
std::string sdRelativeName;
|
||||
|
||||
SdCardMountedIF* sdcMan;
|
||||
|
||||
virtual ReturnValue_t writeJsonFile();
|
||||
|
||||
/**
|
||||
* @brief This function sets the name of the json file dependent on the
|
||||
* currently active SD card
|
||||
*
|
||||
* @return OK if successful, otherwise error return value
|
||||
*/
|
||||
ReturnValue_t updateFullName();
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
inline ReturnValue_t LocalParameterHandler::addParameter(std::string key, T value) {
|
||||
ReturnValue_t result = insertValue(key, value);
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
result = writeJsonFile();
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
inline ReturnValue_t LocalParameterHandler::updateParameter(std::string key, T value) {
|
||||
ReturnValue_t result = setValue(key, value);
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
result = writeJsonFile();
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
#endif /* BSP_Q7S_MEMORY_LOCALPARAMETERHANDLER_H_ */
|
@ -9,20 +9,27 @@
|
||||
#include <iostream>
|
||||
|
||||
#include "OBSWConfig.h"
|
||||
#include "bsp_q7s/core/WatchdogHandler.h"
|
||||
#include "commonConfig.h"
|
||||
#include "core/scheduling.h"
|
||||
#include "fsfw/tasks/TaskFactory.h"
|
||||
#include "fsfw/version.h"
|
||||
#include "mission/acsDefs.h"
|
||||
#include "mission/comDefs.h"
|
||||
#include "mission/system/tree/system.h"
|
||||
#include "q7sConfig.h"
|
||||
#include "watchdog/definitions.h"
|
||||
|
||||
static int OBSW_ALREADY_RUNNING = -2;
|
||||
static constexpr int OBSW_ALREADY_RUNNING = -2;
|
||||
#if OBSW_Q7S_EM == 0
|
||||
static const char* DEV_STRING = "Xiphos Q7S FM";
|
||||
#else
|
||||
static const char* DEV_STRING = "Xiphos Q7S EM";
|
||||
#endif
|
||||
int obsw::obsw() {
|
||||
|
||||
WatchdogHandler WATCHDOG_HANDLER;
|
||||
|
||||
int obsw::obsw(int argc, char* argv[]) {
|
||||
using namespace fsfw;
|
||||
std::cout << "-- EIVE OBSW --" << std::endl;
|
||||
std::cout << "-- Compiled for Linux (" << DEV_STRING << ") --" << std::endl;
|
||||
@ -31,9 +38,10 @@ int obsw::obsw() {
|
||||
std::cout << "-- " << __DATE__ << " " << __TIME__ << " --" << std::endl;
|
||||
|
||||
#if Q7S_CHECK_FOR_ALREADY_RUNNING_IMG == 1
|
||||
std::error_code e;
|
||||
// Check special file here. This file is created or deleted by the eive-watchdog application
|
||||
// or systemd service!
|
||||
if (std::filesystem::exists(watchdog::RUNNING_FILE_NAME)) {
|
||||
if (std::filesystem::exists(watchdog::RUNNING_FILE_NAME, e)) {
|
||||
sif::warning << "File " << watchdog::RUNNING_FILE_NAME
|
||||
<< " exists so the software might "
|
||||
"already be running. Check if obsw systemd service has been stopped."
|
||||
@ -42,14 +50,48 @@ int obsw::obsw() {
|
||||
}
|
||||
#endif
|
||||
|
||||
// Delay the boot if applicable.
|
||||
bootDelayHandling();
|
||||
|
||||
bool initWatchFunction = false;
|
||||
std::string fullExecPath = argv[0];
|
||||
if (fullExecPath.find("/usr/bin") != std::string::npos) {
|
||||
initWatchFunction = true;
|
||||
}
|
||||
ReturnValue_t result = WATCHDOG_HANDLER.initialize(initWatchFunction);
|
||||
if (result != returnvalue::OK) {
|
||||
std::cerr << "Initiating EIVE watchdog handler failed" << std::endl;
|
||||
}
|
||||
|
||||
scheduling::initMission();
|
||||
|
||||
// Command the EIVE system to safe mode
|
||||
#if OBSW_COMMAND_SAFE_MODE_AT_STARTUP == 1
|
||||
// This ensures that the PCDU switches were updated.
|
||||
TaskFactory::delayTask(1000);
|
||||
commandComSubsystemRxOnly();
|
||||
commandEiveSystemToSafe();
|
||||
#else
|
||||
announceAllModes();
|
||||
#endif
|
||||
|
||||
for (;;) {
|
||||
WATCHDOG_HANDLER.periodicOperation();
|
||||
TaskFactory::delayTask(2000);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
void obsw::bootDelayHandling() {
|
||||
const char* homedir = nullptr;
|
||||
homedir = getenv("HOME");
|
||||
if (homedir == nullptr) {
|
||||
homedir = getpwuid(getuid())->pw_dir;
|
||||
}
|
||||
std::filesystem::path bootDelayFile = std::filesystem::path(homedir) / "boot_delay_secs.txt";
|
||||
std::error_code e;
|
||||
// Init delay handling.
|
||||
if (std::filesystem::exists(bootDelayFile)) {
|
||||
if (std::filesystem::exists(bootDelayFile, e)) {
|
||||
std::ifstream ifile(bootDelayFile);
|
||||
std::string lineStr;
|
||||
unsigned int bootDelaySecs = 0;
|
||||
@ -69,12 +111,41 @@ int obsw::obsw() {
|
||||
std::cout << "Delaying OBSW start for " << bootDelaySecs << " seconds" << std::endl;
|
||||
TaskFactory::delayTask(bootDelaySecs * 1000);
|
||||
}
|
||||
|
||||
scheduling::initMission();
|
||||
|
||||
for (;;) {
|
||||
/* Suspend main thread by sleeping it. */
|
||||
TaskFactory::delayTask(5000);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
void obsw::commandEiveSystemToSafe() {
|
||||
auto sysQueueId = satsystem::EIVE_SYSTEM.getCommandQueue();
|
||||
CommandMessage msg;
|
||||
ModeMessage::setCmdModeMessage(msg, acs::AcsMode::SAFE, 0);
|
||||
ReturnValue_t result =
|
||||
MessageQueueSenderIF::sendMessage(sysQueueId, &msg, MessageQueueIF::NO_QUEUE, false);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "obsw: Sending safe mode command to EIVE system failed" << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
void obsw::commandComSubsystemRxOnly() {
|
||||
auto* comSs = ObjectManager::instance()->get<HasModesIF>(objects::COM_SUBSYSTEM);
|
||||
if (comSs == nullptr) {
|
||||
sif::error << "obsw: Could not retrieve COM subsystem object" << std::endl;
|
||||
return;
|
||||
}
|
||||
CommandMessage msg;
|
||||
ModeMessage::setCmdModeMessage(msg, com::RX_ONLY, 0);
|
||||
ReturnValue_t result = MessageQueueSenderIF::sendMessage(comSs->getCommandQueue(), &msg,
|
||||
MessageQueueIF::NO_QUEUE, false);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "obsw: Sending RX_ONLY mode command to COM subsystem failed" << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
void obsw::announceAllModes() {
|
||||
auto sysQueueId = satsystem::EIVE_SYSTEM.getCommandQueue();
|
||||
CommandMessage msg;
|
||||
ModeMessage::setModeAnnounceMessage(msg, true);
|
||||
ReturnValue_t result =
|
||||
MessageQueueSenderIF::sendMessage(sysQueueId, &msg, MessageQueueIF::NO_QUEUE, false);
|
||||
if (result != returnvalue::OK) {
|
||||
sif::error << "obsw: Sending safe mode command to EIVE system failed" << std::endl;
|
||||
}
|
||||
}
|
||||
|
@ -3,8 +3,13 @@
|
||||
|
||||
namespace obsw {
|
||||
|
||||
int obsw();
|
||||
int obsw(int argc, char* argv[]);
|
||||
|
||||
};
|
||||
void bootDelayHandling();
|
||||
void commandEiveSystemToSafe();
|
||||
void commandComSubsystemRxOnly();
|
||||
void announceAllModes();
|
||||
|
||||
}; // namespace obsw
|
||||
|
||||
#endif /* BSP_Q7S_CORE_OBSW_H_ */
|
||||
|
@ -1,3 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
root="$(pwd)"
|
||||
ln -s "$root/hooks" "$root/.git/hooks"
|
||||
|
||||
git submodule update --init fsfw thirdparty/rapidcsv thirdparty/lwgps thirdparty/json
|
||||
|
@ -21,10 +21,13 @@ if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
|
||||
)
|
||||
endif()
|
||||
|
||||
set(RELEASE_BUILD 1 PARENT_SCOPE)
|
||||
|
||||
if(${CMAKE_BUILD_TYPE} MATCHES "Debug")
|
||||
message(STATUS
|
||||
"Building Debug application with flags: ${CMAKE_C_FLAGS_DEBUG}"
|
||||
)
|
||||
set(RELEASE_BUILD 0 PARENT_SCOPE)
|
||||
elseif(${CMAKE_BUILD_TYPE} MATCHES "RelWithDebInfo")
|
||||
message(STATUS
|
||||
"Building Release (Debug) application with "
|
||||
|
@ -4,7 +4,7 @@
|
||||
# 2. Major version
|
||||
# 3. Minor version
|
||||
# 4. Revision
|
||||
# 5. git SHA hash and commits since tag
|
||||
# 5. (Optional) git SHA hash and commits since tag when applicable
|
||||
function(determine_version_with_git)
|
||||
include(GetGitRevisionDescription)
|
||||
git_describe(VERSION ${ARGN})
|
||||
@ -22,7 +22,9 @@ function(determine_version_with_git)
|
||||
list(APPEND GIT_INFO ${_VERSION_MAJOR})
|
||||
list(APPEND GIT_INFO ${_VERSION_MINOR})
|
||||
list(APPEND GIT_INFO ${_VERSION_PATCH})
|
||||
list(APPEND GIT_INFO ${VERSION_SHA1})
|
||||
if(NOT VERSION_SHA1 STREQUAL VERSION)
|
||||
list(APPEND GIT_INFO ${VERSION_SHA1})
|
||||
endif()
|
||||
set(GIT_INFO ${GIT_INFO} PARENT_SCOPE)
|
||||
message(STATUS "eive | Set git version info into GIT_INFO from the git tag ${VERSION}")
|
||||
endfunction()
|
||||
|
@ -1,10 +0,0 @@
|
||||
#ifndef COMMON_CONFIG_OBSWVERSION_H_
|
||||
#define COMMON_CONFIG_OBSWVERSION_H_
|
||||
|
||||
const char* const SW_NAME = "eive";
|
||||
|
||||
#define SW_VERSION 1
|
||||
#define SW_SUBVERSION 12
|
||||
#define SW_REVISION 1
|
||||
|
||||
#endif /* COMMON_CONFIG_OBSWVERSION_H_ */
|
@ -4,6 +4,8 @@
|
||||
#include <cstdint>
|
||||
#include "fsfw/version.h"
|
||||
|
||||
#cmakedefine RELEASE_BUILD
|
||||
|
||||
#cmakedefine RASPBERRY_PI
|
||||
#cmakedefine XIPHOS_Q7S
|
||||
#cmakedefine BEAGLEBONEBLACK
|
||||
|
@ -5,6 +5,7 @@
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
#include "commonConfig.h"
|
||||
#include "fsfw/timemanager/clockDefinitions.h"
|
||||
#include "fsfw_hal/linux/serial/SerialCookie.h"
|
||||
#include "fsfw_hal/linux/spi/spiDefinitions.h"
|
||||
@ -47,10 +48,19 @@ static constexpr spi::SpiModes DEFAULT_ADIS16507_MODE = spi::SpiModes::MODE_3;
|
||||
static constexpr uint32_t RW_SPEED = 300'000;
|
||||
static constexpr spi::SpiModes RW_MODE = spi::SpiModes::MODE_0;
|
||||
|
||||
static constexpr dur_millis_t RTD_CS_TIMEOUT = 50;
|
||||
#ifdef RELEASE_BUILD
|
||||
static constexpr uint8_t CS_FACTOR = 1;
|
||||
#else
|
||||
static constexpr uint8_t CS_FACTOR = 3;
|
||||
#endif
|
||||
|
||||
static constexpr dur_millis_t RTD_CS_TIMEOUT = 50 * CS_FACTOR;
|
||||
static constexpr uint32_t RTD_SPEED = 2'000'000;
|
||||
static constexpr spi::SpiModes RTD_MODE = spi::SpiModes::MODE_3;
|
||||
|
||||
static constexpr dur_millis_t SUS_CS_TIMEOUT = 50 * CS_FACTOR;
|
||||
static constexpr dur_millis_t ACS_BOARD_CS_TIMEOUT = 50 * CS_FACTOR;
|
||||
|
||||
} // namespace spi
|
||||
|
||||
namespace uart {
|
||||
|
@ -102,6 +102,7 @@ enum gpioId_t {
|
||||
VC2_PAPB_BUSY,
|
||||
VC3_PAPB_EMPTY,
|
||||
VC3_PAPB_BUSY,
|
||||
PTME_RESETN,
|
||||
|
||||
PDEC_RESET,
|
||||
|
||||
|
@ -12,7 +12,7 @@ enum Switchers : uint8_t {
|
||||
HEATER_4_CAMERA,
|
||||
HEATER_5_STR,
|
||||
HEATER_6_DRO,
|
||||
HEATER_7_HPA,
|
||||
HEATER_7_S_BAND,
|
||||
NUMBER_OF_SWITCHES
|
||||
};
|
||||
}
|
||||
|
@ -45,15 +45,49 @@ static constexpr uint32_t SA_DEPL_MAX_BURN_TIME = 180;
|
||||
|
||||
static constexpr uint32_t CCSDS_HANDLER_QUEUE_SIZE = 50;
|
||||
static constexpr uint8_t NUMBER_OF_VIRTUAL_CHANNELS = 4;
|
||||
static constexpr uint8_t VC0_QUEUE_SIZE = 80;
|
||||
static constexpr uint8_t VC1_QUEUE_SIZE = 80;
|
||||
static constexpr uint8_t VC2_QUEUE_SIZE = 50;
|
||||
static constexpr uint8_t VC3_QUEUE_SIZE = 50;
|
||||
static constexpr uint32_t VC0_LIVE_TM_QUEUE_SIZE = 300;
|
||||
// There are three individual log stores!
|
||||
static constexpr uint32_t MISC_STORE_QUEUE_SIZE = 200;
|
||||
static constexpr uint32_t OK_STORE_QUEUE_SIZE = 350;
|
||||
static constexpr uint32_t NOK_STORE_QUEUE_SIZE = 350;
|
||||
static constexpr uint32_t HK_STORE_QUEUE_SIZE = 300;
|
||||
static constexpr uint32_t CFDP_STORE_QUEUE_SIZE = 300;
|
||||
|
||||
static constexpr uint32_t MAX_PUS_FUNNEL_QUEUE_DEPTH = 100;
|
||||
static constexpr uint32_t MAX_CFDP_FUNNEL_QUEUE_DEPTH = 80;
|
||||
|
||||
static constexpr uint32_t MAX_STORED_CMDS_UDP = 120;
|
||||
static constexpr uint32_t MAX_STORED_CMDS_TCP = 120;
|
||||
static constexpr uint32_t MAX_STORED_CMDS_UDP = 150;
|
||||
static constexpr uint32_t MAX_STORED_CMDS_TCP = 180;
|
||||
|
||||
namespace spiSched {
|
||||
|
||||
static constexpr uint32_t SCHED_BLOCK_1_SUS_READ_MS = 15;
|
||||
static constexpr uint32_t SCHED_BLOCK_2_SENSOR_READ_MS = 30;
|
||||
static constexpr uint32_t SCHED_BLOCK_3_READ_IMTQ_MGM_MS = 43;
|
||||
static constexpr uint32_t SCHED_BLOCK_4_ACS_CTRL_MS = 45;
|
||||
static constexpr uint32_t SCHED_BLOCK_5_ACTUATOR_MS = 55;
|
||||
static constexpr uint32_t SCHED_BLOCK_6_IMTQ_BLOCK_2_MS = 105;
|
||||
static constexpr uint32_t SCHED_BLOCK_RTD = 150;
|
||||
static constexpr uint32_t SCHED_BLOCK_7_RW_READ_MS = 300;
|
||||
static constexpr uint32_t SCHED_BLOCK_8_PLPCDU_MS = 320;
|
||||
static constexpr uint32_t SCHED_BLOCK_9_RAD_SENS_MS = 340;
|
||||
|
||||
// 15 ms for FM
|
||||
static constexpr float SCHED_BLOCK_1_PERIOD = static_cast<float>(SCHED_BLOCK_1_SUS_READ_MS) / 400.0;
|
||||
static constexpr float SCHED_BLOCK_2_PERIOD =
|
||||
static_cast<float>(SCHED_BLOCK_2_SENSOR_READ_MS) / 400.0;
|
||||
static constexpr float SCHED_BLOCK_3_PERIOD =
|
||||
static_cast<float>(SCHED_BLOCK_3_READ_IMTQ_MGM_MS) / 400.0;
|
||||
static constexpr float SCHED_BLOCK_4_PERIOD = static_cast<float>(SCHED_BLOCK_4_ACS_CTRL_MS) / 400.0;
|
||||
static constexpr float SCHED_BLOCK_5_PERIOD = static_cast<float>(SCHED_BLOCK_5_ACTUATOR_MS) / 400.0;
|
||||
static constexpr float SCHED_BLOCK_6_PERIOD =
|
||||
static_cast<float>(SCHED_BLOCK_6_IMTQ_BLOCK_2_MS) / 400.0;
|
||||
static constexpr float SCHED_BLOCK_RTD_PERIOD = static_cast<float>(SCHED_BLOCK_RTD) / 400.0;
|
||||
static constexpr float SCHED_BLOCK_7_PERIOD = static_cast<float>(SCHED_BLOCK_7_RW_READ_MS) / 400.0;
|
||||
static constexpr float SCHED_BLOCK_8_PERIOD = static_cast<float>(SCHED_BLOCK_8_PLPCDU_MS) / 400.0;
|
||||
static constexpr float SCHED_BLOCK_9_PERIOD = static_cast<float>(SCHED_BLOCK_9_RAD_SENS_MS) / 400.0;
|
||||
|
||||
} // namespace spiSched
|
||||
|
||||
} // namespace config
|
||||
|
||||
|
@ -36,6 +36,9 @@ enum : uint8_t {
|
||||
SCEX_HANDLER = 138,
|
||||
CONFIGHANDLER = 139,
|
||||
CORE = 140,
|
||||
TCS_CONTROLLER = 141,
|
||||
COM_SUBSYSTEM = 142,
|
||||
PERSISTENT_TM_STORE = 143,
|
||||
COMMON_SUBSYSTEM_ID_END
|
||||
|
||||
};
|
||||
|
@ -44,13 +44,14 @@ enum commonObjects : uint32_t {
|
||||
STAR_TRACKER = 0x44130001,
|
||||
GPS_CONTROLLER = 0x44130045,
|
||||
|
||||
IMTQ_POLLING = 0x44140013,
|
||||
IMTQ_HANDLER = 0x44140014,
|
||||
TMP1075_HANDLER_TCS_0 = 0x44420004,
|
||||
TMP1075_HANDLER_TCS_1 = 0x44420005,
|
||||
TMP1075_HANDLER_PLPCDU_0 = 0x44420006,
|
||||
TMP1075_HANDLER_PLPCDU_1 = 0x44420007,
|
||||
TMP1075_HANDLER_IF_BOARD = 0x44420008,
|
||||
TMP1075_HANDLER_OBC_IF_BOARD = 0x44420009,
|
||||
|
||||
PCDU_HANDLER = 0x442000A1,
|
||||
P60DOCK_HANDLER = 0x44250000,
|
||||
PDU1_HANDLER = 0x44250001,
|
||||
@ -65,6 +66,10 @@ enum commonObjects : uint32_t {
|
||||
PLOC_MPSOC_HELPER = 0x44330003,
|
||||
AXI_PTME_CONFIG = 0x44330004,
|
||||
PTME_CONFIG = 0x44330005,
|
||||
PTME_VC0_LIVE_TM = 0x44330006,
|
||||
PTME_VC1_LOG_TM = 0x44330007,
|
||||
PTME_VC2_HK_TM = 0x44330008,
|
||||
PTME_VC3_CFDP_TM = 0x44330009,
|
||||
PLOC_MPSOC_HANDLER = 0x44330015,
|
||||
PLOC_SUPERVISOR_HANDLER = 0x44330016,
|
||||
PLOC_SUPERVISOR_HELPER = 0x44330017,
|
||||
@ -122,7 +127,10 @@ enum commonObjects : uint32_t {
|
||||
// CCSDS_IP_CORE_BRIDGE = 0x73500000,
|
||||
|
||||
/* 0x49 ('I') for Communication Interfaces */
|
||||
SPI_RTD_COM_IF = 0x49020006,
|
||||
ACS_BOARD_POLLING_TASK = 0x49060004,
|
||||
RW_POLLING_TASK = 0x49060005,
|
||||
SPI_RTD_COM_IF = 0x49060006,
|
||||
SUS_POLLING_TASK = 0x49060007,
|
||||
|
||||
// 0x60 for other stuff
|
||||
HEATER_0_PLOC_PROC_BRD = 0x60000000,
|
||||
@ -132,14 +140,17 @@ enum commonObjects : uint32_t {
|
||||
HEATER_4_CAMERA = 0x60000004,
|
||||
HEATER_5_STR = 0x60000005,
|
||||
HEATER_6_DRO = 0x60000006,
|
||||
HEATER_7_HPA = 0x60000007,
|
||||
HEATER_7_SYRLINKS = 0x60000007,
|
||||
|
||||
// 0x73 ('s') for assemblies and system/subsystem components
|
||||
ACS_BOARD_ASS = 0x73000001,
|
||||
SUS_BOARD_ASS = 0x73000002,
|
||||
TCS_BOARD_ASS = 0x73000003,
|
||||
RW_ASS = 0x73000004,
|
||||
RW_ASSY = 0x73000004,
|
||||
CAM_SWITCHER = 0x73000006,
|
||||
SYRLINKS_ASSY = 0x73000007,
|
||||
IMTQ_ASSY = 0x73000008,
|
||||
STR_ASSY = 0x73000009,
|
||||
EIVE_SYSTEM = 0x73010000,
|
||||
ACS_SUBSYSTEM = 0x73010001,
|
||||
PL_SUBSYSTEM = 0x73010002,
|
||||
@ -151,6 +162,20 @@ enum commonObjects : uint32_t {
|
||||
CFDP_TM_FUNNEL = 0x73000102,
|
||||
CFDP_HANDLER = 0x73000205,
|
||||
CFDP_DISTRIBUTOR = 0x73000206,
|
||||
MISC_TM_STORE = 0x73020001,
|
||||
OK_TM_STORE = 0x73020002,
|
||||
NOT_OK_TM_STORE = 0x73020003,
|
||||
HK_TM_STORE = 0x73020004,
|
||||
CFDP_TM_STORE = 0x73030000,
|
||||
|
||||
LIVE_TM_TASK = 0x73040000,
|
||||
LOG_STORE_AND_TM_TASK = 0x73040001,
|
||||
HK_STORE_AND_TM_TASK = 0x73040002,
|
||||
CFDP_STORE_AND_TM_TASK = 0x73040003,
|
||||
DOWNLINK_RAM_STORE = 0x73040004,
|
||||
|
||||
// Other stuff
|
||||
THERMAL_TEMP_INSERTER = 0x90000003,
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -35,9 +35,17 @@ enum commonClassIds : uint8_t {
|
||||
SA_DEPL_HANDLER, // SADPL
|
||||
MPSOC_RETURN_VALUES_IF, // MPSOCRTVIF
|
||||
SUPV_RETURN_VALUES_IF, // SPVRTVIF
|
||||
ACS_CTRL, // ACSCTRL
|
||||
ACS_MEKF, // ACSMEKF
|
||||
ACS_SAFE, // ACSSAF
|
||||
ACS_PTG, // ACSPTG
|
||||
ACS_DETUMBLE, // ACSDTB
|
||||
SD_CARD_MANAGER, // SDMA
|
||||
LOCAL_PARAM_HANDLER, // LPH
|
||||
PERSISTENT_TM_STORE, // PTM
|
||||
TM_SINK, // TMS
|
||||
COMMON_CLASS_ID_END // [EXPORT] : [END]
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif /* COMMON_CONFIG_COMMONCLASSIDS_H_ */
|
||||
|
@ -12,6 +12,7 @@ enum Ids {
|
||||
PUS_SERVICE_8 = 8,
|
||||
PUS_SERVICE_9 = 9,
|
||||
PUS_SERVICE_11 = 11,
|
||||
PUS_SERVICE_15 = 15,
|
||||
PUS_SERVICE_17 = 17,
|
||||
PUS_SERVICE_19 = 19,
|
||||
PUS_SERVICE_20 = 20,
|
||||
|
@ -7,9 +7,9 @@ AcuDummy::AcuDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
|
||||
AcuDummy::~AcuDummy() {}
|
||||
|
||||
void AcuDummy::doStartUp() {}
|
||||
void AcuDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void AcuDummy::doShutDown() {}
|
||||
void AcuDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t AcuDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) { return NOTHING_TO_SEND; }
|
||||
|
||||
@ -37,6 +37,7 @@ uint32_t AcuDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return
|
||||
|
||||
ReturnValue_t AcuDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(ACU::pool::ACU_TEMPERATURES, new PoolEntry<float>(3));
|
||||
localDataPoolMap.emplace(ACU::pool::ACU_TEMPERATURES,
|
||||
new PoolEntry<float>({10.0, 10.0, 10.0}, true));
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
@ -7,9 +7,9 @@ BpxDummy::BpxDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
|
||||
BpxDummy::~BpxDummy() {}
|
||||
|
||||
void BpxDummy::doStartUp() {}
|
||||
void BpxDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void BpxDummy::doShutDown() {}
|
||||
void BpxDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t BpxDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) { return NOTHING_TO_SEND; }
|
||||
|
||||
|
@ -34,10 +34,10 @@ class BpxDummy : public DeviceHandlerBase {
|
||||
PoolEntry<uint16_t> dischargeCurrent = PoolEntry<uint16_t>({0});
|
||||
PoolEntry<uint16_t> heaterCurrent = PoolEntry<uint16_t>({0});
|
||||
PoolEntry<uint16_t> battVolt = PoolEntry<uint16_t>({0});
|
||||
PoolEntry<int16_t> battTemp1 = PoolEntry<int16_t>({0});
|
||||
PoolEntry<int16_t> battTemp2 = PoolEntry<int16_t>({0});
|
||||
PoolEntry<int16_t> battTemp3 = PoolEntry<int16_t>({0});
|
||||
PoolEntry<int16_t> battTemp4 = PoolEntry<int16_t>({0});
|
||||
PoolEntry<int16_t> battTemp1 = PoolEntry<int16_t>({10}, true);
|
||||
PoolEntry<int16_t> battTemp2 = PoolEntry<int16_t>({10}, true);
|
||||
PoolEntry<int16_t> battTemp3 = PoolEntry<int16_t>({10}, true);
|
||||
PoolEntry<int16_t> battTemp4 = PoolEntry<int16_t>({10}, true);
|
||||
PoolEntry<uint32_t> rebootCounter = PoolEntry<uint32_t>({0});
|
||||
PoolEntry<uint8_t> bootCause = PoolEntry<uint8_t>({0});
|
||||
PoolEntry<uint8_t> battheatMode = PoolEntry<uint8_t>({0});
|
||||
|
@ -1,11 +1,13 @@
|
||||
target_sources(
|
||||
${LIB_DUMMIES}
|
||||
PUBLIC TemperatureSensorsDummy.cpp
|
||||
PUBLIC TemperatureSensorInserter.cpp
|
||||
SusDummy.cpp
|
||||
BpxDummy.cpp
|
||||
ComIFDummy.cpp
|
||||
ComCookieDummy.cpp
|
||||
RwDummy.cpp
|
||||
Max31865Dummy.cpp
|
||||
PcduHandlerDummy.cpp
|
||||
StarTrackerDummy.cpp
|
||||
SyrlinksDummy.cpp
|
||||
ImtqDummy.cpp
|
||||
@ -13,11 +15,17 @@ target_sources(
|
||||
PduDummy.cpp
|
||||
P60DockDummy.cpp
|
||||
SaDeploymentDummy.cpp
|
||||
GpsDummy.cpp
|
||||
GpsDhbDummy.cpp
|
||||
GpsCtrlDummy.cpp
|
||||
GyroAdisDummy.cpp
|
||||
GyroL3GD20Dummy.cpp
|
||||
MgmLIS3MDLDummy.cpp
|
||||
PlPcduDummy.cpp
|
||||
ExecutableComIfDummy.cpp
|
||||
ScexDummy.cpp
|
||||
CoreControllerDummy.cpp
|
||||
PlocMpsocDummy.cpp
|
||||
PlocSupervisorDummy.cpp
|
||||
helpers.cpp
|
||||
MgmRm3100Dummy.cpp)
|
||||
MgmRm3100Dummy.cpp
|
||||
Tmp1075Dummy.cpp)
|
||||
|
@ -1,7 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include <fsfw/controller/ExtendedControllerBase.h>
|
||||
#include <mission/devices/devicedefinitions/SusDefinitions.h>
|
||||
#include <mission/devices/devicedefinitions/susMax1227Helpers.h>
|
||||
|
||||
class CoreControllerDummy : public ExtendedControllerBase {
|
||||
public:
|
||||
|
27
dummies/ExecutableComIfDummy.cpp
Normal file
27
dummies/ExecutableComIfDummy.cpp
Normal file
@ -0,0 +1,27 @@
|
||||
#include <dummies/ExecutableComIfDummy.h>
|
||||
|
||||
ExecutableComIfDummy::ExecutableComIfDummy(object_id_t objectId) : SystemObject(objectId) {}
|
||||
|
||||
ReturnValue_t ExecutableComIfDummy::initializeInterface(CookieIF *cookie) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t ExecutableComIfDummy::sendMessage(CookieIF *cookie, const uint8_t *sendData,
|
||||
size_t sendLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t ExecutableComIfDummy::getSendSuccess(CookieIF *cookie) { return returnvalue::OK; }
|
||||
|
||||
ReturnValue_t ExecutableComIfDummy::requestReceiveMessage(CookieIF *cookie, size_t requestLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t ExecutableComIfDummy::performOperation(uint8_t operationCode) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t ExecutableComIfDummy::readReceivedMessage(CookieIF *cookie, uint8_t **buffer,
|
||||
size_t *size) {
|
||||
return returnvalue::OK;
|
||||
}
|
21
dummies/ExecutableComIfDummy.h
Normal file
21
dummies/ExecutableComIfDummy.h
Normal file
@ -0,0 +1,21 @@
|
||||
#ifndef DUMMIES_EXECUTABLECOMIFDUMMY_H_
|
||||
#define DUMMIES_EXECUTABLECOMIFDUMMY_H_
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceCommunicationIF.h>
|
||||
#include <fsfw/objectmanager/SystemObject.h>
|
||||
#include <fsfw/tasks/ExecutableObjectIF.h>
|
||||
|
||||
class ExecutableComIfDummy : public ExecutableObjectIF,
|
||||
public DeviceCommunicationIF,
|
||||
public SystemObject {
|
||||
public:
|
||||
ExecutableComIfDummy(object_id_t objectId);
|
||||
ReturnValue_t performOperation(uint8_t operationCode = 0) override;
|
||||
ReturnValue_t initializeInterface(CookieIF *cookie) override;
|
||||
ReturnValue_t sendMessage(CookieIF *cookie, const uint8_t *sendData, size_t sendLen) override;
|
||||
ReturnValue_t getSendSuccess(CookieIF *cookie) override;
|
||||
ReturnValue_t requestReceiveMessage(CookieIF *cookie, size_t requestLen) override;
|
||||
ReturnValue_t readReceivedMessage(CookieIF *cookie, uint8_t **buffer, size_t *size) override;
|
||||
};
|
||||
|
||||
#endif /* DUMMIES_EXECUTABLECOMIFDUMMY_H_ */
|
36
dummies/GpsCtrlDummy.cpp
Normal file
36
dummies/GpsCtrlDummy.cpp
Normal file
@ -0,0 +1,36 @@
|
||||
#include "GpsCtrlDummy.h"
|
||||
|
||||
GpsCtrlDummy::GpsCtrlDummy(object_id_t objectId)
|
||||
: ExtendedControllerBase(objectId, 20), gpsSet(this) {}
|
||||
|
||||
ReturnValue_t GpsCtrlDummy::handleCommandMessage(CommandMessage* message) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void GpsCtrlDummy::performControlOperation() {}
|
||||
|
||||
ReturnValue_t GpsCtrlDummy::checkModeCommand(Mode_t mode, Submode_t submode,
|
||||
uint32_t* msToReachTheMode) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
LocalPoolDataSetBase* GpsCtrlDummy::getDataSetHandle(sid_t sid) { return &gpsSet; }
|
||||
|
||||
ReturnValue_t GpsCtrlDummy::initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
|
||||
LocalDataPoolManager& poolManager) {
|
||||
localDataPoolMap.emplace(GpsHyperion::ALTITUDE, new PoolEntry<double>({537222.3469}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::LONGITUDE, new PoolEntry<double>({-8.8579}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::LATITUDE, new PoolEntry<double>({49.5952}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::SPEED, new PoolEntry<double>({0}));
|
||||
localDataPoolMap.emplace(GpsHyperion::YEAR, new PoolEntry<uint16_t>({2023}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::MONTH, new PoolEntry<uint8_t>({5}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::DAY, new PoolEntry<uint8_t>({16}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::HOURS, new PoolEntry<uint8_t>({1}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::MINUTES, new PoolEntry<uint8_t>({0}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::SECONDS, new PoolEntry<uint8_t>({0}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::UNIX_SECONDS, new PoolEntry<uint32_t>({1684191600}, true));
|
||||
localDataPoolMap.emplace(GpsHyperion::SATS_IN_USE, new PoolEntry<uint8_t>());
|
||||
localDataPoolMap.emplace(GpsHyperion::SATS_IN_VIEW, new PoolEntry<uint8_t>());
|
||||
localDataPoolMap.emplace(GpsHyperion::FIX_MODE, new PoolEntry<uint8_t>());
|
||||
return returnvalue::OK;
|
||||
}
|
23
dummies/GpsCtrlDummy.h
Normal file
23
dummies/GpsCtrlDummy.h
Normal file
@ -0,0 +1,23 @@
|
||||
#ifndef DUMMIES_GPSCTRLDUMMY_H_
|
||||
#define DUMMIES_GPSCTRLDUMMY_H_
|
||||
|
||||
#include <fsfw/controller/ExtendedControllerBase.h>
|
||||
#include <mission/devices/devicedefinitions/GPSDefinitions.h>
|
||||
|
||||
class GpsCtrlDummy : public ExtendedControllerBase {
|
||||
public:
|
||||
GpsCtrlDummy(object_id_t objectId);
|
||||
|
||||
private:
|
||||
GpsPrimaryDataset gpsSet;
|
||||
|
||||
ReturnValue_t handleCommandMessage(CommandMessage* message) override;
|
||||
void performControlOperation() override;
|
||||
ReturnValue_t checkModeCommand(Mode_t mode, Submode_t submode,
|
||||
uint32_t* msToReachTheMode) override;
|
||||
ReturnValue_t initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
|
||||
LocalDataPoolManager& poolManager) override;
|
||||
LocalPoolDataSetBase* getDataSetHandle(sid_t sid) override;
|
||||
};
|
||||
|
||||
#endif /* DUMMIES_GPSCTRLDUMMY_H_ */
|
@ -1,42 +1,44 @@
|
||||
#include "GpsDummy.h"
|
||||
|
||||
#include <dummies/GpsDhbDummy.h>
|
||||
#include <mission/devices/devicedefinitions/GPSDefinitions.h>
|
||||
|
||||
GpsDummy::GpsDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
GpsDhbDummy::GpsDhbDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie) {}
|
||||
|
||||
GpsDummy::~GpsDummy() {}
|
||||
GpsDhbDummy::~GpsDhbDummy() {}
|
||||
|
||||
void GpsDummy::doStartUp() {}
|
||||
void GpsDhbDummy::doStartUp() {}
|
||||
|
||||
void GpsDummy::doShutDown() {}
|
||||
void GpsDhbDummy::doShutDown() {}
|
||||
|
||||
ReturnValue_t GpsDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) { return NOTHING_TO_SEND; }
|
||||
|
||||
ReturnValue_t GpsDummy::buildTransitionDeviceCommand(DeviceCommandId_t *id) {
|
||||
ReturnValue_t GpsDhbDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t GpsDummy::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
|
||||
const uint8_t *commandData, size_t commandDataLen) {
|
||||
ReturnValue_t GpsDhbDummy::buildTransitionDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t GpsDhbDummy::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
|
||||
const uint8_t *commandData,
|
||||
size_t commandDataLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t GpsDummy::scanForReply(const uint8_t *start, size_t len, DeviceCommandId_t *foundId,
|
||||
size_t *foundLen) {
|
||||
ReturnValue_t GpsDhbDummy::scanForReply(const uint8_t *start, size_t len,
|
||||
DeviceCommandId_t *foundId, size_t *foundLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t GpsDummy::interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) {
|
||||
ReturnValue_t GpsDhbDummy::interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void GpsDummy::fillCommandAndReplyMap() {}
|
||||
void GpsDhbDummy::fillCommandAndReplyMap() {}
|
||||
|
||||
uint32_t GpsDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 500; }
|
||||
uint32_t GpsDhbDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 500; }
|
||||
|
||||
ReturnValue_t GpsDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
ReturnValue_t GpsDhbDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(GpsHyperion::LATITUDE, new PoolEntry<double>({0.0}, 1));
|
||||
localDataPoolMap.emplace(GpsHyperion::LONGITUDE, new PoolEntry<double>({0.0}, 1));
|
||||
localDataPoolMap.emplace(GpsHyperion::ALTITUDE, new PoolEntry<double>({0.0}));
|
33
dummies/GpsDhbDummy.h
Normal file
33
dummies/GpsDhbDummy.h
Normal file
@ -0,0 +1,33 @@
|
||||
#ifndef DUMMIES_GPSDHBDUMMY_H_
|
||||
#define DUMMIES_GPSDHBDUMMY_H_
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
|
||||
|
||||
class GpsDhbDummy : public DeviceHandlerBase {
|
||||
public:
|
||||
static const DeviceCommandId_t SIMPLE_COMMAND = 1;
|
||||
static const DeviceCommandId_t PERIODIC_REPLY = 2;
|
||||
|
||||
static const uint8_t SIMPLE_COMMAND_DATA = 1;
|
||||
static const uint8_t PERIODIC_REPLY_DATA = 2;
|
||||
|
||||
GpsDhbDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie);
|
||||
virtual ~GpsDhbDummy();
|
||||
|
||||
protected:
|
||||
void doStartUp() override;
|
||||
void doShutDown() override;
|
||||
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildTransitionDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildCommandFromCommand(DeviceCommandId_t deviceCommand, const uint8_t *commandData,
|
||||
size_t commandDataLen) override;
|
||||
ReturnValue_t scanForReply(const uint8_t *start, size_t len, DeviceCommandId_t *foundId,
|
||||
size_t *foundLen) override;
|
||||
ReturnValue_t interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) override;
|
||||
void fillCommandAndReplyMap() override;
|
||||
uint32_t getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) override;
|
||||
ReturnValue_t initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) override;
|
||||
};
|
||||
|
||||
#endif /* DUMMIES_GPSDHBDUMMY_H_ */
|
@ -1,15 +1,15 @@
|
||||
#include "GyroAdisDummy.h"
|
||||
|
||||
#include "mission/devices/devicedefinitions/GyroADIS1650XDefinitions.h"
|
||||
#include <mission/devices/devicedefinitions/gyroAdisHelpers.h>
|
||||
|
||||
GyroAdisDummy::GyroAdisDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie), dataset(this) {}
|
||||
|
||||
GyroAdisDummy::~GyroAdisDummy() {}
|
||||
|
||||
void GyroAdisDummy::doStartUp() {}
|
||||
void GyroAdisDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void GyroAdisDummy::doShutDown() {}
|
||||
void GyroAdisDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t GyroAdisDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
@ -40,13 +40,13 @@ uint32_t GyroAdisDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { r
|
||||
|
||||
ReturnValue_t GyroAdisDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(ADIS1650X::ANG_VELOC_X, new PoolEntry<double>({-0.5}, true));
|
||||
localDataPoolMap.emplace(ADIS1650X::ANG_VELOC_Y, new PoolEntry<double>({0.2}, true));
|
||||
localDataPoolMap.emplace(ADIS1650X::ANG_VELOC_Z, new PoolEntry<double>({-1.2}, true));
|
||||
localDataPoolMap.emplace(ADIS1650X::ACCELERATION_X, new PoolEntry<double>({0.0}));
|
||||
localDataPoolMap.emplace(ADIS1650X::ACCELERATION_Y, new PoolEntry<double>({0.0}));
|
||||
localDataPoolMap.emplace(ADIS1650X::ACCELERATION_Z, new PoolEntry<double>({0.0}));
|
||||
localDataPoolMap.emplace(ADIS1650X::TEMPERATURE, new PoolEntry<float>({0.0}));
|
||||
localDataPoolMap.emplace(adis1650x::ANG_VELOC_X, new PoolEntry<double>({-0.5}, true));
|
||||
localDataPoolMap.emplace(adis1650x::ANG_VELOC_Y, new PoolEntry<double>({0.2}, true));
|
||||
localDataPoolMap.emplace(adis1650x::ANG_VELOC_Z, new PoolEntry<double>({-1.2}, true));
|
||||
localDataPoolMap.emplace(adis1650x::ACCELERATION_X, new PoolEntry<double>({0.0}));
|
||||
localDataPoolMap.emplace(adis1650x::ACCELERATION_Y, new PoolEntry<double>({0.0}));
|
||||
localDataPoolMap.emplace(adis1650x::ACCELERATION_Z, new PoolEntry<double>({0.0}));
|
||||
localDataPoolMap.emplace(adis1650x::TEMPERATURE, new PoolEntry<float>({0.0}));
|
||||
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
@ -2,8 +2,7 @@
|
||||
#define DUMMIES_GYROADISDUMMY_H_
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
|
||||
|
||||
#include "mission/devices/devicedefinitions/GyroADIS1650XDefinitions.h"
|
||||
#include <mission/devices/devicedefinitions/gyroAdisHelpers.h>
|
||||
|
||||
class GyroAdisDummy : public DeviceHandlerBase {
|
||||
public:
|
||||
|
@ -1,15 +1,15 @@
|
||||
#include "GyroL3GD20Dummy.h"
|
||||
|
||||
#include "fsfw_hal/devicehandlers/devicedefinitions/GyroL3GD20Definitions.h"
|
||||
#include <fsfw_hal/devicehandlers/devicedefinitions/gyroL3gHelpers.h>
|
||||
|
||||
GyroL3GD20Dummy::GyroL3GD20Dummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie) {}
|
||||
|
||||
GyroL3GD20Dummy::~GyroL3GD20Dummy() {}
|
||||
|
||||
void GyroL3GD20Dummy::doStartUp() {}
|
||||
void GyroL3GD20Dummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void GyroL3GD20Dummy::doShutDown() {}
|
||||
void GyroL3GD20Dummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t GyroL3GD20Dummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
@ -40,9 +40,9 @@ uint32_t GyroL3GD20Dummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) {
|
||||
|
||||
ReturnValue_t GyroL3GD20Dummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(L3GD20H::ANG_VELOC_X, new PoolEntry<float>({1.2}, true));
|
||||
localDataPoolMap.emplace(L3GD20H::ANG_VELOC_Y, new PoolEntry<float>({-0.1}, true));
|
||||
localDataPoolMap.emplace(L3GD20H::ANG_VELOC_Z, new PoolEntry<float>({0.7}, true));
|
||||
localDataPoolMap.emplace(L3GD20H::TEMPERATURE, new PoolEntry<float>({0.0}));
|
||||
localDataPoolMap.emplace(l3gd20h::ANG_VELOC_X, new PoolEntry<float>({1.2}, true));
|
||||
localDataPoolMap.emplace(l3gd20h::ANG_VELOC_Y, new PoolEntry<float>({-0.1}, true));
|
||||
localDataPoolMap.emplace(l3gd20h::ANG_VELOC_Z, new PoolEntry<float>({0.7}, true));
|
||||
localDataPoolMap.emplace(l3gd20h::TEMPERATURE, new PoolEntry<float>({0.0}));
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
@ -1,15 +1,15 @@
|
||||
#include "ImtqDummy.h"
|
||||
|
||||
#include <mission/devices/devicedefinitions/imtqHandlerDefinitions.h>
|
||||
#include <mission/devices/devicedefinitions/imtqHelpers.h>
|
||||
|
||||
ImtqDummy::ImtqDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie) {}
|
||||
|
||||
ImtqDummy::~ImtqDummy() {}
|
||||
ImtqDummy::~ImtqDummy() = default;
|
||||
|
||||
void ImtqDummy::doStartUp() {}
|
||||
void ImtqDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void ImtqDummy::doShutDown() {}
|
||||
void ImtqDummy::doShutDown() { setMode(_MODE_POWER_DOWN); }
|
||||
|
||||
ReturnValue_t ImtqDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) { return NOTHING_TO_SEND; }
|
||||
|
||||
@ -38,10 +38,10 @@ uint32_t ImtqDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { retur
|
||||
|
||||
ReturnValue_t ImtqDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(IMTQ::MCU_TEMPERATURE, new PoolEntry<int16_t>({0}));
|
||||
localDataPoolMap.emplace(IMTQ::MGM_CAL_NT, new PoolEntry<float>({0.0, 0.0, 0.0}));
|
||||
localDataPoolMap.emplace(IMTQ::ACTUATION_CAL_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(IMTQ::MTM_RAW, new PoolEntry<float>({0.12, 0.76, -0.45}, true));
|
||||
localDataPoolMap.emplace(IMTQ::ACTUATION_RAW_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
return returnvalue::OK;
|
||||
localDataPoolMap.emplace(imtq::MCU_TEMPERATURE, new PoolEntry<int16_t>({0}));
|
||||
localDataPoolMap.emplace(imtq::MGM_CAL_NT, new PoolEntry<float>({0.0, 0.0, 0.0}));
|
||||
localDataPoolMap.emplace(imtq::ACTUATION_CAL_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(imtq::MTM_RAW, new PoolEntry<float>({0.12, 0.76, -0.45}, true));
|
||||
localDataPoolMap.emplace(imtq::ACTUATION_RAW_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
return DeviceHandlerBase::initializeLocalDataPool(localDataPoolMap, poolManager);
|
||||
}
|
||||
|
@ -12,7 +12,7 @@ class ImtqDummy : public DeviceHandlerBase {
|
||||
static const uint8_t PERIODIC_REPLY_DATA = 2;
|
||||
|
||||
ImtqDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie);
|
||||
virtual ~ImtqDummy();
|
||||
~ImtqDummy() override;
|
||||
|
||||
protected:
|
||||
void doStartUp() override;
|
||||
|
45
dummies/Max31865Dummy.cpp
Normal file
45
dummies/Max31865Dummy.cpp
Normal file
@ -0,0 +1,45 @@
|
||||
#include "Max31865Dummy.h"
|
||||
|
||||
using namespace returnvalue;
|
||||
|
||||
Max31865Dummy::Max31865Dummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie), set(this, EiveMax31855::EXCHANGE_SET_ID) {}
|
||||
void Max31865Dummy::doStartUp() { setMode(MODE_ON); }
|
||||
void Max31865Dummy::doShutDown() { setMode(_MODE_POWER_DOWN); }
|
||||
ReturnValue_t Max31865Dummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
ReturnValue_t Max31865Dummy::buildTransitionDeviceCommand(DeviceCommandId_t *id) { return OK; }
|
||||
ReturnValue_t Max31865Dummy::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
|
||||
const uint8_t *commandData,
|
||||
size_t commandDataLen) {
|
||||
return 0;
|
||||
}
|
||||
ReturnValue_t Max31865Dummy::scanForReply(const uint8_t *start, size_t len,
|
||||
DeviceCommandId_t *foundId, size_t *foundLen) {
|
||||
return 0;
|
||||
}
|
||||
ReturnValue_t Max31865Dummy::interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) {
|
||||
return 0;
|
||||
}
|
||||
void Max31865Dummy::fillCommandAndReplyMap() {}
|
||||
uint32_t Max31865Dummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 0; }
|
||||
ReturnValue_t Max31865Dummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
using namespace MAX31865;
|
||||
localDataPoolMap.emplace(static_cast<lp_id_t>(PoolIds::RTD_VALUE), new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(static_cast<lp_id_t>(PoolIds::TEMPERATURE_C), new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(static_cast<lp_id_t>(PoolIds::LAST_FAULT_BYTE),
|
||||
new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(static_cast<lp_id_t>(PoolIds::FAULT_BYTE), new PoolEntry<uint8_t>({0}));
|
||||
return OK;
|
||||
}
|
||||
|
||||
void Max31865Dummy::setTemperature(float temperature) {
|
||||
set.temperatureCelcius.value = temperature;
|
||||
}
|
||||
|
||||
LocalPoolDataSetBase *Max31865Dummy::getDataSetHandle(sid_t sid) { return &set; }
|
||||
Max31865Dummy::Max31865Dummy(object_id_t objectId, CookieIF *cookie)
|
||||
: DeviceHandlerBase(objectId, objects::DUMMY_COM_IF, cookie),
|
||||
set(this, EiveMax31855::EXCHANGE_SET_ID) {}
|
33
dummies/Max31865Dummy.h
Normal file
33
dummies/Max31865Dummy.h
Normal file
@ -0,0 +1,33 @@
|
||||
#ifndef EIVE_OBSW_MAX31865DUMMY_H
|
||||
#define EIVE_OBSW_MAX31865DUMMY_H
|
||||
|
||||
#include "fsfw/devicehandlers/DeviceHandlerBase.h"
|
||||
#include "mission/devices/devicedefinitions/Max31865Definitions.h"
|
||||
|
||||
class Max31865Dummy : public DeviceHandlerBase {
|
||||
public:
|
||||
Max31865Dummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie);
|
||||
Max31865Dummy(object_id_t objectId, CookieIF *comCookie);
|
||||
|
||||
void setTemperature(float temperature);
|
||||
|
||||
private:
|
||||
MAX31865::PrimarySet set;
|
||||
|
||||
void doStartUp() override;
|
||||
void doShutDown() override;
|
||||
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildTransitionDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildCommandFromCommand(DeviceCommandId_t deviceCommand, const uint8_t *commandData,
|
||||
size_t commandDataLen) override;
|
||||
ReturnValue_t scanForReply(const uint8_t *start, size_t len, DeviceCommandId_t *foundId,
|
||||
size_t *foundLen) override;
|
||||
ReturnValue_t interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) override;
|
||||
void fillCommandAndReplyMap() override;
|
||||
uint32_t getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) override;
|
||||
ReturnValue_t initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) override;
|
||||
LocalPoolDataSetBase *getDataSetHandle(sid_t sid) override;
|
||||
};
|
||||
|
||||
#endif // EIVE_OBSW_MAX31865DUMMY_H
|
@ -1,15 +1,15 @@
|
||||
#include "MgmLIS3MDLDummy.h"
|
||||
|
||||
#include "fsfw_hal/devicehandlers/devicedefinitions/MgmLIS3HandlerDefs.h"
|
||||
#include <fsfw_hal/devicehandlers/devicedefinitions/mgmLis3Helpers.h>
|
||||
|
||||
MgmLIS3MDLDummy::MgmLIS3MDLDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie), dataset(this) {}
|
||||
|
||||
MgmLIS3MDLDummy::~MgmLIS3MDLDummy() {}
|
||||
|
||||
void MgmLIS3MDLDummy::doStartUp() {}
|
||||
void MgmLIS3MDLDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void MgmLIS3MDLDummy::doShutDown() {}
|
||||
void MgmLIS3MDLDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t MgmLIS3MDLDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
@ -40,8 +40,8 @@ uint32_t MgmLIS3MDLDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) {
|
||||
|
||||
ReturnValue_t MgmLIS3MDLDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(MGMLIS3MDL::TEMPERATURE_CELCIUS, new PoolEntry<float>({0.0}));
|
||||
localDataPoolMap.emplace(MGMLIS3MDL::FIELD_STRENGTHS,
|
||||
localDataPoolMap.emplace(mgmLis3::TEMPERATURE_CELCIUS, new PoolEntry<float>({0.0}));
|
||||
localDataPoolMap.emplace(mgmLis3::FIELD_STRENGTHS,
|
||||
new PoolEntry<float>({1.02, 0.56, -0.78}, true));
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
@ -2,8 +2,7 @@
|
||||
#define DUMMIES_MGMLIS3MDLDUMMY_H_
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
|
||||
|
||||
#include "fsfw_hal/devicehandlers/devicedefinitions/MgmLIS3HandlerDefs.h"
|
||||
#include <fsfw_hal/devicehandlers/devicedefinitions/mgmLis3Helpers.h>
|
||||
|
||||
class MgmLIS3MDLDummy : public DeviceHandlerBase {
|
||||
public:
|
||||
@ -17,7 +16,7 @@ class MgmLIS3MDLDummy : public DeviceHandlerBase {
|
||||
virtual ~MgmLIS3MDLDummy();
|
||||
|
||||
protected:
|
||||
MGMLIS3MDL::MgmPrimaryDataset dataset;
|
||||
mgmLis3::MgmPrimaryDataset dataset;
|
||||
void doStartUp() override;
|
||||
void doShutDown() override;
|
||||
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t *id) override;
|
||||
|
@ -7,18 +7,22 @@ MgmRm3100Dummy::MgmRm3100Dummy(object_id_t objectId, object_id_t comif, CookieIF
|
||||
|
||||
MgmRm3100Dummy::~MgmRm3100Dummy() = default;
|
||||
|
||||
void MgmRm3100Dummy::doStartUp() {}
|
||||
void MgmRm3100Dummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void MgmRm3100Dummy::doShutDown() {}
|
||||
void MgmRm3100Dummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t MgmRm3100Dummy::buildNormalDeviceCommand(DeviceCommandId_t* id) { return OK; }
|
||||
ReturnValue_t MgmRm3100Dummy::buildNormalDeviceCommand(DeviceCommandId_t* id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t MgmRm3100Dummy::buildTransitionDeviceCommand(DeviceCommandId_t* id) { return OK; }
|
||||
ReturnValue_t MgmRm3100Dummy::buildTransitionDeviceCommand(DeviceCommandId_t* id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t MgmRm3100Dummy::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
|
||||
const uint8_t* commandData,
|
||||
size_t commandDataLen) {
|
||||
return OK;
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t MgmRm3100Dummy::scanForReply(const uint8_t* start, size_t len,
|
||||
@ -36,7 +40,7 @@ uint32_t MgmRm3100Dummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) {
|
||||
|
||||
ReturnValue_t MgmRm3100Dummy::initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
|
||||
LocalDataPoolManager& poolManager) {
|
||||
localDataPoolMap.emplace(RM3100::FIELD_STRENGTHS,
|
||||
localDataPoolMap.emplace(mgmRm3100::FIELD_STRENGTHS,
|
||||
new PoolEntry<float>({0.87, -0.95, 0.11}, true));
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
@ -1,8 +1,9 @@
|
||||
#ifndef DUMMIES_MGMRM3100DUMMY_H_
|
||||
#define DUMMIES_MGMRM3100DUMMY_H_
|
||||
|
||||
#include <fsfw_hal/devicehandlers/devicedefinitions/mgmRm3100Helpers.h>
|
||||
|
||||
#include "fsfw/devicehandlers/DeviceHandlerBase.h"
|
||||
#include "fsfw_hal/devicehandlers/devicedefinitions/MgmRM3100HandlerDefs.h"
|
||||
|
||||
class MgmRm3100Dummy : public DeviceHandlerBase {
|
||||
public:
|
||||
@ -10,7 +11,7 @@ class MgmRm3100Dummy : public DeviceHandlerBase {
|
||||
virtual ~MgmRm3100Dummy();
|
||||
|
||||
protected:
|
||||
RM3100::Rm3100PrimaryDataset dataset;
|
||||
mgmRm3100::Rm3100PrimaryDataset dataset;
|
||||
void doStartUp() override;
|
||||
void doShutDown() override;
|
||||
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t *id) override;
|
||||
|
@ -7,9 +7,9 @@ P60DockDummy::P60DockDummy(object_id_t objectId, object_id_t comif, CookieIF *co
|
||||
|
||||
P60DockDummy::~P60DockDummy() {}
|
||||
|
||||
void P60DockDummy::doStartUp() {}
|
||||
void P60DockDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void P60DockDummy::doShutDown() {}
|
||||
void P60DockDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t P60DockDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
@ -40,7 +40,9 @@ uint32_t P60DockDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { re
|
||||
|
||||
ReturnValue_t P60DockDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(P60Dock::pool::P60DOCK_TEMPERATURE_1, new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(P60Dock::pool::P60DOCK_TEMPERATURE_2, new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(P60Dock::pool::P60DOCK_TEMPERATURE_1,
|
||||
new PoolEntry<float>({10.0}, true));
|
||||
localDataPoolMap.emplace(P60Dock::pool::P60DOCK_TEMPERATURE_2,
|
||||
new PoolEntry<float>({10.0}, true));
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
62
dummies/PcduHandlerDummy.cpp
Normal file
62
dummies/PcduHandlerDummy.cpp
Normal file
@ -0,0 +1,62 @@
|
||||
#include "PcduHandlerDummy.h"
|
||||
|
||||
#include <mission/devices/devicedefinitions/GomspaceDefinitions.h>
|
||||
|
||||
PcduHandlerDummy::PcduHandlerDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie), dummySwitcher(objectId, 18, 18, false) {}
|
||||
|
||||
PcduHandlerDummy::~PcduHandlerDummy() {}
|
||||
|
||||
void PcduHandlerDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void PcduHandlerDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::buildTransitionDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
|
||||
const uint8_t *commandData,
|
||||
size_t commandDataLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::scanForReply(const uint8_t *start, size_t len,
|
||||
DeviceCommandId_t *foundId, size_t *foundLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void PcduHandlerDummy::fillCommandAndReplyMap() {}
|
||||
|
||||
uint32_t PcduHandlerDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 500; }
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::sendSwitchCommand(power::Switch_t switchNr, ReturnValue_t onOff) {
|
||||
return dummySwitcher.sendSwitchCommand(switchNr, onOff);
|
||||
}
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::sendFuseOnCommand(uint8_t fuseNr) {
|
||||
return dummySwitcher.sendFuseOnCommand(fuseNr);
|
||||
}
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::getSwitchState(power::Switch_t switchNr) const {
|
||||
return dummySwitcher.getSwitchState(switchNr);
|
||||
}
|
||||
|
||||
ReturnValue_t PcduHandlerDummy::getFuseState(uint8_t fuseNr) const {
|
||||
return dummySwitcher.getFuseState(fuseNr);
|
||||
}
|
||||
|
||||
uint32_t PcduHandlerDummy::getSwitchDelayMs(void) const { return dummySwitcher.getSwitchDelayMs(); }
|
39
dummies/PcduHandlerDummy.h
Normal file
39
dummies/PcduHandlerDummy.h
Normal file
@ -0,0 +1,39 @@
|
||||
#pragma once
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
|
||||
#include <fsfw/power/DummyPowerSwitcher.h>
|
||||
|
||||
class PcduHandlerDummy : public DeviceHandlerBase, public PowerSwitchIF {
|
||||
public:
|
||||
static const DeviceCommandId_t SIMPLE_COMMAND = 1;
|
||||
static const DeviceCommandId_t PERIODIC_REPLY = 2;
|
||||
|
||||
static const uint8_t SIMPLE_COMMAND_DATA = 1;
|
||||
static const uint8_t PERIODIC_REPLY_DATA = 2;
|
||||
|
||||
PcduHandlerDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie);
|
||||
virtual ~PcduHandlerDummy();
|
||||
|
||||
protected:
|
||||
DummyPowerSwitcher dummySwitcher;
|
||||
|
||||
void doStartUp() override;
|
||||
void doShutDown() override;
|
||||
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildTransitionDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildCommandFromCommand(DeviceCommandId_t deviceCommand, const uint8_t *commandData,
|
||||
size_t commandDataLen) override;
|
||||
ReturnValue_t scanForReply(const uint8_t *start, size_t len, DeviceCommandId_t *foundId,
|
||||
size_t *foundLen) override;
|
||||
ReturnValue_t interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) override;
|
||||
void fillCommandAndReplyMap() override;
|
||||
uint32_t getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) override;
|
||||
ReturnValue_t initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) override;
|
||||
|
||||
ReturnValue_t sendSwitchCommand(power::Switch_t switchNr, ReturnValue_t onOff) override;
|
||||
ReturnValue_t sendFuseOnCommand(uint8_t fuseNr) override;
|
||||
ReturnValue_t getSwitchState(power::Switch_t switchNr) const override;
|
||||
ReturnValue_t getFuseState(uint8_t fuseNr) const override;
|
||||
uint32_t getSwitchDelayMs(void) const override;
|
||||
};
|
@ -3,13 +3,14 @@
|
||||
#include <mission/devices/devicedefinitions/GomspaceDefinitions.h>
|
||||
|
||||
PduDummy::PduDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie) {}
|
||||
: DeviceHandlerBase(objectId, comif, comCookie),
|
||||
coreHk(this, static_cast<uint32_t>(P60System::SetIds::CORE)) {}
|
||||
|
||||
PduDummy::~PduDummy() {}
|
||||
|
||||
void PduDummy::doStartUp() {}
|
||||
void PduDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void PduDummy::doShutDown() {}
|
||||
void PduDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t PduDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) { return NOTHING_TO_SEND; }
|
||||
|
||||
@ -37,6 +38,8 @@ uint32_t PduDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return
|
||||
|
||||
ReturnValue_t PduDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(PDU::pool::PDU_TEMPERATURE, new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(PDU::pool::PDU_TEMPERATURE, new PoolEntry<float>({10.0}, true));
|
||||
localDataPoolMap.emplace(PDU::pool::PDU_VOLTAGES, &pduVoltages);
|
||||
localDataPoolMap.emplace(PDU::pool::PDU_CURRENTS, &pduCurrents);
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
@ -3,6 +3,8 @@
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
|
||||
|
||||
#include "mission/devices/devicedefinitions/GomspaceDefinitions.h"
|
||||
|
||||
class PduDummy : public DeviceHandlerBase {
|
||||
public:
|
||||
static const DeviceCommandId_t SIMPLE_COMMAND = 1;
|
||||
@ -15,6 +17,10 @@ class PduDummy : public DeviceHandlerBase {
|
||||
virtual ~PduDummy();
|
||||
|
||||
protected:
|
||||
PDU::PduCoreHk coreHk;
|
||||
PoolEntry<int16_t> pduVoltages = PoolEntry<int16_t>(9);
|
||||
PoolEntry<int16_t> pduCurrents = PoolEntry<int16_t>(9);
|
||||
|
||||
void doStartUp() override;
|
||||
void doShutDown() override;
|
||||
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t *id) override;
|
||||
|
@ -7,9 +7,9 @@ PlPcduDummy::PlPcduDummy(object_id_t objectId, object_id_t comif, CookieIF *comC
|
||||
|
||||
PlPcduDummy::~PlPcduDummy() {}
|
||||
|
||||
void PlPcduDummy::doStartUp() {}
|
||||
void PlPcduDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void PlPcduDummy::doShutDown() {}
|
||||
void PlPcduDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t PlPcduDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
@ -40,6 +40,6 @@ uint32_t PlPcduDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { ret
|
||||
|
||||
ReturnValue_t PlPcduDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(plpcdu::PlPcduPoolIds::TEMP, new PoolEntry<float>({0.0}));
|
||||
localDataPoolMap.emplace(plpcdu::PlPcduPoolIds::TEMP, new PoolEntry<float>({0.0}, true));
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
42
dummies/PlocMpsocDummy.cpp
Normal file
42
dummies/PlocMpsocDummy.cpp
Normal file
@ -0,0 +1,42 @@
|
||||
#include "PlocMpsocDummy.h"
|
||||
|
||||
PlocMpsocDummy::PlocMpsocDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie) {}
|
||||
|
||||
PlocMpsocDummy::~PlocMpsocDummy() {}
|
||||
|
||||
void PlocMpsocDummy::doStartUp() { setMode(MODE_ON); }
|
||||
|
||||
void PlocMpsocDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t PlocMpsocDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t PlocMpsocDummy::buildTransitionDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t PlocMpsocDummy::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
|
||||
const uint8_t *commandData,
|
||||
size_t commandDataLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t PlocMpsocDummy::scanForReply(const uint8_t *start, size_t len,
|
||||
DeviceCommandId_t *foundId, size_t *foundLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t PlocMpsocDummy::interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void PlocMpsocDummy::fillCommandAndReplyMap() {}
|
||||
|
||||
uint32_t PlocMpsocDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 500; }
|
||||
|
||||
ReturnValue_t PlocMpsocDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
return returnvalue::OK;
|
||||
}
|
@ -1,9 +1,8 @@
|
||||
#ifndef DUMMIES_GPSDUMMY_H_
|
||||
#define DUMMIES_GPSDUMMY_H_
|
||||
#pragma once
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
|
||||
|
||||
class GpsDummy : public DeviceHandlerBase {
|
||||
class PlocMpsocDummy : public DeviceHandlerBase {
|
||||
public:
|
||||
static const DeviceCommandId_t SIMPLE_COMMAND = 1;
|
||||
static const DeviceCommandId_t PERIODIC_REPLY = 2;
|
||||
@ -11,8 +10,8 @@ class GpsDummy : public DeviceHandlerBase {
|
||||
static const uint8_t SIMPLE_COMMAND_DATA = 1;
|
||||
static const uint8_t PERIODIC_REPLY_DATA = 2;
|
||||
|
||||
GpsDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie);
|
||||
virtual ~GpsDummy();
|
||||
PlocMpsocDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie);
|
||||
virtual ~PlocMpsocDummy();
|
||||
|
||||
protected:
|
||||
void doStartUp() override;
|
||||
@ -29,5 +28,3 @@ class GpsDummy : public DeviceHandlerBase {
|
||||
ReturnValue_t initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) override;
|
||||
};
|
||||
|
||||
#endif /* DUMMIES_GPSDUMMY_H_ */
|
44
dummies/PlocSupervisorDummy.cpp
Normal file
44
dummies/PlocSupervisorDummy.cpp
Normal file
@ -0,0 +1,44 @@
|
||||
#include "PlocSupervisorDummy.h"
|
||||
|
||||
PlocSupervisorDummy::PlocSupervisorDummy(object_id_t objectId, object_id_t comif,
|
||||
CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie) {}
|
||||
|
||||
PlocSupervisorDummy::~PlocSupervisorDummy() {}
|
||||
|
||||
void PlocSupervisorDummy::doStartUp() { setMode(MODE_ON); }
|
||||
|
||||
void PlocSupervisorDummy::doShutDown() { setMode(_MODE_POWER_DOWN); }
|
||||
|
||||
ReturnValue_t PlocSupervisorDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t PlocSupervisorDummy::buildTransitionDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t PlocSupervisorDummy::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
|
||||
const uint8_t *commandData,
|
||||
size_t commandDataLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t PlocSupervisorDummy::scanForReply(const uint8_t *start, size_t len,
|
||||
DeviceCommandId_t *foundId, size_t *foundLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t PlocSupervisorDummy::interpretDeviceReply(DeviceCommandId_t id,
|
||||
const uint8_t *packet) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void PlocSupervisorDummy::fillCommandAndReplyMap() {}
|
||||
|
||||
uint32_t PlocSupervisorDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 500; }
|
||||
|
||||
ReturnValue_t PlocSupervisorDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
return returnvalue::OK;
|
||||
}
|
30
dummies/PlocSupervisorDummy.h
Normal file
30
dummies/PlocSupervisorDummy.h
Normal file
@ -0,0 +1,30 @@
|
||||
#pragma once
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
|
||||
|
||||
class PlocSupervisorDummy : public DeviceHandlerBase {
|
||||
public:
|
||||
static const DeviceCommandId_t SIMPLE_COMMAND = 1;
|
||||
static const DeviceCommandId_t PERIODIC_REPLY = 2;
|
||||
|
||||
static const uint8_t SIMPLE_COMMAND_DATA = 1;
|
||||
static const uint8_t PERIODIC_REPLY_DATA = 2;
|
||||
|
||||
PlocSupervisorDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie);
|
||||
virtual ~PlocSupervisorDummy();
|
||||
|
||||
protected:
|
||||
void doStartUp() override;
|
||||
void doShutDown() override;
|
||||
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildTransitionDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildCommandFromCommand(DeviceCommandId_t deviceCommand, const uint8_t *commandData,
|
||||
size_t commandDataLen) override;
|
||||
ReturnValue_t scanForReply(const uint8_t *start, size_t len, DeviceCommandId_t *foundId,
|
||||
size_t *foundLen) override;
|
||||
ReturnValue_t interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) override;
|
||||
void fillCommandAndReplyMap() override;
|
||||
uint32_t getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) override;
|
||||
ReturnValue_t initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) override;
|
||||
};
|
@ -1,6 +1,6 @@
|
||||
#include "RwDummy.h"
|
||||
|
||||
#include <mission/devices/devicedefinitions/RwDefinitions.h>
|
||||
#include <mission/devices/devicedefinitions/rwHelpers.h>
|
||||
|
||||
RwDummy::RwDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie) {}
|
||||
@ -37,39 +37,39 @@ uint32_t RwDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return
|
||||
|
||||
ReturnValue_t RwDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(RwDefinitions::TEMPERATURE_C, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::TEMPERATURE_C, new PoolEntry<int32_t>({0}));
|
||||
|
||||
localDataPoolMap.emplace(RwDefinitions::CURR_SPEED, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::REFERENCE_SPEED, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::STATE, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::CLC_MODE, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(rws::CURR_SPEED, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::REFERENCE_SPEED, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::STATE, new PoolEntry<uint8_t>({1}, true));
|
||||
localDataPoolMap.emplace(rws::CLC_MODE, new PoolEntry<uint8_t>({0}));
|
||||
|
||||
localDataPoolMap.emplace(RwDefinitions::LAST_RESET_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::CURRRENT_RESET_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(rws::LAST_RESET_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(rws::CURRRENT_RESET_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
|
||||
localDataPoolMap.emplace(RwDefinitions::TM_LAST_RESET_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::TM_MCU_TEMPERATURE, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::PRESSURE_SENSOR_TEMPERATURE, new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::PRESSURE, new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::TM_RW_STATE, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::TM_CLC_MODE, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::TM_RW_CURR_SPEED, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::TM_RW_REF_SPEED, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::INVALID_CRC_PACKETS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::INVALID_LEN_PACKETS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::INVALID_CMD_PACKETS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::EXECUTED_REPLIES, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::COMMAND_REPLIES, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::UART_BYTES_WRITTEN, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::UART_BYTES_READ, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::UART_PARITY_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::UART_NOISE_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::UART_FRAME_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::UART_REG_OVERRUN_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::UART_TOTAL_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::SPI_BYTES_WRITTEN, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::SPI_BYTES_READ, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::SPI_REG_OVERRUN_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(RwDefinitions::SPI_TOTAL_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::TM_LAST_RESET_STATUS, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(rws::TM_MCU_TEMPERATURE, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::PRESSURE_SENSOR_TEMPERATURE, new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(rws::PRESSURE, new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(rws::TM_RW_STATE, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(rws::TM_CLC_MODE, new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(rws::TM_RW_CURR_SPEED, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::TM_RW_REF_SPEED, new PoolEntry<int32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::INVALID_CRC_PACKETS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::INVALID_LEN_PACKETS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::INVALID_CMD_PACKETS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::EXECUTED_REPLIES, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::COMMAND_REPLIES, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::UART_BYTES_WRITTEN, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::UART_BYTES_READ, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::UART_PARITY_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::UART_NOISE_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::UART_FRAME_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::UART_REG_OVERRUN_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::UART_TOTAL_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::SPI_BYTES_WRITTEN, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::SPI_BYTES_READ, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::SPI_REG_OVERRUN_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
localDataPoolMap.emplace(rws::SPI_TOTAL_ERRORS, new PoolEntry<uint32_t>({0}));
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
40
dummies/ScexDummy.cpp
Normal file
40
dummies/ScexDummy.cpp
Normal file
@ -0,0 +1,40 @@
|
||||
#include "ScexDummy.h"
|
||||
|
||||
ScexDummy::ScexDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie) {}
|
||||
|
||||
ScexDummy::~ScexDummy() {}
|
||||
|
||||
void ScexDummy::doStartUp() { setMode(MODE_ON); }
|
||||
|
||||
void ScexDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t ScexDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) { return NOTHING_TO_SEND; }
|
||||
|
||||
ReturnValue_t ScexDummy::buildTransitionDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
|
||||
ReturnValue_t ScexDummy::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
|
||||
const uint8_t *commandData,
|
||||
size_t commandDataLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t ScexDummy::scanForReply(const uint8_t *start, size_t len, DeviceCommandId_t *foundId,
|
||||
size_t *foundLen) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t ScexDummy::interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) {
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
void ScexDummy::fillCommandAndReplyMap() {}
|
||||
|
||||
uint32_t ScexDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 500; }
|
||||
|
||||
ReturnValue_t ScexDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
return returnvalue::OK;
|
||||
}
|
30
dummies/ScexDummy.h
Normal file
30
dummies/ScexDummy.h
Normal file
@ -0,0 +1,30 @@
|
||||
#pragma once
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
|
||||
|
||||
class ScexDummy : public DeviceHandlerBase {
|
||||
public:
|
||||
static const DeviceCommandId_t SIMPLE_COMMAND = 1;
|
||||
static const DeviceCommandId_t PERIODIC_REPLY = 2;
|
||||
|
||||
static const uint8_t SIMPLE_COMMAND_DATA = 1;
|
||||
static const uint8_t PERIODIC_REPLY_DATA = 2;
|
||||
|
||||
ScexDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie);
|
||||
virtual ~ScexDummy();
|
||||
|
||||
protected:
|
||||
void doStartUp() override;
|
||||
void doShutDown() override;
|
||||
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildTransitionDeviceCommand(DeviceCommandId_t *id) override;
|
||||
ReturnValue_t buildCommandFromCommand(DeviceCommandId_t deviceCommand, const uint8_t *commandData,
|
||||
size_t commandDataLen) override;
|
||||
ReturnValue_t scanForReply(const uint8_t *start, size_t len, DeviceCommandId_t *foundId,
|
||||
size_t *foundLen) override;
|
||||
ReturnValue_t interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) override;
|
||||
void fillCommandAndReplyMap() override;
|
||||
uint32_t getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) override;
|
||||
ReturnValue_t initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) override;
|
||||
};
|
@ -5,9 +5,9 @@ SusDummy::SusDummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
|
||||
SusDummy::~SusDummy() {}
|
||||
|
||||
void SusDummy::doStartUp() {}
|
||||
void SusDummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
|
||||
void SusDummy::doShutDown() {}
|
||||
void SusDummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t SusDummy::buildNormalDeviceCommand(DeviceCommandId_t *id) { return NOTHING_TO_SEND; }
|
||||
|
||||
@ -35,9 +35,10 @@ uint32_t SusDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return
|
||||
|
||||
ReturnValue_t SusDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(SUS::SusPoolIds::TEMPERATURE_C, new PoolEntry<float>({0}, 1, true));
|
||||
localDataPoolMap.emplace(SUS::SusPoolIds::CHANNEL_VEC,
|
||||
new PoolEntry<uint16_t>({0, 0, 0, 0, 0, 0}, true));
|
||||
localDataPoolMap.emplace(susMax1227::SusPoolIds::TEMPERATURE_C,
|
||||
new PoolEntry<float>({0}, 1, true));
|
||||
localDataPoolMap.emplace(susMax1227::SusPoolIds::CHANNEL_VEC,
|
||||
new PoolEntry<uint16_t>({2603, 781, 2760, 2048, 4056, 0}, true));
|
||||
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
@ -2,8 +2,7 @@
|
||||
#define DUMMIES_SUSDUMMY_H_
|
||||
|
||||
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
|
||||
|
||||
#include "mission/devices/devicedefinitions/SusDefinitions.h"
|
||||
#include <mission/devices/devicedefinitions/susMax1227Helpers.h>
|
||||
|
||||
class SusDummy : public DeviceHandlerBase {
|
||||
public:
|
||||
@ -17,7 +16,7 @@ class SusDummy : public DeviceHandlerBase {
|
||||
virtual ~SusDummy();
|
||||
|
||||
protected:
|
||||
SUS::SusDataset susSet;
|
||||
susMax1227::SusDataset susSet;
|
||||
void doStartUp() override;
|
||||
void doShutDown() override;
|
||||
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t *id) override;
|
||||
|
40
dummies/TemperatureSensorInserter.cpp
Normal file
40
dummies/TemperatureSensorInserter.cpp
Normal file
@ -0,0 +1,40 @@
|
||||
#include "TemperatureSensorInserter.h"
|
||||
|
||||
#include <objects/systemObjectList.h>
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include <utility>
|
||||
|
||||
TemperatureSensorInserter::TemperatureSensorInserter(object_id_t objectId,
|
||||
Max31865DummyMap tempSensorDummies_,
|
||||
Tmp1075DummyMap tempTmpSensorDummies_)
|
||||
: SystemObject(objects::THERMAL_TEMP_INSERTER),
|
||||
max31865DummyMap(std::move(tempSensorDummies_)),
|
||||
tmp1075DummyMap(std::move(tempTmpSensorDummies_)) {}
|
||||
|
||||
ReturnValue_t TemperatureSensorInserter::initialize() {
|
||||
if (performTest) {
|
||||
if (testCase == TestCase::COOL_SYRLINKS) {
|
||||
}
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t TemperatureSensorInserter::performOperation(uint8_t opCode) {
|
||||
/*
|
||||
ReturnValue_t result = max31865PlocHeatspreaderSet.read();
|
||||
if (result != returnvalue::OK) {
|
||||
sif::warning << "Failed to read temperature from MAX31865 dataset" << std::endl;
|
||||
}
|
||||
max31865PlocHeatspreaderSet.rtdValue = value - 5;
|
||||
max31865PlocHeatspreaderSet.temperatureCelcius = value;
|
||||
if ((iteration % 100) < 20) {
|
||||
max31865PlocHeatspreaderSet.setValidity(false, true);
|
||||
} else {
|
||||
max31865PlocHeatspreaderSet.setValidity(true, true);
|
||||
}
|
||||
max31865PlocHeatspreaderSet.commit();
|
||||
*/
|
||||
return returnvalue::OK;
|
||||
}
|
30
dummies/TemperatureSensorInserter.h
Normal file
30
dummies/TemperatureSensorInserter.h
Normal file
@ -0,0 +1,30 @@
|
||||
#pragma once
|
||||
|
||||
#include <fsfw/controller/ExtendedControllerBase.h>
|
||||
#include <mission/devices/devicedefinitions/Max31865Definitions.h>
|
||||
|
||||
#include "Max31865Dummy.h"
|
||||
#include "Tmp1075Dummy.h"
|
||||
|
||||
class TemperatureSensorInserter : public ExecutableObjectIF, public SystemObject {
|
||||
public:
|
||||
using Max31865DummyMap = std::map<object_id_t, Max31865Dummy*>;
|
||||
using Tmp1075DummyMap = std::map<object_id_t, Tmp1075Dummy*>;
|
||||
explicit TemperatureSensorInserter(object_id_t objectId, Max31865DummyMap tempSensorDummies_,
|
||||
Tmp1075DummyMap tempTmpSensorDummies_);
|
||||
|
||||
ReturnValue_t initialize() override;
|
||||
|
||||
protected:
|
||||
ReturnValue_t performOperation(uint8_t opCode) override;
|
||||
|
||||
private:
|
||||
Max31865DummyMap max31865DummyMap;
|
||||
Tmp1075DummyMap tmp1075DummyMap;
|
||||
enum TestCase { NONE = 0, COOL_SYRLINKS = 1 };
|
||||
int iteration = 0;
|
||||
bool performTest = false;
|
||||
TestCase testCase = TestCase::NONE;
|
||||
|
||||
// void noise();
|
||||
};
|
@ -1,102 +0,0 @@
|
||||
#include "TemperatureSensorsDummy.h"
|
||||
|
||||
#include <objects/systemObjectList.h>
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
|
||||
TemperatureSensorsDummy::TemperatureSensorsDummy()
|
||||
: ExtendedControllerBase(objects::RTD_0_IC3_PLOC_HEATSPREADER),
|
||||
max31865Set(this, MAX31865::MAX31865_SET_ID) {
|
||||
ObjectManager::instance()->insert(objects::RTD_1_IC4_PLOC_MISSIONBOARD, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_2_IC5_4K_CAMERA, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_3_IC6_DAC_HEATSPREADER, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_4_IC7_STARTRACKER, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_5_IC8_RW1_MX_MY, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_6_IC9_DRO, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_7_IC10_SCEX, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_8_IC11_X8, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_9_IC12_HPA, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_10_IC13_PL_TX, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_11_IC14_MPA, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_12_IC15_ACU, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_13_IC16_PLPCDU_HEATSPREADER, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_14_IC17_TCS_BOARD, this);
|
||||
ObjectManager::instance()->insert(objects::RTD_15_IC18_IMTQ, this);
|
||||
ObjectManager::instance()->insert(objects::TMP1075_HANDLER_TCS_0, this);
|
||||
ObjectManager::instance()->insert(objects::TMP1075_HANDLER_TCS_1, this);
|
||||
|
||||
ObjectManager::instance()->insert(objects::TMP1075_HANDLER_PLPCDU_0, this);
|
||||
ObjectManager::instance()->insert(objects::TMP1075_HANDLER_PLPCDU_1, this);
|
||||
ObjectManager::instance()->insert(objects::TMP1075_HANDLER_IF_BOARD, this);
|
||||
}
|
||||
|
||||
ReturnValue_t TemperatureSensorsDummy::initialize() {
|
||||
static bool done = false;
|
||||
if (not done) {
|
||||
done = true;
|
||||
ReturnValue_t result = ExtendedControllerBase::initialize();
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t TemperatureSensorsDummy::handleCommandMessage(CommandMessage* message) {
|
||||
return returnvalue::FAILED;
|
||||
}
|
||||
|
||||
void TemperatureSensorsDummy::performControlOperation() {
|
||||
iteration++;
|
||||
value = sin(iteration / 80. * M_PI) * 10;
|
||||
|
||||
ReturnValue_t result = max31865Set.read();
|
||||
if (result != returnvalue::OK) {
|
||||
sif::warning << "Failed to read temperature from MAX31865 dataset" << std::endl;
|
||||
}
|
||||
max31865Set.rtdValue = value - 5;
|
||||
max31865Set.temperatureCelcius = value;
|
||||
if ((iteration % 100) < 20) {
|
||||
max31865Set.setValidity(false, true);
|
||||
} else {
|
||||
max31865Set.setValidity(true, true);
|
||||
}
|
||||
max31865Set.commit();
|
||||
}
|
||||
|
||||
ReturnValue_t TemperatureSensorsDummy::initializeLocalDataPool(
|
||||
localpool::DataPool& localDataPoolMap, LocalDataPoolManager& poolManager) {
|
||||
localDataPoolMap.emplace(static_cast<lp_id_t>(MAX31865::PoolIds::RTD_VALUE),
|
||||
new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(static_cast<lp_id_t>(MAX31865::PoolIds::TEMPERATURE_C),
|
||||
new PoolEntry<float>({0}));
|
||||
localDataPoolMap.emplace(static_cast<lp_id_t>(MAX31865::PoolIds::LAST_FAULT_BYTE),
|
||||
new PoolEntry<uint8_t>({0}));
|
||||
localDataPoolMap.emplace(static_cast<lp_id_t>(MAX31865::PoolIds::FAULT_BYTE),
|
||||
new PoolEntry<uint8_t>({0}));
|
||||
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
LocalPoolDataSetBase* TemperatureSensorsDummy::getDataSetHandle(sid_t sid) {
|
||||
sif::debug << "getHandle" << std::endl;
|
||||
switch (sid.ownerSetId) {
|
||||
case MAX31865::MAX31865_SET_ID:
|
||||
return &max31865Set;
|
||||
default:
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
ReturnValue_t TemperatureSensorsDummy::checkModeCommand(Mode_t mode, Submode_t submode,
|
||||
uint32_t* msToReachTheMode) {
|
||||
if (submode != SUBMODE_NONE) {
|
||||
return INVALID_SUBMODE;
|
||||
}
|
||||
if ((mode != MODE_OFF) && (mode != MODE_ON) && (mode != MODE_NORMAL)) {
|
||||
return INVALID_MODE;
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
@ -1,29 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
#include <fsfw/controller/ExtendedControllerBase.h>
|
||||
#include <mission/devices/devicedefinitions/Max31865Definitions.h>
|
||||
|
||||
class TemperatureSensorsDummy : public ExtendedControllerBase {
|
||||
public:
|
||||
TemperatureSensorsDummy();
|
||||
|
||||
ReturnValue_t initialize() override;
|
||||
|
||||
protected:
|
||||
virtual ReturnValue_t handleCommandMessage(CommandMessage* message) override;
|
||||
virtual void performControlOperation() override;
|
||||
virtual ReturnValue_t initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
|
||||
LocalDataPoolManager& poolManager) override;
|
||||
virtual LocalPoolDataSetBase* getDataSetHandle(sid_t sid) override;
|
||||
|
||||
// Mode abstract functions
|
||||
virtual ReturnValue_t checkModeCommand(Mode_t mode, Submode_t submode,
|
||||
uint32_t* msToReachTheMode) override;
|
||||
|
||||
private:
|
||||
int iteration = 0;
|
||||
float value = 0;
|
||||
MAX31865::Max31865Set max31865Set;
|
||||
|
||||
void noise();
|
||||
};
|
36
dummies/Tmp1075Dummy.cpp
Normal file
36
dummies/Tmp1075Dummy.cpp
Normal file
@ -0,0 +1,36 @@
|
||||
#include "Tmp1075Dummy.h"
|
||||
|
||||
#include "mission/devices/devicedefinitions/Tmp1075Definitions.h"
|
||||
|
||||
using namespace returnvalue;
|
||||
|
||||
Tmp1075Dummy::Tmp1075Dummy(object_id_t objectId, object_id_t comif, CookieIF *comCookie)
|
||||
: DeviceHandlerBase(objectId, comif, comCookie), set(this) {}
|
||||
|
||||
void Tmp1075Dummy::doStartUp() { setMode(MODE_NORMAL); }
|
||||
void Tmp1075Dummy::doShutDown() { setMode(MODE_OFF); }
|
||||
|
||||
ReturnValue_t Tmp1075Dummy::buildNormalDeviceCommand(DeviceCommandId_t *id) {
|
||||
return NOTHING_TO_SEND;
|
||||
}
|
||||
ReturnValue_t Tmp1075Dummy::buildTransitionDeviceCommand(DeviceCommandId_t *id) { return OK; }
|
||||
ReturnValue_t Tmp1075Dummy::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
|
||||
const uint8_t *commandData,
|
||||
size_t commandDataLen) {
|
||||
return 0;
|
||||
}
|
||||
ReturnValue_t Tmp1075Dummy::scanForReply(const uint8_t *start, size_t len,
|
||||
DeviceCommandId_t *foundId, size_t *foundLen) {
|
||||
return 0;
|
||||
}
|
||||
ReturnValue_t Tmp1075Dummy::interpretDeviceReply(DeviceCommandId_t id, const uint8_t *packet) {
|
||||
return 0;
|
||||
}
|
||||
void Tmp1075Dummy::fillCommandAndReplyMap() {}
|
||||
uint32_t Tmp1075Dummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 1000; }
|
||||
ReturnValue_t Tmp1075Dummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
|
||||
LocalDataPoolManager &poolManager) {
|
||||
localDataPoolMap.emplace(TMP1075::TEMPERATURE_C_TMP1075, new PoolEntry<float>({0.0}));
|
||||
return OK;
|
||||
}
|
||||
LocalPoolDataSetBase *Tmp1075Dummy::getDataSetHandle(sid_t sid) { return &set; }
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user