Cosmetics

This commit is contained in:
Bertrand Songis
2016-07-02 09:56:16 +02:00
parent 42aa06a166
commit 30f31450ce
3 changed files with 47 additions and 60 deletions
+2 -11
View File
@@ -100,16 +100,7 @@ void USB_OTG_BSP_DisableInterrupt(USB_OTG_CORE_HANDLE *pdev)
*/
void USB_OTG_BSP_uDelay (const uint32_t usec)
{
uint32_t count = 0;
const uint32_t utime = ((SystemCoreClock/1000000) * usec);
do
{
if ( ++count > utime )
{
return ;
}
}
while (1);
delay_us(usec);
}
@@ -121,7 +112,7 @@ void USB_OTG_BSP_uDelay (const uint32_t usec)
*/
void USB_OTG_BSP_mDelay (const uint32_t msec)
{
USB_OTG_BSP_uDelay(msec * 1000);
delay_ms(msec);
}
+4 -4
View File
@@ -21,15 +21,15 @@
/* Includes ------------------------------------------------------------------*/
#include "../../opentx.h"
#include "../../thirdparty/FatFs/diskio.h"
#include "../horus/board_horus.h"
#include "../horus/sdio_sd.h"
#include "board_horus.h"
#include "sdio_sd.h"
#if defined(__cplusplus) && !defined(SIMU)
extern "C" {
#endif
#include "usbd_msc_mem.h"
#include "../horus/usb_conf.h"
#include "usb_conf.h"
/* SD card only when not running bootloader */
#define STORAGE_LUN_NBR 1
@@ -130,7 +130,7 @@ int8_t STORAGE_GetCapacity (uint8_t lun, uint32_t *block_num, uint32_t *block_si
return 0;
}
uint8_t lunReady[1] ;
uint8_t lunReady[STORAGE_LUN_NBR] ;
void usbPluggedIn()
{
@@ -171,11 +171,7 @@ int8_t STORAGE_GetCapacity (uint8_t lun, uint32_t *block_num, uint32_t *block_si
return 0;
}
#if defined(BOOT)
uint8_t lunReady[2] ;
#else
uint8_t lunReady[1] ;
#endif
uint8_t lunReady[STORAGE_LUN_NBR];
void usbPluggedIn()
{