Skip to content

Commit 6aa4c19

Browse files
committed
Merge branch 'add_telegram_interface'
2 parents f4caf84 + 7ee8ed1 commit 6aa4c19

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+3032
-1833
lines changed

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* text=auto

interface_temperature/README.md

Lines changed: 28 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,36 @@
1-
# Interface Température Pour Domoticz
2-
Permet d'envoyer la température de deux sondes etanches vers un serveur Domoticz en Wifi.
1+
# LightKit
32

4-
## Changelog
5-
### [v2.3] - 23/07/19
6-
- Remplacement des 3 LED R, G, B par une led NéoPixel
3+
LightKit est un logiciel modulaire capable de donner la vie aux cartes électronique de notre cher Pascal.
74

8-
### [v2.2] - 19/07/19
9-
- Ajout de la détection automatique des sondes
10-
- Passage du prototype Rev. B de 3v3 à 5V pour l'alim des sondes
5+
## Auteurs
116

12-
### [v2.1] - 19/07/19
13-
- Passage à PlatformIO
7+
* **Pascal RONDANE** - *Concepteur initial*
8+
* **Bastian BOUCHARDON** - *Concepteur initial*
9+
* **David DEVANT** - *Amélioration logicielle* - [Devdevdavid](https://github.com/Devdevdavid)
1410

15-
### [v1.2] - 16/07/19
16-
- Ajout adresse second capteur
11+
# Notes pour les développeurs
1712

18-
### [v1.1] - 18/10/18
19-
- Ajout LED de visu OK
13+
## Utilisation de platformIO CLI
2014

21-
### [v1.0] - 17/05/18
22-
- Module Ok, ajout OTA
15+
- `platformio device monitor` : Ouvrir l'interface série pour le debug
16+
- `platformio run -e board_temp_telegram_relay` : Lancer une compilation
17+
- `platformio run --target upload -e board_temp_telegram_relay` : Lancer une compilation suivi d'un upload
2318

24-
## Auteurs
19+
## Utilisation de Clang-Format
20+
21+
Pour appliquer le formattage sur tous les fichiers de `src`:
22+
23+
```bash
24+
clang-format -i src/*.[ch]pp src/*/*.[ch]pp
25+
```
26+
27+
Pour omettre certaines parties du code, on utilise ceci :
28+
29+
```
30+
int formatted_code;
31+
// clang-format off
32+
void unformatted_code ;
33+
// clang-format on
34+
void formatted_code_again;
35+
```
2536

26-
* **Pascal RONDANE** - *Concepteur initial*
27-
* **Bastian BOUCHARDON** - *Concepteur initial*
28-
* **David DEVANT** - *Amélioration logicielle* - [Devdevdavid](https://github.com/Devdevdavid)
Binary file not shown.
Binary file not shown.
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
# Basic .clang-format
2+
---
3+
4+
# Guide : https://clang.llvm.org/docs/ClangFormatStyleOptions.html
5+
6+
# --- CHANGELOG ---
7+
# Rev B (18/08/2020) : Add pointers
8+
# Rev A (01/06/2020) : First revision
9+
10+
# Others
11+
AccessModifierOffset: 0
12+
AlignEscapedNewlinesLeft: true
13+
AlignConsecutiveAssignments: true
14+
AlignConsecutiveDeclarations: true
15+
AlignTrailingComments: true
16+
AllowAllParametersOfDeclarationOnNextLine: false
17+
AllowShortFunctionsOnASingleLine: true
18+
AllowShortLoopsOnASingleLine: true
19+
AlwaysBreakBeforeMultilineStrings: false
20+
AlwaysBreakTemplateDeclarations: false
21+
BinPackParameters: false
22+
BreakBeforeBinaryOperators: false
23+
BreakBeforeTernaryOperators: false
24+
BreakConstructorInitializersBeforeComma: false
25+
CommentPragmas: ''
26+
ConstructorInitializerAllOnOneLineOrOnePerLine: false
27+
ConstructorInitializerIndentWidth: 0
28+
ContinuationIndentWidth: 0
29+
Cpp11BracedListStyle: false
30+
DerivePointerBinding: false
31+
IndentFunctionDeclarationAfterType: false
32+
NamespaceIndentation: None
33+
ObjCSpaceAfterProperty: true
34+
ObjCSpaceBeforeProtocolList: true
35+
PenaltyBreakBeforeFirstCallParameter: 100
36+
PenaltyBreakComment: 100
37+
PenaltyBreakFirstLessLess: 0
38+
PenaltyBreakString: 100
39+
PenaltyExcessCharacter: 1
40+
PenaltyReturnTypeOnItsOwnLine: 20
41+
42+
# Defines
43+
AlignConsecutiveMacros: true
44+
AlignEscapedNewlines: Left
45+
46+
# Code
47+
Language: Cpp
48+
Standard: Cpp11
49+
ColumnLimit: 0
50+
MaxEmptyLinesToKeep: 1
51+
SpacesInParentheses: false
52+
SpaceAfterCStyleCast: true
53+
AllowShortBlocksOnASingleLine: false
54+
55+
# Braces
56+
BreakBeforeBraces: Custom
57+
BraceWrapping:
58+
AfterCaseLabel: false
59+
AfterClass: false
60+
AfterControlStatement: Never
61+
AfterEnum: true
62+
AfterFunction: true
63+
AfterNamespace : false
64+
AfterStruct: false
65+
AfterUnion: false
66+
AfterExternBlock: false
67+
BeforeCatch: false
68+
BeforeElse: false
69+
SplitEmptyFunction: false
70+
71+
# Function
72+
AllowShortFunctionsOnASingleLine: false
73+
74+
# Indent
75+
IndentWidth: 4
76+
TabWidth : 4
77+
UseTab: ForContinuationAndIndentation
78+
79+
# IF
80+
AllowShortIfStatementsOnASingleLine: Never
81+
SpacesInConditionalStatement: false
82+
83+
# Goto Labels
84+
IndentGotoLabels: false
85+
86+
# Case
87+
IndentCaseLabels: false
88+
89+
# PPDirective
90+
IndentPPDirectives: None
91+
92+
# Pointer
93+
PointerAlignment: Middle

interface_temperature/software/.clang_complete

Lines changed: 0 additions & 52 deletions
This file was deleted.

interface_temperature/software/.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,6 @@
33
.vscode/c_cpp_properties.json
44
.vscode/launch.json
55
.vscode/ipch
6+
7+
# This file need to be ignore in order to avoid password leaks on Github.
8+
/src/private.hpp
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
2-
// See http://go.microsoft.com/fwlink/?LinkId=827846
3-
// for the documentation about the extensions.json format
4-
"recommendations": [
5-
"platformio.platformio-ide"
6-
]
7-
}
2+
// See http://go.microsoft.com/fwlink/?LinkId=827846
3+
// for the documentation about the extensions.json format
4+
"recommendations": [
5+
"platformio.platformio-ide"
6+
]
7+
}

interface_temperature/software/platformio.ini

Lines changed: 33 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,21 @@
1111
[env]
1212
monitor_speed = 115200
1313
framework = arduino
14-
15-
; [env:esp12e_ota]
16-
; platform = espressif8266
17-
; board = esp12e
18-
; lib_ignore = ESP32WebServer
19-
; ; Les paramètres ci-dessous permettent de upload en OTA
20-
; upload_protocol = espota
21-
; upload_port = 192.168.1.47
22-
; upload_flags =
23-
; --port=8266
24-
; --auth=ThisIsSecureNow
14+
; upload_port = COM40
15+
lib_deps =
16+
Adafruit NeoPixel
17+
WS2812FX
18+
UniversalTelegramBot
19+
ArduinoJson
20+
OneWire
21+
DallasTemperature
22+
ESP32WebServer
23+
; === For OTA ===
24+
upload_protocol = espota
25+
upload_port = 192.168.1.39
26+
upload_flags =
27+
--port=8266
28+
--auth=ThisIsSecureNow
2529

2630
[env:board_temp_domoticz_buzzer]
2731
build_flags =
@@ -41,6 +45,24 @@ platform = espressif8266
4145
board = esp12e
4246
lib_ignore = ESP32WebServer
4347

48+
[env:board_temp_telegram_buzzer]
49+
build_flags =
50+
-DESP8266
51+
-DBOARD_TEMP_TELEGRAM
52+
-DBOARD_TEMP_TELEGRAM_BUZZER
53+
platform = espressif8266
54+
board = esp12e
55+
lib_ignore = ESP32WebServer
56+
57+
[env:board_temp_telegram_relay]
58+
build_flags =
59+
-DESP8266
60+
-DBOARD_TEMP_TELEGRAM
61+
-DBOARD_TEMP_TELEGRAM_RELAY
62+
platform = espressif8266
63+
board = esp12e
64+
lib_ignore = ESP32WebServer
65+
4466
[env:board_ring]
4567
build_flags =
4668
-DESP32

0 commit comments

Comments
 (0)