MCPcopy Create free account
hub / github.com/chirpstack/chirpstack / class_c_update_scheduler_run_after

Method class_c_update_scheduler_run_after

chirpstack/src/downlink/data.rs:2465–2481  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

2463 }
2464
2465 async fn class_c_update_scheduler_run_after(&mut self) -> Result<()> {
2466 trace!("Updating scheduler_run_after_ts for Class-C");
2467
2468 let conf = config::get();
2469 let scheduler_run_after_ts = Utc::now() + conf.network.scheduler.class_c_lock_duration;
2470
2471 self.device = device::partial_update(
2472 self.device.dev_eui,
2473 &device::DeviceChangeset {
2474 scheduler_run_after: Some(Some(scheduler_run_after_ts)),
2475 ..Default::default()
2476 },
2477 )
2478 .await?;
2479
2480 Ok(())
2481 }
2482
2483 // The setting of tx_info and updating update_scheduler_run_after_ts is combined
2484 // as we need to calculate the ping_slot_ts for the tx_info.

Callers 1

Calls 2

getFunction · 0.50
partial_updateFunction · 0.50

Tested by

no test coverage detected