Prusa MINI Firmware overview
CDB6 Struct Reference

#include <masstorage.h>

Collaboration diagram for CDB6:

Public Member Functions

 CDB6 (uint8_t _Opcode, uint8_t _LUN, uint32_t LBA, uint8_t _AllocationLength, uint8_t _Control)
 
 CDB6 (uint8_t _Opcode, uint8_t _LUN, uint8_t _AllocationLength, uint8_t _Control)
 

Public Attributes

uint8_t Opcode
 
unsigned LBAMSB: 5
 
unsigned LUN: 3
 
uint8_t LBAHB
 
uint8_t LBALB
 
uint8_t AllocationLength
 
uint8_t Control
 

Constructor & Destructor Documentation

◆ CDB6() [1/2]

CDB6::CDB6 ( uint8_t  _Opcode,
uint8_t  _LUN,
uint32_t  LBA,
uint8_t  _AllocationLength,
uint8_t  _Control 
)
216  :
217  Opcode(_Opcode), LBAMSB(BGRAB2(LBA) & 0x1f), LUN(_LUN), LBAHB(BGRAB1(LBA)), LBALB(BGRAB0(LBA)),
218  AllocationLength(_AllocationLength), Control(_Control) {
219  }

◆ CDB6() [2/2]

CDB6::CDB6 ( uint8_t  _Opcode,
uint8_t  _LUN,
uint8_t  _AllocationLength,
uint8_t  _Control 
)
221  :
222  Opcode(_Opcode), LBAMSB(0), LUN(_LUN), LBAHB(0), LBALB(0),
223  AllocationLength(_AllocationLength), Control(_Control) {
224  }

Member Data Documentation

◆ Opcode

uint8_t CDB6::Opcode

◆ LBAMSB

unsigned CDB6::LBAMSB

◆ LUN

unsigned CDB6::LUN

◆ LBAHB

uint8_t CDB6::LBAHB

◆ LBALB

uint8_t CDB6::LBALB

◆ AllocationLength

uint8_t CDB6::AllocationLength

◆ Control

uint8_t CDB6::Control
BGRAB0
#define BGRAB0(__usi__)
Definition: macros.h:57
CDB6::Opcode
uint8_t Opcode
Definition: masstorage.h:204
CDB6::LBALB
uint8_t LBALB
Definition: masstorage.h:210
BGRAB2
#define BGRAB2(__usi__)
Definition: macros.h:59
BGRAB1
#define BGRAB1(__usi__)
Definition: macros.h:58
CDB6::LBAMSB
unsigned LBAMSB
Definition: masstorage.h:206
CDB6::LBAHB
uint8_t LBAHB
Definition: masstorage.h:209
CDB6::Control
uint8_t Control
Definition: masstorage.h:212
CDB6::AllocationLength
uint8_t AllocationLength
Definition: masstorage.h:211
CDB6::LUN
unsigned LUN
Definition: masstorage.h:207