Skip to content

Commit

Permalink
remove default include paths: first pass
Browse files Browse the repository at this point in the history
  • Loading branch information
carpikes committed Jul 17, 2022
1 parent ecd038f commit bc3733b
Show file tree
Hide file tree
Showing 72 changed files with 309 additions and 235 deletions.
15 changes: 1 addition & 14 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -53,20 +53,7 @@ openrtx_src = ['openrtx/src/core/state.c',
'openrtx/src/protocols/M17/M17Transmitter.cpp',
'openrtx/src/protocols/M17/M17LinkSetupFrame.cpp']

openrtx_inc = ['openrtx/include',
'openrtx/include/rtx',
'openrtx/include/core',
'openrtx/include/calibration',
'openrtx/include/protocols',
'openrtx/include/fonts/adafruit',
'platform/drivers/ADC',
'platform/drivers/NVM',
'platform/drivers/GPS',
'platform/drivers/USB',
'platform/drivers/tones',
'platform/drivers/baseband',
'platform/drivers/backlight',
'platform/drivers/chSelector']
openrtx_inc = ['openrtx/include', 'platform']

main_src = []

Expand Down
3 changes: 2 additions & 1 deletion openrtx/include/calibration/calibInfo_GDx.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@
#ifndef CALIBINFO_GDX_H
#define CALIBINFO_GDX_H

#include <datatypes.h>
#include <stdint.h>

#include "core/datatypes.h"

/**
* \brief Calibration data for GDx platforms.
*/
Expand Down
3 changes: 2 additions & 1 deletion openrtx/include/calibration/calibInfo_MDx.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@
#ifndef CALIBINFO_MDX_H
#define CALIBINFO_MDX_H

#include <datatypes.h>
#include <stdint.h>

#include "core/datatypes.h"

/**
* Data types defining the structure of calibration data stored in external
* flash memory of MDx devices.
Expand Down
5 changes: 3 additions & 2 deletions openrtx/include/core/audio_codec.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@
#ifndef AUDIO_CODEC_H
#define AUDIO_CODEC_H

#include <interfaces/audio_path.h>
#include <stdint.h>
#include <stdbool.h>
#include <stdint.h>

#include "interfaces/audio_path.h"

#ifdef __cplusplus
extern "C" {
Expand Down
7 changes: 4 additions & 3 deletions openrtx/include/core/cps.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,11 @@
#ifndef CPS_H
#define CPS_H

#include <stdint.h>
#include <stdbool.h>
#include <datatypes.h>
#include <rtx.h>
#include <stdint.h>

#include "core/datatypes.h"
#include "rtx/rtx.h"

// Magic number to identify the binary file
#define CPS_MAGIC 0x43585452
Expand Down
2 changes: 2 additions & 0 deletions openrtx/include/core/event.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
#ifndef EVENT_H
#define EVENT_H

#include <stdint.h>

/**
* This enum describes the event message type:
* - EVENT_KBD is used to send a keypress
Expand Down
4 changes: 3 additions & 1 deletion openrtx/include/core/gps.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,11 @@
#ifndef GPS_H
#define GPS_H

#include <interfaces/rtc.h>
#include <stdint.h>

#include "interfaces/rtc.h"
#include "datetime.h"

/**
* Data structure representing a single satellite as part of a GPS fix.
*/
Expand Down
3 changes: 2 additions & 1 deletion openrtx/include/core/input.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@
#ifndef INPUT_H
#define INPUT_H

#include <interfaces/keyboard.h>
#include <inttypes.h>
#include <stdbool.h>

#include "interfaces/keyboard.h"

/**
* Time interval in milliseconds after which a keypress is considered a long-press
*/
Expand Down
6 changes: 3 additions & 3 deletions openrtx/include/core/queue.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@
#define QUEUE_H

#include <pthread.h>
#include <unistd.h>
#include <stdlib.h>
#include <stdint.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdlib.h>
#include <unistd.h>

// Ring buffer size (MAX = 255)
#define MSG_QTY 10
Expand Down
1 change: 1 addition & 0 deletions openrtx/include/core/ringbuf.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#endif

#include <pthread.h>

#include <cstdint>

/**
Expand Down
11 changes: 6 additions & 5 deletions openrtx/include/core/state.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,14 @@
#ifndef STATE_H
#define STATE_H

#include <interfaces/rtc.h>
#include <datatypes.h>
#include <settings.h>
#include <pthread.h>
#include <stdbool.h>
#include <cps.h>
#include <gps.h>

#include "cps.h"
#include "datatypes.h"
#include "gps.h"
#include "interfaces/rtc.h"
#include "settings.h"

/**
* Data structure representing the settings of the M17 mode.
Expand Down
11 changes: 6 additions & 5 deletions openrtx/include/core/ui.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,13 @@
#define UI_H

#include <stdbool.h>
#include <state.h>
#include <interfaces/graphics.h>
#include <interfaces/keyboard.h>
#include <stdint.h>
#include <event.h>
#include <hwconfig.h>

#include "event.h"
#include "hwconfig.h"
#include "interfaces/graphics.h"
#include "interfaces/keyboard.h"
#include "state.h"

// Maximum menu entry length
#define MAX_ENTRY_LEN 21
Expand Down
3 changes: 2 additions & 1 deletion openrtx/include/core/utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@
#ifndef CALIB_UTILS_H
#define CALIB_UTILS_H

#include <datatypes.h>
#include <stdint.h>

#include "datatypes.h"

#ifdef __cplusplus
extern "C" {
#endif
Expand Down
4 changes: 2 additions & 2 deletions openrtx/include/core/xmodem.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@
#ifndef XMODEM_H
#define XMODEM_H

#include <sys/types.h>
#include <stdint.h>
#include <stddef.h>
#include <stdint.h>
#include <sys/types.h>

#ifdef __cplusplus
extern "C" {
Expand Down
2 changes: 2 additions & 0 deletions openrtx/include/fonts/adafruit/gfxfont.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
#ifndef _GFXFONT_H_
#define _GFXFONT_H_

#include <stdint.h>

/// Font data stored PER GLYPH
typedef struct {
uint16_t bitmapOffset; ///< Pointer into GFXfont->bitmap
Expand Down
3 changes: 2 additions & 1 deletion openrtx/include/interfaces/audio.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@

#include <stdbool.h>
#include <stdint.h>
#include <rtx.h>

#include "rtx/rtx.h"

#ifdef __cplusplus
extern "C" {
Expand Down
2 changes: 1 addition & 1 deletion openrtx/include/interfaces/cps_io.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#define CPS_IO_H

#include <stdint.h>
#include <cps.h>
#include "core/cps.h"

#ifdef __cplusplus
extern "C" {
Expand Down
31 changes: 18 additions & 13 deletions openrtx/include/interfaces/graphics.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,25 @@
#ifndef GRAPHICS_H
#define GRAPHICS_H

#include <stdint.h>
#include <stdbool.h>
#include <interfaces/display.h>
#include <state.h>
#include <gfxfont.h>
#include <TomThumb.h>
#include <FreeSans6pt7b.h>
#include <FreeSans8pt7b.h>
#include <FreeSans9pt7b.h>
#include <FreeSans10pt7b.h>
#include <FreeSans12pt7b.h>
#include <FreeSans16pt7b.h>
#include <FreeSans18pt7b.h>
#include <FreeSans24pt7b.h>
#include <stdint.h>

#include "core/state.h"
#include "display.h"

// This one before the fonts
#include "fonts/adafruit/gfxfont.h"

// Fonts includes
#include "fonts/adafruit/FreeSans10pt7b.h"
#include "fonts/adafruit/FreeSans12pt7b.h"
#include "fonts/adafruit/FreeSans16pt7b.h"
#include "fonts/adafruit/FreeSans18pt7b.h"
#include "fonts/adafruit/FreeSans24pt7b.h"
#include "fonts/adafruit/FreeSans6pt7b.h"
#include "fonts/adafruit/FreeSans8pt7b.h"
#include "fonts/adafruit/FreeSans9pt7b.h"
#include "fonts/adafruit/TomThumb.h"

#ifdef __cplusplus
#include <deque>
Expand Down
7 changes: 4 additions & 3 deletions openrtx/include/interfaces/nvmem.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@
#define NVMEM_H

#include <stdint.h>
#include <cps.h>
#include <settings.h>
#include "platform.h"

#include "core/cps.h"
#include "core/settings.h"
#include "interfaces/platform.h"

#ifdef __cplusplus
extern "C" {
Expand Down
3 changes: 2 additions & 1 deletion openrtx/include/interfaces/radio.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@

#include <stdbool.h>
#include <stdint.h>
#include <rtx.h>

#include "rtx/rtx.h"

#ifdef __cplusplus
extern "C" {
Expand Down
3 changes: 2 additions & 1 deletion openrtx/include/interfaces/rtc.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@
#ifndef RTC_H
#define RTC_H

#include <datetime.h>
#include <stdint.h>

#include "core/datetime.h"

/**
* Standard interface for real time clock drivers, providing both calendar and
* clock functionalities.
Expand Down
6 changes: 4 additions & 2 deletions openrtx/include/protocols/M17/M17Constants.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,11 @@
#ifndef M17_CONSTANTS_H
#define M17_CONSTANTS_H

#include <M17/M17Datatypes.hpp>
#include <cstdint>
#include <array>
#include <cstddef>
#include <cstdint>

#include "M17Datatypes.hpp"

#ifndef __cplusplus
#error This header is C++ only!
Expand Down
3 changes: 2 additions & 1 deletion openrtx/include/protocols/M17/M17DSP.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,10 @@
#error This header is C++ only!
#endif

#include <fir.hpp>
#include <array>

#include "core/fir.hpp"

namespace M17
{

Expand Down
15 changes: 8 additions & 7 deletions openrtx/include/protocols/M17/M17Demodulator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,16 @@
#error This header is C++ only!
#endif

#include <cstdint>
#include <cstddef>
#include <memory>
#include <array>
#include <dsp.h>
#include <cmath>
#include <interfaces/audio_stream.h>
#include <M17/M17Datatypes.hpp>
#include <M17/M17Constants.hpp>
#include <cstddef>
#include <cstdint>
#include <memory>

#include "M17Constants.hpp"
#include "M17Datatypes.hpp"
#include "core/dsp.h"
#include "interfaces/audio_stream.h"

namespace M17
{
Expand Down
5 changes: 3 additions & 2 deletions openrtx/include/protocols/M17/M17FrameDecoder.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,13 @@
#error This header is C++ only!
#endif

#include <array>
#include <cstdint>
#include <string>
#include <array>

#include "M17LinkSetupFrame.hpp"
#include "M17Viterbi.hpp"
#include "M17StreamFrame.hpp"
#include "M17Viterbi.hpp"

namespace M17
{
Expand Down
3 changes: 2 additions & 1 deletion openrtx/include/protocols/M17/M17FrameEncoder.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,9 @@
#error This header is C++ only!
#endif

#include <string>
#include <array>
#include <string>

#include "M17ConvolutionalEncoder.hpp"
#include "M17LinkSetupFrame.hpp"
#include "M17StreamFrame.hpp"
Expand Down
9 changes: 5 additions & 4 deletions openrtx/include/protocols/M17/M17Modulator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,13 @@
#error This header is C++ only!
#endif

#include <interfaces/audio_stream.h>
#include <M17/M17Constants.hpp>
#include <array>
#include <cstdint>
#include <memory>
#include <array>
#include <dsp.h>

#include "M17Constants.hpp"
#include "core/dsp.h"
#include "interfaces/audio_stream.h"

namespace M17
{
Expand Down
1 change: 1 addition & 0 deletions openrtx/include/protocols/M17/M17StreamFrame.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@

#include <cstring>
#include <string>

#include "M17Datatypes.hpp"

namespace M17
Expand Down
Loading

0 comments on commit bc3733b

Please sign in to comment.