updated satrs
This commit is contained in:
parent
875ac6280a
commit
62784b32cc
@ -2,7 +2,6 @@ mod can;
|
|||||||
mod can_ids;
|
mod can_ids;
|
||||||
mod ccsds;
|
mod ccsds;
|
||||||
mod device_handler;
|
mod device_handler;
|
||||||
mod example_main;
|
|
||||||
mod hk;
|
mod hk;
|
||||||
mod logger;
|
mod logger;
|
||||||
mod pus;
|
mod pus;
|
||||||
@ -339,7 +338,7 @@ fn main() {
|
|||||||
|
|
||||||
// send start verification and get token
|
// send start verification and get token
|
||||||
let start_token = reporter_pld
|
let start_token = reporter_pld
|
||||||
.start_success(request_with_token.1, &time_stamp_buf)
|
.start_success(request_with_token.1, Some(&time_stamp_buf))
|
||||||
.expect("Error sending start success.");
|
.expect("Error sending start success.");
|
||||||
|
|
||||||
// make can bus package to camera
|
// make can bus package to camera
|
||||||
@ -387,7 +386,7 @@ fn main() {
|
|||||||
|
|
||||||
// send end verification with token
|
// send end verification with token
|
||||||
reporter_pld
|
reporter_pld
|
||||||
.completion_success(start_token, &time_stamp_buf)
|
.completion_success(start_token, Some(&time_stamp_buf))
|
||||||
.expect("Error sending start success.");
|
.expect("Error sending start success.");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
22
src/pus.rs
22
src/pus.rs
@ -75,7 +75,7 @@ impl PusServiceProvider for PusReceiver {
|
|||||||
self.update_time_stamp();
|
self.update_time_stamp();
|
||||||
let accepted_token = self
|
let accepted_token = self
|
||||||
.verif_reporter
|
.verif_reporter
|
||||||
.acceptance_success(init_token, &self.time_stamp)
|
.acceptance_success(init_token, Some(&self.time_stamp))
|
||||||
.expect("Acceptance success failure");
|
.expect("Acceptance success failure");
|
||||||
if service == 17 {
|
if service == 17 {
|
||||||
self.handle_test_service(pus_tc, accepted_token);
|
self.handle_test_service(pus_tc, accepted_token);
|
||||||
@ -90,7 +90,7 @@ impl PusServiceProvider for PusReceiver {
|
|||||||
self.verif_reporter
|
self.verif_reporter
|
||||||
.start_failure(
|
.start_failure(
|
||||||
accepted_token,
|
accepted_token,
|
||||||
FailParams::new(&self.time_stamp, &tmtc_err::INVALID_PUS_SERVICE, None),
|
FailParams::new(Some(&self.time_stamp), &tmtc_err::INVALID_PUS_SERVICE, None),
|
||||||
)
|
)
|
||||||
.expect("Start failure verification failed")
|
.expect("Start failure verification failed")
|
||||||
}
|
}
|
||||||
@ -107,20 +107,20 @@ impl PusReceiver {
|
|||||||
let addr = self.tm_store.add_pus_tm(&ping_reply);
|
let addr = self.tm_store.add_pus_tm(&ping_reply);
|
||||||
let start_token = self
|
let start_token = self
|
||||||
.verif_reporter
|
.verif_reporter
|
||||||
.start_success(token, &self.time_stamp)
|
.start_success(token, Some(&self.time_stamp))
|
||||||
.expect("Error sending start success");
|
.expect("Error sending start success");
|
||||||
self.tm_tx
|
self.tm_tx
|
||||||
.send(addr)
|
.send(addr)
|
||||||
.expect("Sending TM to TM funnel failed");
|
.expect("Sending TM to TM funnel failed");
|
||||||
self.verif_reporter
|
self.verif_reporter
|
||||||
.completion_success(start_token, &self.time_stamp)
|
.completion_success(start_token, Some(&self.time_stamp))
|
||||||
.expect("Error sending completion success");
|
.expect("Error sending completion success");
|
||||||
} else {
|
} else {
|
||||||
self.update_time_stamp();
|
self.update_time_stamp();
|
||||||
self.verif_reporter
|
self.verif_reporter
|
||||||
.start_failure(
|
.start_failure(
|
||||||
token,
|
token,
|
||||||
FailParams::new(&self.time_stamp, &tmtc_err::INVALID_PUS_SUBSERVICE, None),
|
FailParams::new(Some(&self.time_stamp), &tmtc_err::INVALID_PUS_SUBSERVICE, None),
|
||||||
)
|
)
|
||||||
.expect("Sending start failure TM failed");
|
.expect("Sending start failure TM failed");
|
||||||
}
|
}
|
||||||
@ -141,7 +141,7 @@ impl PusReceiver {
|
|||||||
self.verif_reporter
|
self.verif_reporter
|
||||||
.start_failure(
|
.start_failure(
|
||||||
token,
|
token,
|
||||||
FailParams::new(&self.time_stamp, &tmtc_err::NOT_ENOUGH_APP_DATA, None),
|
FailParams::new(Some(&self.time_stamp), &tmtc_err::NOT_ENOUGH_APP_DATA, None),
|
||||||
)
|
)
|
||||||
.expect("Sending start failure TM failed");
|
.expect("Sending start failure TM failed");
|
||||||
return;
|
return;
|
||||||
@ -155,7 +155,7 @@ impl PusReceiver {
|
|||||||
};
|
};
|
||||||
self.update_time_stamp();
|
self.update_time_stamp();
|
||||||
self.verif_reporter
|
self.verif_reporter
|
||||||
.start_failure(token, FailParams::new(&self.time_stamp, err, None))
|
.start_failure(token, FailParams::new(Some(&self.time_stamp), err, None))
|
||||||
.expect("Sending start failure TM failed");
|
.expect("Sending start failure TM failed");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -165,7 +165,7 @@ impl PusReceiver {
|
|||||||
self.verif_reporter
|
self.verif_reporter
|
||||||
.start_failure(
|
.start_failure(
|
||||||
token,
|
token,
|
||||||
FailParams::new(&self.time_stamp, &hk_err::UNKNOWN_TARGET_ID, None),
|
FailParams::new(Some(&self.time_stamp), &hk_err::UNKNOWN_TARGET_ID, None),
|
||||||
)
|
)
|
||||||
.expect("Sending start failure TM failed");
|
.expect("Sending start failure TM failed");
|
||||||
return;
|
return;
|
||||||
@ -190,7 +190,7 @@ impl PusReceiver {
|
|||||||
.start_failure(
|
.start_failure(
|
||||||
token,
|
token,
|
||||||
FailParams::new(
|
FailParams::new(
|
||||||
&self.time_stamp,
|
Some(&self.time_stamp),
|
||||||
&hk_err::COLLECTION_INTERVAL_MISSING,
|
&hk_err::COLLECTION_INTERVAL_MISSING,
|
||||||
None,
|
None,
|
||||||
),
|
),
|
||||||
@ -212,14 +212,14 @@ impl PusReceiver {
|
|||||||
verif_reporter
|
verif_reporter
|
||||||
.start_failure(
|
.start_failure(
|
||||||
token,
|
token,
|
||||||
FailParams::new(timestamp, failure_code, failure_data),
|
FailParams::new(Some(timestamp), failure_code, failure_data),
|
||||||
)
|
)
|
||||||
.expect("Sending start failure TM failed");
|
.expect("Sending start failure TM failed");
|
||||||
};
|
};
|
||||||
let send_start_acceptance = |verif_reporter: &mut StdVerifReporterWithSender,
|
let send_start_acceptance = |verif_reporter: &mut StdVerifReporterWithSender,
|
||||||
timestamp: &[u8; 7]| {
|
timestamp: &[u8; 7]| {
|
||||||
verif_reporter
|
verif_reporter
|
||||||
.start_success(token, timestamp)
|
.start_success(token, Some(timestamp))
|
||||||
.expect("Sending start success TM failed")
|
.expect("Sending start success TM failed")
|
||||||
};
|
};
|
||||||
if pus_tc.user_data().is_none() {
|
if pus_tc.user_data().is_none() {
|
||||||
|
Loading…
Reference in New Issue
Block a user