sdmmc_core/command/class/
class4.rs

1use crate::result::Error;
2use crate::{command_enum, lib_enum};
3
4pub mod cmd16;
5pub mod cmd20;
6pub mod cmd22;
7pub mod cmd23;
8pub mod cmd24;
9pub mod cmd25;
10pub mod cmd26;
11pub mod cmd27;
12
13lib_enum! {
14    /// MMC opcodes for Class 4.
15    CommandClass4: u32 {
16        default: SetBlockCount,
17        error: Error,
18        SetBlocklen = 16,
19        SpeedClassControl = 20,
20        AddressExtension = 22,
21        SetBlockCount = 23,
22        WriteBlock = 24,
23        WriteMultipleBlock = 25,
24        ProgramCID = 26,
25        ProgramCSD = 27,
26    }
27}
28
29command_enum! {
30    /// Represents the variants for Class4 commands.
31    Command {
32        default: Cmd16(cmd16::Cmd16),
33        Cmd16(cmd16::Cmd16),
34        Cmd20(cmd20::Cmd20),
35        Cmd22(cmd22::Cmd22),
36        Cmd23(cmd23::Cmd23),
37        Cmd24(cmd24::Cmd24),
38        Cmd25(cmd25::Cmd25),
39        Cmd26(cmd26::Cmd26),
40        Cmd27(cmd27::Cmd27),
41    }
42}