From afa75315276bf3835fdc6d93690d58e88f2a7ba4 Mon Sep 17 00:00:00 2001 From: "Guillaume W. Bres" Date: Sat, 29 Jul 2023 12:32:05 +0200 Subject: [PATCH 1/5] rinex crate: update to georust infrastructure This library and associated toolkits were integrated into the georust community. Update all URL and crates io interfacing Signed-off-by: Guillaume W. Bres --- crx2rnx/Cargo.toml | 4 ++-- rinex-cli/Cargo.toml | 5 +++-- rinex/Cargo.toml | 5 +++-- rnx2crx/Cargo.toml | 5 +++-- sinex/Cargo.toml | 6 +++--- ublox-rnx/Cargo.toml | 5 +++-- 6 files changed, 17 insertions(+), 13 deletions(-) diff --git a/crx2rnx/Cargo.toml b/crx2rnx/Cargo.toml index cff2d1c6f..9b253c598 100644 --- a/crx2rnx/Cargo.toml +++ b/crx2rnx/Cargo.toml @@ -1,10 +1,10 @@ [package] name = "crx2rnx" -version = "2.0.0" +version = "2.1.0" license = "MIT OR Apache-2.0" authors = ["Guillaume W. Bres "] description = "RINEX data decompressor" -homepage = "https://github.com/gwbres/rinex" +homepage = "https://github.com/georust/rinex" keywords = ["rinex", "compression", "decompression", "crinex"] categories = ["science", "command-line-interface", "command-line-utilities"] edition = "2021" diff --git a/rinex-cli/Cargo.toml b/rinex-cli/Cargo.toml index d15a13c54..5ab1926ca 100644 --- a/rinex-cli/Cargo.toml +++ b/rinex-cli/Cargo.toml @@ -1,10 +1,11 @@ [package] name = "rinex-cli" -version = "0.6.0" +version = "0.8.0" license = "MIT OR Apache-2.0" authors = ["Guillaume W. Bres "] description = "Command line tool parse and analyze RINEX data" -homepage = "https://github.com/gwbres/rinex" +homepage = "https://github.com/georust/rinex" +repository = "https://github.com/georust/rinex" keywords = ["rinex", "gps", "glonass", "galileo", "timing"] categories = ["science", "command-line-interface", "command-line-utilities"] edition = "2021" diff --git a/rinex/Cargo.toml b/rinex/Cargo.toml index 646d46a89..8e6a8fc46 100644 --- a/rinex/Cargo.toml +++ b/rinex/Cargo.toml @@ -1,10 +1,11 @@ [package] name = "rinex" -version = "0.9.0" +version = "0.10.0" license = "MIT OR Apache-2.0" authors = ["Guillaume W. Bres "] description = "Package to parse and analyze RINEX data" -homepage = "https://github.com/gwbres/rinex" +homepage = "https://github.com/georust/rinex" +repository = "https://github.com/georust/rinex" keywords = ["rinex", "timing", "gps", "glonass", "galileo"] categories = ["science", "parsing"] edition = "2021" diff --git a/rnx2crx/Cargo.toml b/rnx2crx/Cargo.toml index 73c86766e..5749f4f54 100644 --- a/rnx2crx/Cargo.toml +++ b/rnx2crx/Cargo.toml @@ -1,10 +1,11 @@ [package] name = "rnx2crx" -version = "1.0.0" +version = "1.1.0" license = "MIT OR Apache-2.0" authors = ["Guillaume W. Bres "] description = "RINEX data compressor" -homepage = "https://github.com/gwbres/rinex" +homepage = "https://github.com/georust/rinex" +repository = "https://github.com/georust/rinex" keywords = ["rinex", "compression", "crinex"] categories = ["science", "command-line-interface", "command-line-utilities"] edition = "2021" diff --git a/sinex/Cargo.toml b/sinex/Cargo.toml index a71adfa21..d449ab4af 100644 --- a/sinex/Cargo.toml +++ b/sinex/Cargo.toml @@ -1,11 +1,11 @@ [package] name = "sinex" -version = "0.1.1" +version = "0.2.0" license = "MIT OR Apache-2.0" authors = ["Guillaume W. Bres "] description = "Package to parse and analyze SINEX data" -homepage = "https://github.com/gwbres/rinex/sinex" -repository = "https://github.com/gwbres/rinex/sinex" +homepage = "https://github.com/georust/rinex/sinex" +repository = "https://github.com/georust/rinex/sinex" keywords = ["sinex", "timing", "gps", "glonass", "galileo"] categories = ["science", "parsing"] edition = "2021" diff --git a/ublox-rnx/Cargo.toml b/ublox-rnx/Cargo.toml index 24f3e40ab..1f36d121d 100644 --- a/ublox-rnx/Cargo.toml +++ b/ublox-rnx/Cargo.toml @@ -1,10 +1,11 @@ [package] name = "ublox-rnx" -version = "0.0.2" +version = "0.1.0" license = "MIT OR Apache-2.0" authors = ["Guillaume W. Bres "] description = "Efficient RINEX production from a Ublox GNSS receiver" -homepage = "https://github.com/gwbres/rinex" +homepage = "https://github.com/georust/rinex" +repository = "https://github.com/georust/rinex" keywords = ["rinex", "gps", "glonass", "galileo", "timing"] categories = ["science", "command-line-interface", "command-line-utilities"] edition = "2021" From dfa37d9e71c3458cec1496151ce6fbc577a014b3 Mon Sep 17 00:00:00 2001 From: "Guillaume W. Bres" Date: Sat, 29 Jul 2023 12:51:33 +0200 Subject: [PATCH 2/5] crinex header formatting needs to be improved regarding this crate revision evolution Signed-off-by: Guillaume W. Bres --- rinex/Cargo.toml | 2 +- rinex/src/observation/mod.rs | 22 +++++++++++----------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/rinex/Cargo.toml b/rinex/Cargo.toml index 8e6a8fc46..adee8a047 100644 --- a/rinex/Cargo.toml +++ b/rinex/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rinex" -version = "0.10.0" +version = "0.10.1" license = "MIT OR Apache-2.0" authors = ["Guillaume W. Bres "] description = "Package to parse and analyze RINEX data" diff --git a/rinex/src/observation/mod.rs b/rinex/src/observation/mod.rs index c296e2624..e5ce5c321 100644 --- a/rinex/src/observation/mod.rs +++ b/rinex/src/observation/mod.rs @@ -187,16 +187,16 @@ mod crinex { let crinex = Crinex::default(); let now = Epoch::now().unwrap(); let (y, m, d, hh, mm, _, _) = now.to_gregorian_utc(); - let expected = format!( - "3.0 COMPACT RINEX FORMAT CRINEX VERS / TYPE -rust-rinex-{} {:02}-{}-{} {:02}:{:02} CRINEX PROG / DATE", - env!("CARGO_PKG_VERSION"), - d, - fmt_month!(m), - y - 2000, - hh, - mm - ); - assert_eq!(crinex.to_string(), expected); + let content = crinex.to_string(); + let lines: Vec<&str> = content.lines().collect(); + assert_eq!(lines.len(), 2); // main title should span 2 lines + + // test first line + let expected = + "3.0 COMPACT RINEX FORMAT CRINEX VERS / TYPE"; + assert_eq!(expected, lines[0]); + + // test second line width : must follow RINEX standards + //assert_eq!(lines[1].len(), 80); } } From e8bb9846f5736be11a8eecd81c975f76929848fe Mon Sep 17 00:00:00 2001 From: "Guillaume W. Bres" Date: Sat, 29 Jul 2023 13:06:13 +0200 Subject: [PATCH 3/5] ublox crate maintenance issue Signed-off-by: Guillaume W. Bres --- ublox-rnx/src/main.rs | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/ublox-rnx/src/main.rs b/ublox-rnx/src/main.rs index 70e5ef6c9..ee9238214 100644 --- a/ublox-rnx/src/main.rs +++ b/ublox-rnx/src/main.rs @@ -34,6 +34,7 @@ pub fn main() -> Result<(), Box> { .expect(&format!("failed to open serial port \"{}\"", port)); let mut device = device::Device::new(port); + /* needs ublox crate update !! // Enable UBX protocol on all ports // so User can connect to all of them device.write_all( @@ -51,7 +52,9 @@ pub fn main() -> Result<(), Box> { .into_packet_bytes(), )?; device.wait_for_ack::().unwrap(); + */ + /* NEED UBX CRATE UPDATE!! device.write_all( &CfgPrtUartBuilder { portid: UartPortId::Uart2, @@ -67,7 +70,9 @@ pub fn main() -> Result<(), Box> { .into_packet_bytes(), )?; device.wait_for_ack::().unwrap(); + */ + /* NEED UBX CRATE UPDATE!! device.write_all( &CfgPrtUartBuilder { portid: UartPortId::Usb, @@ -83,6 +88,7 @@ pub fn main() -> Result<(), Box> { .into_packet_bytes(), )?; device.wait_for_ack::().unwrap(); + */ /////////////////////// // Observation opmode @@ -98,6 +104,8 @@ pub fn main() -> Result<(), Box> { // Navigation opmode /////////////////////// // Enable GPS Ephemeris + GPS Iono + + /* NEED UBX Crate update!! device .write_all( &CfgMsgAllPortsBuilder::set_rate_for::([0, 1, 0, 0, 0, 0]) @@ -112,6 +120,7 @@ pub fn main() -> Result<(), Box> { ) .unwrap(); device.wait_for_ack::().unwrap(); + */ // Create header section let _header = header::Header::basic_obs(); @@ -140,11 +149,13 @@ pub fn main() -> Result<(), Box> { //flags.ephemeris_available(); } }, + /* NEED UBX CRATE UPDATE !! PacketRef::NavEoe(pkt) => { // End of epoch notification let _itow = pkt.itow(); // ==> push into file }, + */ _ => {}, } }); From c91594e95c11a8eb60647ed10525cdd507672e5c Mon Sep 17 00:00:00 2001 From: "Guillaume W. Bres" Date: Sat, 29 Jul 2023 13:06:29 +0200 Subject: [PATCH 4/5] update to georust Signed-off-by: Guillaume W. Bres --- ublox-rnx/Cargo.toml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/ublox-rnx/Cargo.toml b/ublox-rnx/Cargo.toml index 1f36d121d..448b92d16 100644 --- a/ublox-rnx/Cargo.toml +++ b/ublox-rnx/Cargo.toml @@ -16,7 +16,6 @@ chrono = "0.4" serde = "1.0" serde_json = "1.0" serialport = "4.2.0" -#ublox = "0.4.2" -ublox = { git = "https://github.com/gwbres/ublox", branch = "gwbr/develop" } -rinex = { path = "../rinex", features = ["serde"] } +ublox = "0.4.2" +rinex = { version = "0.10.1", features = ["serde"] } clap = { version = "3.2.22", features = ["yaml"] } From c5d86e1088a9b9c390b37314c5387b62e44ff5ad Mon Sep 17 00:00:00 2001 From: "Guillaume W. Bres" Date: Sat, 29 Jul 2023 13:38:39 +0200 Subject: [PATCH 5/5] add new science::geo lib category Signed-off-by: Guillaume W. Bres --- crx2rnx/Cargo.toml | 2 +- rinex-cli/Cargo.toml | 2 +- rinex/Cargo.toml | 2 +- rnx2crx/Cargo.toml | 2 +- sinex/Cargo.toml | 2 +- ublox-rnx/Cargo.toml | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/crx2rnx/Cargo.toml b/crx2rnx/Cargo.toml index 9b253c598..ea4d73415 100644 --- a/crx2rnx/Cargo.toml +++ b/crx2rnx/Cargo.toml @@ -6,7 +6,7 @@ authors = ["Guillaume W. Bres "] description = "RINEX data decompressor" homepage = "https://github.com/georust/rinex" keywords = ["rinex", "compression", "decompression", "crinex"] -categories = ["science", "command-line-interface", "command-line-utilities"] +categories = ["science", "science::geo", "command-line-interface", "command-line-utilities"] edition = "2021" readme = "README.md" diff --git a/rinex-cli/Cargo.toml b/rinex-cli/Cargo.toml index 5ab1926ca..e7958eda2 100644 --- a/rinex-cli/Cargo.toml +++ b/rinex-cli/Cargo.toml @@ -7,7 +7,7 @@ description = "Command line tool parse and analyze RINEX data" homepage = "https://github.com/georust/rinex" repository = "https://github.com/georust/rinex" keywords = ["rinex", "gps", "glonass", "galileo", "timing"] -categories = ["science", "command-line-interface", "command-line-utilities"] +categories = ["science", "science::geo", "command-line-interface", "command-line-utilities"] edition = "2021" readme = "README.md" diff --git a/rinex/Cargo.toml b/rinex/Cargo.toml index adee8a047..26adb9d2f 100644 --- a/rinex/Cargo.toml +++ b/rinex/Cargo.toml @@ -7,7 +7,7 @@ description = "Package to parse and analyze RINEX data" homepage = "https://github.com/georust/rinex" repository = "https://github.com/georust/rinex" keywords = ["rinex", "timing", "gps", "glonass", "galileo"] -categories = ["science", "parsing"] +categories = ["science", "science::geo", "parsing"] edition = "2021" readme = "README.md" rust-version = "1.61" diff --git a/rnx2crx/Cargo.toml b/rnx2crx/Cargo.toml index 5749f4f54..fc8f6ab18 100644 --- a/rnx2crx/Cargo.toml +++ b/rnx2crx/Cargo.toml @@ -7,7 +7,7 @@ description = "RINEX data compressor" homepage = "https://github.com/georust/rinex" repository = "https://github.com/georust/rinex" keywords = ["rinex", "compression", "crinex"] -categories = ["science", "command-line-interface", "command-line-utilities"] +categories = ["science", "science::geo", "command-line-interface", "command-line-utilities"] edition = "2021" readme = "README.md" diff --git a/sinex/Cargo.toml b/sinex/Cargo.toml index d449ab4af..2535c0114 100644 --- a/sinex/Cargo.toml +++ b/sinex/Cargo.toml @@ -7,7 +7,7 @@ description = "Package to parse and analyze SINEX data" homepage = "https://github.com/georust/rinex/sinex" repository = "https://github.com/georust/rinex/sinex" keywords = ["sinex", "timing", "gps", "glonass", "galileo"] -categories = ["science", "parsing"] +categories = ["science", "science::geo", "parsing"] edition = "2021" readme = "README.md" diff --git a/ublox-rnx/Cargo.toml b/ublox-rnx/Cargo.toml index 448b92d16..8cf6f6377 100644 --- a/ublox-rnx/Cargo.toml +++ b/ublox-rnx/Cargo.toml @@ -7,7 +7,7 @@ description = "Efficient RINEX production from a Ublox GNSS receiver" homepage = "https://github.com/georust/rinex" repository = "https://github.com/georust/rinex" keywords = ["rinex", "gps", "glonass", "galileo", "timing"] -categories = ["science", "command-line-interface", "command-line-utilities"] +categories = ["science", "science::geo", "command-line-interface", "command-line-utilities"] edition = "2021" readme = "README.md"