22 * @file oscclientparamsconst.h
33 *
44 */
5- /* Copyright (C) 2025 by Arjan van Vught mailto:info@gd32-dmx.org
6- *
7- * Permission is hereby granted, free of charge, to any person obtaining a copy
8- * of this software and associated documentation files (the "Software"), to deal
9- * in the Software without restriction, including without limitation the rights
10- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11- * copies of the Software, and to permit persons to whom the Software is
12- * furnished to do so, subject to the following conditions:
5+ /* Copyright (C) 2025-2026 by Arjan van Vught mailto:info@gd32-dmx.org
6+ *
7+ * Permission is hereby granted, free of charge, to any person obtaining a copy
8+ * of this software and associated documentation files (the "Software"), to deal
9+ * in the Software without restriction, including without limitation the rights
10+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11+ * copies of the Software, and to permit persons to whom the Software is
12+ * furnished to do so, subject to the following conditions:
1313
14- * The above copyright notice and this permission notice shall be included in
15- * all copies or substantial portions of the Software.
14+ * The above copyright notice and this permission notice shall be included in
15+ * all copies or substantial portions of the Software.
1616
17- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
23- * THE SOFTWARE.
24- */
25-
17+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
23+ * THE SOFTWARE.
24+ */
2625
2726#ifndef JSON_OSCCLIENTPARAMSCONST_H_
2827#define JSON_OSCCLIENTPARAMSCONST_H_
2928
3029#include " json/json_key.h"
3130
32- namespace json
33- {
34- struct OscClientParamsConst
35- {
36- static constexpr char kFileName [] = " oscclient.json" ;
37-
38- static constexpr json::SimpleKey kServerIp {
39- " server_ip" ,
40- 9 ,
41- Fnv1a32 (" server_ip" , 9 )
42- };
43-
44- static constexpr json::SimpleKey kPingDisable {
45- " ping_disable" ,
46- 12 ,
47- Fnv1a32 (" ping_disable" , 12 )
48- };
49-
50- static constexpr json::SimpleKey kPingDelay {
51- " ping_delay" ,
52- 10 ,
53- Fnv1a32 (" ping_delay" , 10 )
54- };
31+ namespace json {
32+ struct OscClientParamsConst {
33+ static constexpr char kFileName [] = " oscclient.json" ;
34+
35+ static constexpr json::SimpleKey kServerIp {" server_ip" , 9 , Fnv1a32 (" server_ip" , 9 )};
36+ static constexpr json::SimpleKey kPingDisable {" ping_disable" , 12 , Fnv1a32 (" ping_disable" , 12 )};
37+ static constexpr json::SimpleKey kPingDelay {" ping_delay" , 10 , Fnv1a32 (" ping_delay" , 10 )};
5538
5639 static constexpr json::PortKey kCmd0 {" cmd0" , 4 , Fnv1a32 (" cmd0" , 4 )};
5740 static constexpr json::PortKey kCmd1 {" cmd1" , 4 , Fnv1a32 (" cmd1" , 4 )};
@@ -62,18 +45,10 @@ struct OscClientParamsConst
6245 static constexpr json::PortKey kCmd6 {" cmd6" , 4 , Fnv1a32 (" cmd6" , 4 )};
6346 static constexpr json::PortKey kCmd7 {" cmd7" , 4 , Fnv1a32 (" cmd7" , 4 )};
6447
65- static constexpr json::PortKey kCmd [] =
66- {
67- kCmd0 ,
68- kCmd1 ,
69- kCmd2 ,
70- kCmd3 ,
71- kCmd4 ,
72- kCmd5 ,
73- kCmd6 ,
74- kCmd7 ,
48+ static constexpr json::PortKey kCmd [] = {
49+ kCmd0 , kCmd1 , kCmd2 , kCmd3 , kCmd4 , kCmd5 , kCmd6 , kCmd7 ,
7550 };
76-
51+
7752 static constexpr json::PortKey kLed0 {" led0" , 4 , Fnv1a32 (" led0" , 4 )};
7853 static constexpr json::PortKey kLed1 {" led1" , 4 , Fnv1a32 (" led1" , 4 )};
7954 static constexpr json::PortKey kLed2 {" led2" , 4 , Fnv1a32 (" led2" , 4 )};
@@ -83,19 +58,10 @@ struct OscClientParamsConst
8358 static constexpr json::PortKey kLed6 {" led6" , 4 , Fnv1a32 (" led6" , 4 )};
8459 static constexpr json::PortKey kLed7 {" led7" , 4 , Fnv1a32 (" led7" , 4 )};
8560
86- static constexpr json::PortKey kLed [] =
87- {
88- kLed0 ,
89- kLed1 ,
90- kLed2 ,
91- kLed3 ,
92- kLed4 ,
93- kLed5 ,
94- kLed6 ,
95- kLed7 ,
61+ static constexpr json::PortKey kLed [] = {
62+ kLed0 , kLed1 , kLed2 , kLed3 , kLed4 , kLed5 , kLed6 , kLed7 ,
9663 };
97-
9864};
9965} // namespace json
10066
101- #endif // JSON_OSCCLIENTPARAMSCONST_H_
67+ #endif // JSON_OSCCLIENTPARAMSCONST_H_
0 commit comments