Skip to content

Commit

Permalink
Refactor code structure and remove unnecessary Arduino.h includes
Browse files Browse the repository at this point in the history
  • Loading branch information
FredM67 committed Mar 21, 2024
1 parent 378fb93 commit a2fe528
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 7 deletions.
2 changes: 0 additions & 2 deletions runtime/Mk2_3phase_RFdatalog_temp/ewma_avg.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@
#ifndef EWMA_AVG_H
#define EWMA_AVG_H

#include <Arduino.h>

#include "type_traits.hpp"

/**
Expand Down
2 changes: 0 additions & 2 deletions runtime/Mk2_3phase_RFdatalog_temp/movingAvg.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
#ifndef MOVINGAVG_H
#define MOVINGAVG_H

#include <Arduino.h>

#include "type_traits.hpp"

/**
Expand Down
50 changes: 49 additions & 1 deletion runtime/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ description = Router program
default_envs = basic
src_dir = Mk2_3phase_RFdatalog_temp

[env]
[options]
platform = atmelavr
framework = arduino
board = uno

build_flags =
-std=c++17
-std=gnu++17
Expand All @@ -33,18 +34,46 @@ monitor_filters =
time ; Add timestamp with milliseconds for each new line
log2file ; Log data to a file “platformio-device-monitor-*.log” located in the current working directory

unittesting_buildflag = -D unitTesting
generic_hw_buildflag = -D generic_hw
coverage_buildflag =
-lgcov
--coverage
-fprofile-abs-path
-Og

[env]
lib_ldf_mode = deep

[env:basic]
platform = ${options.platform}
board = ${options.board}
framework = ${options.framework}

build_flags =
${options.build_flags}
build_unflags =
${options.build_unflags}

extra_scripts =
${options.extra_scripts}

monitor_filters =
${options.monitor_filters}

[env:basic_debug]
extends = env:basic
build_type = debug

[env:temperature]
extends = env:basic
build_src_flags =
-DTEMP_ENABLED
lib_deps =
paulstoffregen/OneWire @ ^2.3.7

[env:emonesp]
extends = env:basic
build_src_flags =
-DEMONESP

Expand All @@ -55,7 +84,26 @@ build_src_flags =
-DEMONESP

[env:rf]
extends = env:basic
build_src_flags =
-DRF_PRESENT
lib_deps =
JeeLib

; #############################################################################
; ### Local and Cloud Unittesting : ALL generic unittests ###
; #############################################################################

; [env:all_generic_unittests]
; platform = native
; build_flags =
; ${options.unittesting_buildflag}
; ${options.generic_hw_buildflag}
; ${options.coverage_buildflag}
;
; test_framework = unity
; test_filter = test_generic*
; check_src_filters =
; lib/*
; ${src_dir}/*
; test/*
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#include <Arduino.h>
#include <unity.h>

#include "utils_relay.h"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#include <Arduino.h>
#include <unity.h>

#include "utils_relay.h"
Expand Down

0 comments on commit a2fe528

Please sign in to comment.