Nirvana Jay / Mbed 2 deprecated F7DISCO_Demo

Dependencies:   BSP_DISCO_F746NG_patch mbed-rtos mbed

Embed: (wiki syntax)

« Back to documentation index

usbd_conf_template.c File Reference

usbd_conf_template.c File Reference

USB Device configuration and interface file This template should be copied to the user folder, renamed and customized following user needs. More...

Go to the source code of this file.

Functions

USBD_StatusTypeDef USBD_LL_Init (USBD_HandleTypeDef *pdev)
 Initializes the Low Level portion of the Device driver.
USBD_StatusTypeDef USBD_LL_DeInit (USBD_HandleTypeDef *pdev)
 De-Initializes the Low Level portion of the Device driver.
USBD_StatusTypeDef USBD_LL_Start (USBD_HandleTypeDef *pdev)
 Starts the Low Level portion of the Device driver.
USBD_StatusTypeDef USBD_LL_Stop (USBD_HandleTypeDef *pdev)
 Stops the Low Level portion of the Device driver.
USBD_StatusTypeDef USBD_LL_OpenEP (USBD_HandleTypeDef *pdev, uint8_t ep_addr, uint8_t ep_type, uint16_t ep_mps)
 Opens an endpoint of the Low Level Driver.
USBD_StatusTypeDef USBD_LL_CloseEP (USBD_HandleTypeDef *pdev, uint8_t ep_addr)
 Closes an endpoint of the Low Level Driver.
USBD_StatusTypeDef USBD_LL_FlushEP (USBD_HandleTypeDef *pdev, uint8_t ep_addr)
 Flushes an endpoint of the Low Level Driver.
USBD_StatusTypeDef USBD_LL_StallEP (USBD_HandleTypeDef *pdev, uint8_t ep_addr)
 Sets a Stall condition on an endpoint of the Low Level Driver.
USBD_StatusTypeDef USBD_LL_ClearStallEP (USBD_HandleTypeDef *pdev, uint8_t ep_addr)
 Clears a Stall condition on an endpoint of the Low Level Driver.
uint8_t USBD_LL_IsStallEP (USBD_HandleTypeDef *pdev, uint8_t ep_addr)
 Returns Stall condition.
USBD_StatusTypeDef USBD_LL_SetUSBAddress (USBD_HandleTypeDef *pdev, uint8_t dev_addr)
 Assigns a USB address to the device.
USBD_StatusTypeDef USBD_LL_Transmit (USBD_HandleTypeDef *pdev, uint8_t ep_addr, uint8_t *pbuf, uint16_t size)
 Transmits data over an endpoint.
USBD_StatusTypeDef USBD_LL_PrepareReceive (USBD_HandleTypeDef *pdev, uint8_t ep_addr, uint8_t *pbuf, uint16_t size)
 Prepares an endpoint for reception.
uint32_t USBD_LL_GetRxDataSize (USBD_HandleTypeDef *pdev, uint8_t ep_addr)
 Returns the last transferred packet size.
void USBD_LL_Delay (uint32_t Delay)
 Delays routine for the USB Device Library.

Detailed Description

USB Device configuration and interface file This template should be copied to the user folder, renamed and customized following user needs.

Author:
MCD Application Team
Version:
V2.4.1
Date:
19-June-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.

Definition in file usbd_conf_template.c.


Function Documentation

USBD_StatusTypeDef USBD_LL_ClearStallEP ( USBD_HandleTypeDef *  pdev,
uint8_t  ep_addr 
)

Clears a Stall condition on an endpoint of the Low Level Driver.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
Return values:
USBDStatus

Definition at line 133 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_CloseEP ( USBD_HandleTypeDef *  pdev,
uint8_t  ep_addr 
)

Closes an endpoint of the Low Level Driver.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
Return values:
USBDStatus

Definition at line 100 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_DeInit ( USBD_HandleTypeDef *  pdev )

De-Initializes the Low Level portion of the Device driver.

Parameters:
pdev,:Device handle
Return values:
USBDStatus

Definition at line 53 of file usbd_conf_template.c.

void USBD_LL_Delay ( uint32_t  Delay )

Delays routine for the USB Device Library.

Parameters:
Delay,:Delay in ms
Return values:
None

Definition at line 208 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_FlushEP ( USBD_HandleTypeDef *  pdev,
uint8_t  ep_addr 
)

Flushes an endpoint of the Low Level Driver.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
Return values:
USBDStatus

Definition at line 111 of file usbd_conf_template.c.

uint32_t USBD_LL_GetRxDataSize ( USBD_HandleTypeDef *  pdev,
uint8_t  ep_addr 
)

Returns the last transferred packet size.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
Return values:
RecivedData Size

Definition at line 198 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_Init ( USBD_HandleTypeDef *  pdev )

Initializes the Low Level portion of the Device driver.

Parameters:
pdev,:Device handle
Return values:
USBDStatus

Definition at line 43 of file usbd_conf_template.c.

uint8_t USBD_LL_IsStallEP ( USBD_HandleTypeDef *  pdev,
uint8_t  ep_addr 
)

Returns Stall condition.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
Return values:
Stall(1: Yes, 0: No)

Definition at line 144 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_OpenEP ( USBD_HandleTypeDef *  pdev,
uint8_t  ep_addr,
uint8_t  ep_type,
uint16_t  ep_mps 
)

Opens an endpoint of the Low Level Driver.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
ep_type,:Endpoint Type
ep_mps,:Endpoint Max Packet Size
Return values:
USBDStatus

Definition at line 86 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_PrepareReceive ( USBD_HandleTypeDef *  pdev,
uint8_t  ep_addr,
uint8_t *  pbuf,
uint16_t  size 
)

Prepares an endpoint for reception.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
pbuf,:Pointer to data to be received
size,:Data size
Return values:
USBDStatus

Definition at line 184 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_SetUSBAddress ( USBD_HandleTypeDef *  pdev,
uint8_t  dev_addr 
)

Assigns a USB address to the device.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
Return values:
USBDStatus

Definition at line 155 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_StallEP ( USBD_HandleTypeDef *  pdev,
uint8_t  ep_addr 
)

Sets a Stall condition on an endpoint of the Low Level Driver.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
Return values:
USBDStatus

Definition at line 122 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_Start ( USBD_HandleTypeDef *  pdev )

Starts the Low Level portion of the Device driver.

Parameters:
pdev,:Device handle
Return values:
USBDStatus

Definition at line 63 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_Stop ( USBD_HandleTypeDef *  pdev )

Stops the Low Level portion of the Device driver.

Parameters:
pdev,:Device handle
Return values:
USBDStatus

Definition at line 73 of file usbd_conf_template.c.

USBD_StatusTypeDef USBD_LL_Transmit ( USBD_HandleTypeDef *  pdev,
uint8_t  ep_addr,
uint8_t *  pbuf,
uint16_t  size 
)

Transmits data over an endpoint.

Parameters:
pdev,:Device handle
ep_addr,:Endpoint Number
pbuf,:Pointer to data to be sent
size,:Data size
Return values:
USBDStatus

Definition at line 168 of file usbd_conf_template.c.