Acc g scaling with DSP
[inav.git] / src / main / drivers / pinio.h
blobbaecc35a181037444f4fecf87e08db3b24f5ebc5
1 /*
2 * This file is part of Cleanflight, Betaflight and INAV
4 * Cleanflight, Betaflight and INAV are free software. You can
5 * redistribute this software and/or modify this software under
6 * the terms of the GNU General Public License as published by
7 * the Free Software Foundation, either version 3 of the License,
8 * or (at your option) any later version.
10 * Cleanflight, Betaflight and INAV are distributed in the hope that
11 * they will be useful, but WITHOUT ANY WARRANTY; without even the
12 * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
13 * PURPOSE. See the GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this software.
18 * If not, see <http://www.gnu.org/licenses/>.
21 #pragma once
23 #include <stdbool.h>
24 #include <stdint.h>
26 #include "drivers/io_types.h"
28 #define PINIO_COUNT 4
29 #define PINIO_FLAGS_INVERTED 0x80
31 typedef struct pinioHardware_s {
32 ioTag_t ioTag;
33 ioConfig_t ioMode;
34 uint16_t flags;
35 } pinioHardware_t;
37 extern const pinioHardware_t pinioHardware[];
38 extern const int pinioHardwareCount;
40 void pinioInit(void);
41 void pinioSet(int index, bool on);