Skip to content

Commit a024fda

Browse files
committed
fix(modem): Fixup the docs
1 parent 3a2acb4 commit a024fda

File tree

20 files changed

+45
-410
lines changed

20 files changed

+45
-410
lines changed

.github/workflows/modem__build-host-tests.yml

+4-2
Original file line numberDiff line numberDiff line change
@@ -108,11 +108,13 @@ jobs:
108108
steps:
109109
- name: Checkout esp-protocols
110110
uses: actions/checkout@v4
111+
- name: Compat check
111112
shell: bash
112113
run: |
113-
apt-get update -y
114-
apt-get install -y astyle
114+
sudo apt-get update -y
115+
sudo apt-get install -y astyle
115116
cd components/esp_modem
116117
find examples/ -type f -regex '.*/generate/.*\.\(hpp\|cpp\)' -exec ./scripts/generate.sh {} \;
117118
./scripts/generate.sh
119+
git diff --name-only
118120
git diff --quiet

components/esp_modem/command/include/cxx_include/esp_modem_command_library.hpp

-32
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
#include "cxx_include/esp_modem_dce_module.hpp"
1111
#include "cxx_include/esp_modem_types.hpp"
1212

13-
// --- ESP-MODEM command module starts here ---
1413
namespace esp_modem {
1514
namespace dce_commands {
1615

@@ -40,37 +39,6 @@ command_result generic_command(CommandableIf *t, const std::string &command,
4039
*/
4140

4241

43-
//
44-
//#define INT_IN(name) int name
45-
//#ifdef __cplusplus
46-
//#define STRING_IN(name) const std::string& name
47-
//#define STRING_OUT(name) std::string& name
48-
//#define BOOL_IN(name) const bool name
49-
//#define BOOL_OUT(name) bool& name
50-
//#define INT_OUT(name) int& name
51-
//#define INTEGER_LIST_IN(name) const int* name
52-
//#define STRUCT_OUT(struct_name, name) struct_name& name
53-
//#else
54-
//#define STRING_IN(name) const char* name
55-
//#define STRING_OUT(name) char* name
56-
//#define BOOL_IN(name) const bool name
57-
//#define BOOL_OUT(name) bool* name
58-
//#define INT_OUT(name) int* name
59-
//#define INTEGER_LIST_IN(name) const int* name
60-
//#define STRUCT_OUT(struct_name, name) esp_modem_ ## struct_name ## _t* name
61-
//#endif
62-
//
63-
//#define FORWARD_INT_IN(name) name
64-
//#define FORWARD_STRING_IN(name) name
65-
//#define FORWARD_STRING_OUT(name) name
66-
//#define FORWARD_BOOL_IN(name) name
67-
//#define FORWARD_BOOL_OUT(name) name
68-
//#define FORWARD_INT_OUT(name) name
69-
//#define FORWARD_INTEGER_LIST_IN(name) name
70-
//#define FORWARD_STRUCT_OUT(struct_name, name) name
71-
72-
// Utility to count arguments (works for up to two parameters here)
73-
7442

7543

7644
/**

components/esp_modem/command/include/cxx_include/esp_modem_dce_generic.hpp

-32
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
#pragma once
88

9-
// --- ESP-MODEM command module starts here ---
109
namespace esp_modem {
1110

1211
/**
@@ -33,37 +32,6 @@ class DCE : public DCE_T<GenericModule> {
3332
using DCE_T<GenericModule>::DCE_T;
3433

3534

36-
//
37-
//#define INT_IN(name) int name
38-
//#ifdef __cplusplus
39-
//#define STRING_IN(name) const std::string& name
40-
//#define STRING_OUT(name) std::string& name
41-
//#define BOOL_IN(name) const bool name
42-
//#define BOOL_OUT(name) bool& name
43-
//#define INT_OUT(name) int& name
44-
//#define INTEGER_LIST_IN(name) const int* name
45-
//#define STRUCT_OUT(struct_name, name) struct_name& name
46-
//#else
47-
//#define STRING_IN(name) const char* name
48-
//#define STRING_OUT(name) char* name
49-
//#define BOOL_IN(name) const bool name
50-
//#define BOOL_OUT(name) bool* name
51-
//#define INT_OUT(name) int* name
52-
//#define INTEGER_LIST_IN(name) const int* name
53-
//#define STRUCT_OUT(struct_name, name) esp_modem_ ## struct_name ## _t* name
54-
//#endif
55-
//
56-
//#define FORWARD_INT_IN(name) name
57-
//#define FORWARD_STRING_IN(name) name
58-
//#define FORWARD_STRING_OUT(name) name
59-
//#define FORWARD_BOOL_IN(name) name
60-
//#define FORWARD_BOOL_OUT(name) name
61-
//#define FORWARD_INT_OUT(name) name
62-
//#define FORWARD_INTEGER_LIST_IN(name) name
63-
//#define FORWARD_STRUCT_OUT(struct_name, name) name
64-
65-
// Utility to count arguments (works for up to two parameters here)
66-
6735

6836

6937

components/esp_modem/command/include/cxx_include/esp_modem_dce_module.hpp

-32
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
#include "esp_modem_dce_config.h"
1515

1616

17-
// --- ESP-MODEM command module starts here ---
1817
namespace esp_modem {
1918

2019
/**
@@ -114,37 +113,6 @@ class GenericModule: public ModuleIf {
114113
*/
115114

116115

117-
//
118-
//#define INT_IN(name) int name
119-
//#ifdef __cplusplus
120-
//#define STRING_IN(name) const std::string& name
121-
//#define STRING_OUT(name) std::string& name
122-
//#define BOOL_IN(name) const bool name
123-
//#define BOOL_OUT(name) bool& name
124-
//#define INT_OUT(name) int& name
125-
//#define INTEGER_LIST_IN(name) const int* name
126-
//#define STRUCT_OUT(struct_name, name) struct_name& name
127-
//#else
128-
//#define STRING_IN(name) const char* name
129-
//#define STRING_OUT(name) char* name
130-
//#define BOOL_IN(name) const bool name
131-
//#define BOOL_OUT(name) bool* name
132-
//#define INT_OUT(name) int* name
133-
//#define INTEGER_LIST_IN(name) const int* name
134-
//#define STRUCT_OUT(struct_name, name) esp_modem_ ## struct_name ## _t* name
135-
//#endif
136-
//
137-
//#define FORWARD_INT_IN(name) name
138-
//#define FORWARD_STRING_IN(name) name
139-
//#define FORWARD_STRING_OUT(name) name
140-
//#define FORWARD_BOOL_IN(name) name
141-
//#define FORWARD_BOOL_OUT(name) name
142-
//#define FORWARD_INT_OUT(name) name
143-
//#define FORWARD_INTEGER_LIST_IN(name) name
144-
//#define FORWARD_STRUCT_OUT(struct_name, name) name
145-
146-
// Utility to count arguments (works for up to two parameters here)
147-
148116

149117

150118

components/esp_modem/command/include/esp_modem_api.h

-39
Original file line numberDiff line numberDiff line change
@@ -14,45 +14,6 @@
1414
extern "C" {
1515
#endif
1616

17-
// --- ESP-MODEM command module starts here ---
18-
19-
//
20-
//#define INT_IN(name) int name
21-
//#ifdef __cplusplus
22-
//#define STRING_IN(name) const std::string& name
23-
//#define STRING_OUT(name) std::string& name
24-
//#define BOOL_IN(name) const bool name
25-
//#define BOOL_OUT(name) bool& name
26-
//#define INT_OUT(name) int& name
27-
//#define INTEGER_LIST_IN(name) const int* name
28-
//#define STRUCT_OUT(struct_name, name) struct_name& name
29-
//#else
30-
//#define STRING_IN(name) const char* name
31-
//#define STRING_OUT(name) char* name
32-
//#define BOOL_IN(name) const bool name
33-
//#define BOOL_OUT(name) bool* name
34-
//#define INT_OUT(name) int* name
35-
//#define INTEGER_LIST_IN(name) const int* name
36-
//#define STRUCT_OUT(struct_name, name) esp_modem_ ## struct_name ## _t* name
37-
//#endif
38-
//
39-
//#define FORWARD_INT_IN(name) name
40-
//#define FORWARD_STRING_IN(name) name
41-
//#define FORWARD_STRING_OUT(name) name
42-
//#define FORWARD_BOOL_IN(name) name
43-
//#define FORWARD_BOOL_OUT(name) name
44-
//#define FORWARD_INT_OUT(name) name
45-
//#define FORWARD_INTEGER_LIST_IN(name) name
46-
//#define FORWARD_STRUCT_OUT(struct_name, name) name
47-
48-
// Utility to count arguments (works for up to two parameters here)
49-
//#define STRING_IN(name) const char* name
50-
//#define STRING_OUT(name) char* name
51-
//#define BOOL_IN(name) const bool name
52-
//#define BOOL_OUT(name) bool* name
53-
//#define INT_OUT(name) int* name
54-
//#define INTEGER_LIST_IN(name) const int* name
55-
//#define STRUCT_OUT(struct_name, name) esp_modem_ ## struct_name ## _t* name
5617

5718

5819

components/esp_modem/command/src/esp_modem_modules.cpp

-32
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
#include "cxx_include/esp_modem_dce_module.hpp"
99
#include "cxx_include/esp_modem_dte.hpp"
1010

11-
// --- ESP-MODEM command module starts here ---
1211
namespace esp_modem {
1312

1413
GenericModule::GenericModule(std::shared_ptr<DTE> dte, const dce_config *config) :
@@ -17,37 +16,6 @@ GenericModule::GenericModule(std::shared_ptr<DTE> dte, const dce_config *config)
1716

1817

1918

20-
//
21-
//#define INT_IN(name) int name
22-
//#ifdef __cplusplus
23-
//#define STRING_IN(name) const std::string& name
24-
//#define STRING_OUT(name) std::string& name
25-
//#define BOOL_IN(name) const bool name
26-
//#define BOOL_OUT(name) bool& name
27-
//#define INT_OUT(name) int& name
28-
//#define INTEGER_LIST_IN(name) const int* name
29-
//#define STRUCT_OUT(struct_name, name) struct_name& name
30-
//#else
31-
//#define STRING_IN(name) const char* name
32-
//#define STRING_OUT(name) char* name
33-
//#define BOOL_IN(name) const bool name
34-
//#define BOOL_OUT(name) bool* name
35-
//#define INT_OUT(name) int* name
36-
//#define INTEGER_LIST_IN(name) const int* name
37-
//#define STRUCT_OUT(struct_name, name) esp_modem_ ## struct_name ## _t* name
38-
//#endif
39-
//
40-
//#define FORWARD_INT_IN(name) name
41-
//#define FORWARD_STRING_IN(name) name
42-
//#define FORWARD_STRING_OUT(name) name
43-
//#define FORWARD_BOOL_IN(name) name
44-
//#define FORWARD_BOOL_OUT(name) name
45-
//#define FORWARD_INT_OUT(name) name
46-
//#define FORWARD_INTEGER_LIST_IN(name) name
47-
//#define FORWARD_STRUCT_OUT(struct_name, name) name
48-
49-
// Utility to count arguments (works for up to two parameters here)
50-
5119

5220

5321

components/esp_modem/examples/modem_console/main/command/my_module_dce.cpp

-32
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
//#include "generate/esp_modem_command_declare.inc"
1919
#include "my_module_dce.hpp"
2020

21-
// --- ESP-MODEM command module starts here ---
2221
using namespace esp_modem;
2322

2423
//
@@ -33,37 +32,6 @@ using namespace esp_modem;
3332
//
3433

3534

36-
//
37-
//#define INT_IN(name) int name
38-
//#ifdef __cplusplus
39-
//#define STRING_IN(name) const std::string& name
40-
//#define STRING_OUT(name) std::string& name
41-
//#define BOOL_IN(name) const bool name
42-
//#define BOOL_OUT(name) bool& name
43-
//#define INT_OUT(name) int& name
44-
//#define INTEGER_LIST_IN(name) const int* name
45-
//#define STRUCT_OUT(struct_name, name) struct_name& name
46-
//#else
47-
//#define STRING_IN(name) const char* name
48-
//#define STRING_OUT(name) char* name
49-
//#define BOOL_IN(name) const bool name
50-
//#define BOOL_OUT(name) bool* name
51-
//#define INT_OUT(name) int* name
52-
//#define INTEGER_LIST_IN(name) const int* name
53-
//#define STRUCT_OUT(struct_name, name) esp_modem_ ## struct_name ## _t* name
54-
//#endif
55-
//
56-
//#define FORWARD_INT_IN(name) name
57-
//#define FORWARD_STRING_IN(name) name
58-
//#define FORWARD_STRING_OUT(name) name
59-
//#define FORWARD_BOOL_IN(name) name
60-
//#define FORWARD_BOOL_OUT(name) name
61-
//#define FORWARD_INT_OUT(name) name
62-
//#define FORWARD_INTEGER_LIST_IN(name) name
63-
//#define FORWARD_STRUCT_OUT(struct_name, name) name
64-
65-
// Utility to count arguments (works for up to two parameters here)
66-
6735

6836

6937
//DECLARE_ALL_COMMAND_APIS(return_type name(...) )

components/esp_modem/examples/modem_console/main/command/my_module_dce.hpp

-32
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#include "cxx_include/esp_modem_dce_factory.hpp"
1717
#include "cxx_include/esp_modem_dce_module.hpp"
1818

19-
// --- ESP-MODEM command module starts here ---
2019
/**
2120
* @brief Definition of a custom DCE uses GenericModule and all its methods
2221
* but could override command processing. Here, for demonstration purposes only,
@@ -54,37 +53,6 @@ class DCE : public esp_modem::DCE_T<GenericModule>, public CommandableIf {
5453

5554

5655

57-
//
58-
//#define INT_IN(name) int name
59-
//#ifdef __cplusplus
60-
//#define STRING_IN(name) const std::string& name
61-
//#define STRING_OUT(name) std::string& name
62-
//#define BOOL_IN(name) const bool name
63-
//#define BOOL_OUT(name) bool& name
64-
//#define INT_OUT(name) int& name
65-
//#define INTEGER_LIST_IN(name) const int* name
66-
//#define STRUCT_OUT(struct_name, name) struct_name& name
67-
//#else
68-
//#define STRING_IN(name) const char* name
69-
//#define STRING_OUT(name) char* name
70-
//#define BOOL_IN(name) const bool name
71-
//#define BOOL_OUT(name) bool* name
72-
//#define INT_OUT(name) int* name
73-
//#define INTEGER_LIST_IN(name) const int* name
74-
//#define STRUCT_OUT(struct_name, name) esp_modem_ ## struct_name ## _t* name
75-
//#endif
76-
//
77-
//#define FORWARD_INT_IN(name) name
78-
//#define FORWARD_STRING_IN(name) name
79-
//#define FORWARD_STRING_OUT(name) name
80-
//#define FORWARD_BOOL_IN(name) name
81-
//#define FORWARD_BOOL_OUT(name) name
82-
//#define FORWARD_INT_OUT(name) name
83-
//#define FORWARD_INTEGER_LIST_IN(name) name
84-
//#define FORWARD_STRUCT_OUT(struct_name, name) name
85-
86-
// Utility to count arguments (works for up to two parameters here)
87-
8856

8957

9058
// DECLARE_ALL_COMMAND_APIS(forwards name(...))

components/esp_modem/examples/modem_tcp_client/main/command/sock_commands.hpp

-32
Original file line numberDiff line numberDiff line change
@@ -13,38 +13,6 @@
1313

1414
namespace sock_commands {
1515

16-
// --- ESP-MODEM command module starts here ---
17-
18-
//
19-
//#define INT_IN(name) int name
20-
//#ifdef __cplusplus
21-
//#define STRING_IN(name) const std::string& name
22-
//#define STRING_OUT(name) std::string& name
23-
//#define BOOL_IN(name) const bool name
24-
//#define BOOL_OUT(name) bool& name
25-
//#define INT_OUT(name) int& name
26-
//#define INTEGER_LIST_IN(name) const int* name
27-
//#define STRUCT_OUT(struct_name, name) struct_name& name
28-
//#else
29-
//#define STRING_IN(name) const char* name
30-
//#define STRING_OUT(name) char* name
31-
//#define BOOL_IN(name) const bool name
32-
//#define BOOL_OUT(name) bool* name
33-
//#define INT_OUT(name) int* name
34-
//#define INTEGER_LIST_IN(name) const int* name
35-
//#define STRUCT_OUT(struct_name, name) esp_modem_ ## struct_name ## _t* name
36-
//#endif
37-
//
38-
//#define FORWARD_INT_IN(name) name
39-
//#define FORWARD_STRING_IN(name) name
40-
//#define FORWARD_STRING_OUT(name) name
41-
//#define FORWARD_BOOL_IN(name) name
42-
//#define FORWARD_BOOL_OUT(name) name
43-
//#define FORWARD_INT_OUT(name) name
44-
//#define FORWARD_INTEGER_LIST_IN(name) name
45-
//#define FORWARD_STRUCT_OUT(struct_name, name) name
46-
47-
// Utility to count arguments (works for up to two parameters here)
4816

4917

5018

0 commit comments

Comments
 (0)