Sky9x added to CMakeLists.txt
This commit is contained in:
@@ -1,23 +1,23 @@
|
||||
/*
|
||||
* Copyright (C) OpenTX
|
||||
*
|
||||
* Based on code named
|
||||
* th9x - http://code.google.com/p/th9x
|
||||
* er9x - http://code.google.com/p/er9x
|
||||
* gruvin9x - http://code.google.com/p/gruvin9x
|
||||
*
|
||||
* License GPLv2: http://www.gnu.org/licenses/gpl-2.0.html
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License version 2 as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Copyright (C) OpenTX
|
||||
*
|
||||
* Based on code named
|
||||
* th9x - http://code.google.com/p/th9x
|
||||
* er9x - http://code.google.com/p/er9x
|
||||
* gruvin9x - http://code.google.com/p/gruvin9x
|
||||
*
|
||||
* License GPLv2: http://www.gnu.org/licenses/gpl-2.0.html
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License version 2 as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
#include "../../opentx.h"
|
||||
|
||||
uint16_t ResetReason;
|
||||
@@ -468,8 +468,6 @@ void i2cInit()
|
||||
NVIC_EnableIRQ(TWI0_IRQn) ;
|
||||
}
|
||||
|
||||
extern const uint8_t BootCode[];
|
||||
|
||||
void boardInit()
|
||||
{
|
||||
// TODO this is not clean, completely unuseful, but prevents the bootloader from being optimized away...
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
/*
|
||||
* Copyright (C) OpenTX
|
||||
*
|
||||
* Based on code named
|
||||
* th9x - http://code.google.com/p/th9x
|
||||
* er9x - http://code.google.com/p/er9x
|
||||
* gruvin9x - http://code.google.com/p/gruvin9x
|
||||
*
|
||||
* License GPLv2: http://www.gnu.org/licenses/gpl-2.0.html
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License version 2 as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef _BOARD_SKY9X_H_
|
||||
#define _BOARD_SKY9X_H_
|
||||
/*
|
||||
* Copyright (C) OpenTX
|
||||
*
|
||||
* Based on code named
|
||||
* th9x - http://code.google.com/p/th9x
|
||||
* er9x - http://code.google.com/p/er9x
|
||||
* gruvin9x - http://code.google.com/p/gruvin9x
|
||||
*
|
||||
* License GPLv2: http://www.gnu.org/licenses/gpl-2.0.html
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License version 2 as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef _BOARD_SKY9X_H_
|
||||
#define _BOARD_SKY9X_H_
|
||||
|
||||
#include <stdio.h>
|
||||
#include "board.h"
|
||||
@@ -155,12 +155,10 @@ extern uint16_t sessionTimer;
|
||||
void calcConsumption();
|
||||
#endif
|
||||
|
||||
// Trainer driver
|
||||
#define SLAVE_MODE() (pwrCheck() == e_power_trainer)
|
||||
// #define JACK_PPM_OUT() PIOC->PIO_PDR = PIO_PC22
|
||||
// #define JACK_PPM_IN() PIOC->PIO_PER = PIO_PC22
|
||||
void checkTrainerSettings();
|
||||
|
||||
void setSticksGain(uint8_t gains);
|
||||
void init_trainer_capture();
|
||||
|
||||
// Write Flash driver
|
||||
#define FLASH_PAGESIZE 256
|
||||
@@ -229,7 +227,8 @@ enum Analogs {
|
||||
};
|
||||
void adcInit();
|
||||
void adcRead(void);
|
||||
inline uint16_t getAnalogValue(uint32_t value);
|
||||
uint16_t getAnalogValue(uint32_t value);
|
||||
void setSticksGain(uint8_t gains);
|
||||
|
||||
// Buzzer driver
|
||||
void buzzerSound(uint8_t duration);
|
||||
@@ -269,6 +268,11 @@ uint32_t pwrCheck();
|
||||
// EEPROM driver
|
||||
void eepromInit();
|
||||
uint32_t eepromReadStatus();
|
||||
extern volatile uint32_t Spi_complete;
|
||||
void eepromWriteEnable();
|
||||
void eepromBlockErase(uint32_t address);
|
||||
void eepromReadArray(uint32_t address, uint8_t * buffer, uint32_t size);
|
||||
void eepromByteProgram(uint32_t address, uint8_t * buffer, uint32_t size);
|
||||
|
||||
// Rotary Encoder driver
|
||||
void rotencInit();
|
||||
@@ -287,9 +291,12 @@ void debugPutc(const char c);
|
||||
void telemetryPortInit(uint32_t baudrate);
|
||||
uint32_t telemetryTransmitPending();
|
||||
void telemetryTransmitBuffer(uint8_t * buffer, uint32_t size);
|
||||
void rxPdcUsart( void (*pChProcess)(uint8_t x) );
|
||||
|
||||
// Second UART driver
|
||||
void serial2TelemetryInit(unsigned int protocol);
|
||||
bool telemetrySecondPortReceive(uint8_t & data);
|
||||
|
||||
#endif // _BOARD_SKY9X_H_
|
||||
extern const uint8_t BootCode[];
|
||||
|
||||
#endif // _BOARD_SKY9X_H_
|
||||
|
||||
@@ -24,13 +24,9 @@
|
||||
/* Only rcvr_spi(), xmit_spi(), sdPoll10ms() and some macros */
|
||||
/* are platform dependent. */
|
||||
/*-----------------------------------------------------------------------*/
|
||||
|
||||
#include <string.h>
|
||||
#include "debug.h"
|
||||
#include "../FatFs/diskio.h"
|
||||
#include "../FatFs/ff.h"
|
||||
#include "../CoOS/kernel/CoOS.h"
|
||||
#include "board.h"
|
||||
|
||||
#include "../../opentx.h"
|
||||
#include "../FatFs/diskio.h"
|
||||
|
||||
#define CARD_TYPE_bmHC (1 << 0) /**< Bit for High-Capacity(Density) */
|
||||
#define CARD_TYPE_bmSDMMC (0x3 << 1) /**< Bits mask for SD/MMC */
|
||||
|
||||
@@ -18,6 +18,8 @@
|
||||
* GNU General Public License for more details.
|
||||
*/
|
||||
|
||||
#include "../../opentx.h"
|
||||
|
||||
#define MCI_INITIAL_SPEED 400000
|
||||
|
||||
void init_SDcard()
|
||||
|
||||
Reference in New Issue
Block a user