Prusa MINI Firmware overview
usbh_msc_bot.h File Reference

Header file for usbh_msc_bot.c. More...

#include "usbh_core.h"
#include "usbh_msc_bot.h"

Go to the source code of this file.

Classes

union  BOT_CBWTypeDef
 
struct  BOT_CBWTypeDef::__CBW
 
union  BOT_CSWTypeDef
 
struct  BOT_CSWTypeDef::__CSW
 
struct  BOT_HandleTypeDef
 

Macros

#define BOT_CBW_SIGNATURE   0x43425355
 
#define BOT_CBW_TAG   0x20304050
 
#define BOT_CSW_SIGNATURE   0x53425355
 
#define BOT_CBW_LENGTH   31
 
#define BOT_CSW_LENGTH   13
 
#define BOT_SEND_CSW_DISABLE   0
 
#define BOT_SEND_CSW_ENABLE   1
 
#define BOT_DIR_IN   0
 
#define BOT_DIR_OUT   1
 
#define BOT_DIR_BOTH   2
 
#define BOT_PAGE_LENGTH   512
 
#define BOT_CBW_CB_LENGTH   16
 
#define USB_REQ_BOT_RESET   0xFF
 
#define USB_REQ_GET_MAX_LUN   0xFE
 
#define MAX_BULK_STALL_COUNT_LIMIT
 

Enumerations

enum  BOT_StatusTypeDef { BOT_OK = 0, BOT_FAIL = 1, BOT_PHASE_ERROR = 2, BOT_BUSY = 3 }
 
enum  BOT_CMDStateTypeDef { BOT_CMD_IDLE = 0, BOT_CMD_SEND, BOT_CMD_WAIT }
 
enum  BOT_CSWStatusTypeDef { BOT_CSW_CMD_PASSED = 0x00, BOT_CSW_CMD_FAILED = 0x01, BOT_CSW_PHASE_ERROR = 0x02 }
 
enum  BOT_StateTypeDef {
  BOT_SEND_CBW = 1, BOT_SEND_CBW_WAIT, BOT_DATA_IN, BOT_DATA_IN_WAIT,
  BOT_DATA_OUT, BOT_DATA_OUT_WAIT, BOT_RECEIVE_CSW, BOT_RECEIVE_CSW_WAIT,
  BOT_ERROR_IN, BOT_ERROR_OUT, BOT_UNRECOVERED_ERROR
}
 

Functions

USBH_StatusTypeDef USBH_MSC_BOT_REQ_Reset (USBH_HandleTypeDef *phost)
 USBH_MSC_BOT_REQ_Reset The function the MSC BOT Reset request. More...
 
USBH_StatusTypeDef USBH_MSC_BOT_REQ_GetMaxLUN (USBH_HandleTypeDef *phost, uint8_t *Maxlun)
 USBH_MSC_BOT_REQ_GetMaxLUN The function the MSC BOT GetMaxLUN request. More...
 
USBH_StatusTypeDef USBH_MSC_BOT_Init (USBH_HandleTypeDef *phost)
 USBH_MSC_BOT_Init The function Initializes the BOT protocol. More...
 
USBH_StatusTypeDef USBH_MSC_BOT_Process (USBH_HandleTypeDef *phost, uint8_t lun)
 USBH_MSC_BOT_Process The function handle the BOT protocol. More...
 
USBH_StatusTypeDef USBH_MSC_BOT_Error (USBH_HandleTypeDef *phost, uint8_t lun)
 

Detailed Description

Header file for usbh_msc_bot.c.

Author
MCD Application Team
Version
V3.2.2
Date
07-July-2015
Attention

© COPYRIGHT 2015 STMicroelectronics

Licensed under MCD-ST Liberty SW License Agreement V2, (the "License"); You may not use this file except in compliance with the License. You may obtain a copy of the License at:

   http://www.st.com/software_license_agreement_liberty_v2

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.