(&mut self)
| 868 | } |
| 869 | |
| 870 | async fn set_device_mode(&mut self) -> Result<()> { |
| 871 | let dp = self.device_profile.as_ref().unwrap(); |
| 872 | let d = self.device.as_mut().unwrap(); |
| 873 | |
| 874 | // LoRaWAN 1.1 devices send a mac-command when changing to Class-C. |
| 875 | if dp.supports_class_c && dp.mac_version.to_string().starts_with("1.0") { |
| 876 | d.enabled_class = DeviceClass::C; |
| 877 | } else { |
| 878 | d.enabled_class = DeviceClass::A; |
| 879 | } |
| 880 | |
| 881 | Ok(()) |
| 882 | } |
| 883 | |
| 884 | async fn update_device(&mut self) -> Result<()> { |
| 885 | trace!("Updating device"); |
no test coverage detected