net: improve error message on unsupported medium.
This commit is contained in:
parent
6d3377e6a6
commit
b5748524f8
@ -9,6 +9,7 @@ categories = [
|
||||
"embedded",
|
||||
"no-std",
|
||||
"asynchronous",
|
||||
"network-programming",
|
||||
]
|
||||
|
||||
[package.metadata.embassy_docs]
|
||||
|
@ -249,7 +249,10 @@ fn to_smoltcp_hardware_address(addr: driver::HardwareAddress) -> HardwareAddress
|
||||
driver::HardwareAddress::Ip => HardwareAddress::Ip,
|
||||
|
||||
#[allow(unreachable_patterns)]
|
||||
_ => panic!("Unsupported address {:?}. Make sure to enable medium-ethernet or medium-ieee802154 in embassy-net's Cargo features.", addr),
|
||||
_ => panic!(
|
||||
"Unsupported medium {:?}. Make sure to enable the right medium feature in embassy-net's Cargo features.",
|
||||
addr
|
||||
),
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user