Project

General

Profile

DotMatrixDisplay » History » Version 10

Frédéric Blanc, 2020-04-17 17:24

1 1 Frédéric Blanc
h1. DotMatrixDisplay
2
3
h2. Hardware
4
5
https://majicdesigns.github.io/MD_MAX72XX/page_f_c16.html
6
7 9 Frédéric Blanc
<pre><code>
8 1 Frédéric Blanc
// ESP8266 PIN configuration
9
#define HARDWARE_TYPE MD_MAX72XX::FC16_HW       //PAROLA_HW GENERIC_HW ICSTATION_HW
10
#define CLK_PIN   D5  // Matrix CLK
11
#define DATA_PIN  D7  // Matrix DIN
12
#define CS_PIN    D6  // Matrix DS
13 9 Frédéric Blanc
</code></pre>
14 1 Frédéric Blanc
15 4 Frédéric Blanc
h2. Software
16
17
code exemple
18
http://sarakha63-domotique.fr/afficheur-led-matrixled-jeedom/
19
20
https://github.com/MajicDesigns/MD_Parola
21
22 5 Frédéric Blanc
version light
23
24
document:"code light DotMatrixDisplay"
25
26 6 Frédéric Blanc
27
mise a jour du code ArduinoJson 5 -> ArduinoJson 6
28
29 7 Frédéric Blanc
<pre><code>
30 6 Frédéric Blanc
// ArduinoJson 5
31 10 Frédéric Blanc
//StaticJsonBuffer<512> jsonBuffer;
32
//JsonObject& root = jsonBuffer.parseObject((char*)payloadcopy);
33
//if (!root.success()) {
34
// ArduinoJson 6
35 6 Frédéric Blanc
  DynamicJsonDocument root(1024);
36
  DeserializationError error = deserializeJson(root, (char*)payloadcopy);
37
  // Test if parsing succeeds.
38
  if (error){
39 7 Frédéric Blanc
</code></pre>
40 6 Frédéric Blanc
41 8 Frédéric Blanc
h3. To Do
42
43
rendre la configuration MQTT dynamique
44
45 1 Frédéric Blanc
h2. MQTT
46
47 2 Frédéric Blanc
topic: DotMatrixDisplay/message
48
49 1 Frédéric Blanc
{"text":"ABC°€",
50
"priorite":0,
51
"lum":1,
52
"pos":2,
53
"eff_in":9,
54
"eff_out":9,
55
"speed":1000,
56
"pause":100}
57 3 Frédéric Blanc
58
{"text":"Bonjour tous le monde",
59
"priorite":0,
60
"lum":1,
61
"pos":1,
62
"eff_in":1,
63
"eff_out":9,
64
"speed":50,
65
"pause":100}