Skip to content

Commit 6f33a24

Browse files
committed
framework_lib: Format PD version as hex
BIOS setup menu displays it as hex and we usually refer to it as such. Signed-off-by: Daniel Schaefer <[email protected]>
1 parent b7bf240 commit 6f33a24

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

framework_lib/src/ccgx/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ impl fmt::Display for BaseVersion {
121121
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
122122
write!(
123123
f,
124-
"{}.{}.{}.{:0>3}",
124+
"{:X}.{:X}.{:X}.{:03X}",
125125
self.major, self.minor, self.patch, self.build_number
126126
)
127127
}
@@ -163,7 +163,7 @@ pub struct AppVersion {
163163

164164
impl fmt::Display for AppVersion {
165165
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
166-
write!(f, "{}.{}.{:0>2}", self.major, self.minor, self.circuit)
166+
write!(f, "{:X}.{:X}.{:02X}", self.major, self.minor, self.circuit)
167167
}
168168
}
169169

0 commit comments

Comments
 (0)