3 files removed

This commit is contained in:
bsongis
2014-03-04 17:14:35 +01:00
parent 74872b1322
commit 51fe47ed8a
10 changed files with 35 additions and 581 deletions
+5 -6
View File
@@ -37,6 +37,10 @@
#ifndef board_taranis_h
#define board_taranis_h
#ifdef __cplusplus
extern "C" {
#endif
#include "STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/inc/stm32f2xx_rcc.h"
#include "STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/inc/stm32f2xx_gpio.h"
#include "STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/inc/stm32f2xx_spi.h"
@@ -45,11 +49,6 @@
#include "STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/inc/stm32f2xx_dma.h"
#include "STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/inc/stm32f2xx_usart.h"
#include "STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/CMSIS/Device/ST/STM32F2xx/Include/stm32f2xx.h"
#ifdef __cplusplus
extern "C" {
#endif
#include "STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Class/msc/inc/usbd_msc_core.h"
#include "STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Core/inc/usbd_usr.h"
#include "usbd_desc.h"
@@ -86,7 +85,7 @@ extern uint16_t sessionTimer;
#define SLAVE_MODE() (g_model.trainerMode == 1)
#define TRAINER_CONNECTED() (GPIO_ReadInputDataBit(GPIOTRNDET, PIN_TRNDET) == Bit_RESET)
void delaysInit();
void delaysInit(void);
#define DEBUG_BAUDRATE 115200
#define SPORT_BAUDRATE 57600
+15 -7
View File
@@ -35,9 +35,10 @@
*/
#include <string.h>
#include "../FatFs/diskio.h"
#include "../FatFs/ff.h"
#include "../CoOS/kernel/CoOS.h"
#include "board_taranis.h"
#include "../../FatFs/diskio.h"
#include "../../FatFs/ff.h"
#include "../../CoOS/kernel/CoOS.h"
#include "hal.h"
/* Definitions for MMC/SDC command */
@@ -93,6 +94,7 @@ uint32_t transSpeed; */
/*-----------------------------------------------------------------------*/
/* Lock / unlock functions */
/*-----------------------------------------------------------------------*/
#if !defined(BOOT)
int ff_cre_syncobj (BYTE vol, _SYNC_t *mutex)
{
*mutex = CoCreateMutex();
@@ -114,6 +116,7 @@ int ff_del_syncobj (_SYNC_t mutex)
{
return 1;
}
#endif
static const DWORD socket_state_mask_cp = (1 << 0);
static const DWORD socket_state_mask_wp = (1 << 1);
@@ -124,7 +127,6 @@ DSTATUS Stat = STA_NOINIT; /* Disk status */
static volatile
DWORD Timer1, Timer2; /* 100Hz decrement timers */
static
BYTE CardType; /* Card type flags */
enum speed_setting { INTERFACE_SLOW, INTERFACE_FAST };
@@ -655,7 +657,6 @@ DSTATUS disk_initialize (
/*-----------------------------------------------------------------------*/
/* Get Disk Status */
/*-----------------------------------------------------------------------*/
DSTATUS disk_status (
BYTE drv /* Physical drive number (0) */
)
@@ -665,7 +666,6 @@ DSTATUS disk_status (
}
/*-----------------------------------------------------------------------*/
/* Read Sector(s) */
/*-----------------------------------------------------------------------*/
@@ -966,7 +966,14 @@ FATFS g_FATFS_Obj;
FIL g_telemetryFile = {0};
#endif
void sdInit()
#if defined(BOOT)
void sdInit(void)
{
f_mount(0, &g_FATFS_Obj);
}
#else
// TODO shouldn't be there!
void sdInit(void)
{
if (f_mount(0, &g_FATFS_Obj) == FR_OK) {
referenceSystemAudioFiles();
@@ -989,6 +996,7 @@ void sdDone()
f_mount(0, 0); // unmount SD
}
}
#endif
uint32_t sdMounted()
{
+3 -1
View File
@@ -307,7 +307,9 @@
#define STM32_SD_DISK_IOCTRL_FORCE 0
//DMA
#define STM32_SD_USE_DMA //Enable the DMA for SD
#if !defined(BOOT)
#define STM32_SD_USE_DMA //Enable the DMA for SD
#endif
#ifdef STM32_SD_USE_DMA
#define DMA_Channel_SPI_SD_RX DMA1_Stream3