2010-08-22 21:51:55 +02:00
|
|
|
/******************** (C) COPYRIGHT 2010 STMicroelectronics ********************
|
|
|
|
* File Name : usb_endp.c
|
|
|
|
* Author : MCD Application Team
|
|
|
|
* Version : V3.2.1
|
|
|
|
* Date : 07/05/2010
|
|
|
|
* Description : Endpoint routines
|
|
|
|
********************************************************************************
|
|
|
|
* THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
|
|
|
|
* WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE TIME.
|
|
|
|
* AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY DIRECT,
|
|
|
|
* INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING FROM THE
|
|
|
|
* CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE CODING
|
|
|
|
* INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
|
|
|
|
*******************************************************************************/
|
|
|
|
|
|
|
|
/* Includes ------------------------------------------------------------------*/
|
|
|
|
#include "platform_config.h"
|
|
|
|
#include "stm32f10x.h"
|
|
|
|
#include "usb_lib.h"
|
|
|
|
#include "usb_istr.h"
|
|
|
|
#include "stm32_eval.h"
|
|
|
|
#include "stm32f10x_flash.h"
|
|
|
|
#include "common.h"
|
|
|
|
#include "hw_config.h"
|
2010-09-02 22:13:41 +02:00
|
|
|
#include "op_dfu.h"
|
2010-08-26 00:31:14 +02:00
|
|
|
|
2010-08-22 21:51:55 +02:00
|
|
|
/* Private typedef -----------------------------------------------------------*/
|
|
|
|
/* Private define ------------------------------------------------------------*/
|
|
|
|
/* Private macro -------------------------------------------------------------*/
|
|
|
|
/* Private variables ---------------------------------------------------------*/
|
2010-08-24 20:26:44 +02:00
|
|
|
uint8_t Receive_Buffer[64];
|
2010-08-22 21:51:55 +02:00
|
|
|
/*******************************************************************************
|
|
|
|
* Function Name : EP1_OUT_Callback.
|
|
|
|
* Description : EP1 OUT Callback Routine.
|
|
|
|
* Input : None.
|
|
|
|
* Output : None.
|
|
|
|
* Return : None.
|
|
|
|
*******************************************************************************/
|
|
|
|
void EP1_OUT_Callback(void)
|
|
|
|
{
|
|
|
|
USB_SIL_Read(EP1_OUT, Receive_Buffer);
|
2010-09-02 22:13:41 +02:00
|
|
|
processComand(Receive_Buffer+1);
|
2010-08-22 21:51:55 +02:00
|
|
|
SetEPRxStatus(ENDP1, EP_RX_VALID);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
/******************* (C) COPYRIGHT 2010 STMicroelectronics *****END OF FILE****/
|
|
|
|
|