Cosmetics

This commit is contained in:
Bertrand Songis
2016-07-23 19:28:30 +02:00
parent dd44da14bc
commit 0ad015f3e7
32 changed files with 227 additions and 183 deletions
@@ -18,11 +18,11 @@
* GNU General Public License for more details.
*/
#include "../../opentx.h"
#include "opentx.h"
#ifndef SIMU
inline void boardInit()
void boardInit()
{
#if !defined(SIMU)
// Set up I/O port data directions and initial states
DDRA = 0xff; PORTA = 0x00; // LCD data
DDRB = 0b11000111; PORTB = 0b00111111; // 7:SPKR, 6:PPM_OUT, 5:TrainSW, 4:IDL2_SW, SDCARD[3:MISO 2:MOSI 1:SCK 0:CS]
@@ -88,7 +88,7 @@ inline void boardInit()
#endif
/***************************************************/
#if defined (VOICE)
#if defined(VOICE)
/*
* SOMO set-up (V4 board only)
*/
@@ -108,10 +108,10 @@ inline void boardInit()
UCSR1B = (1<<RXEN1)|(0<<TXEN1)|(1<<UCSZ12);
UCSR1B |= 1 << RXCIE1; //enable interrupt on rx
#endif
#endif // !defined(SIMU)
}
#if ROTARY_ENCODERS > 2
uint8_t vpotToChange = 0;
uint8_t vpot_mod_state = 0;
@@ -146,7 +146,6 @@ ISR(USART1_RX_vect)
}
}
#endif
#endif // !SIMU
uint8_t pwrCheck()
{
+27 -23
View File
@@ -1,28 +1,32 @@
/*
* 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_GRUVIN9X_H_
#define _BOARD_GRUVIN9X_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_GRUVIN9X_H_
#define _BOARD_GRUVIN9X_H_
#include "../common_avr/board_avr.h"
// Board driver
void boardInit(void);
#define boardOff() pwrOff()
// Keys
#define KEYS_GPIO_REG_MENU pinl
#define KEYS_GPIO_PIN_MENU (1<<4)
@@ -166,4 +170,4 @@ void pwrOff();
#define eepromReadBlock(a, b, c) eeprom_read_block(a, (const void *)b, c)
#endif
#endif // _BOARD_GRUVIN9X_H_
#endif // _BOARD_GRUVIN9X_H_