pub struct FmRadioChannel {
pub number: u8,
pub frequency_hz: u32,
pub name: String,
}Expand description
An FM broadcast radio memory channel (FM0-FM9).
The TH-D75 provides 10 memory channels for storing FM broadcast station frequencies. These are separate from the 1000 regular memory channels.
Fields§
§number: u8Channel number (0-9, displayed as FM0-FM9).
frequency_hz: u32Station frequency in Hz (76,000,000 - 108,000,000). The radio tunes in 50/100 kHz steps in the FM broadcast band.
name: StringStation name (up to 8 characters).
Implementations§
Source§impl FmRadioChannel
impl FmRadioChannel
Sourcepub fn new(number: u8, frequency_hz: u32, name: String) -> Option<Self>
pub fn new(number: u8, frequency_hz: u32, name: String) -> Option<Self>
Create a new FM radio channel.
Returns None if the channel number or frequency is out of range,
or if the name exceeds 8 characters.
Sourcepub fn frequency_mhz(&self) -> f64
pub fn frequency_mhz(&self) -> f64
Returns the frequency in MHz as a floating-point value.
Trait Implementations§
Source§impl Clone for FmRadioChannel
impl Clone for FmRadioChannel
Source§fn clone(&self) -> FmRadioChannel
fn clone(&self) -> FmRadioChannel
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FmRadioChannel
impl Debug for FmRadioChannel
Source§impl Display for FmRadioChannel
impl Display for FmRadioChannel
Source§impl PartialEq for FmRadioChannel
impl PartialEq for FmRadioChannel
impl Eq for FmRadioChannel
impl StructuralPartialEq for FmRadioChannel
Auto Trait Implementations§
impl Freeze for FmRadioChannel
impl RefUnwindSafe for FmRadioChannel
impl Send for FmRadioChannel
impl Sync for FmRadioChannel
impl Unpin for FmRadioChannel
impl UnwindSafe for FmRadioChannel
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more