Revision f3ac1c96 core/inc/aos_shell.h

View differences:

core/inc/aos_shell.h
32 32
#include <hal.h>
33 33
#include <aos_types.h>
34 34
#include <aos_debug.h>
35
/******************************************************************************/
36
/* CONSTANTS                                                                  */
37
/******************************************************************************/
35 38

  
36 39
/**
37 40
 * @brief   Shell event flag that is emitted when the thread starts.
......
98 101
 */
99 102
#define AOS_SHELLCHANNEL_OUTPUT_ENABLED           (1 << 2)
100 103

  
101
/*
102
 * forward definitions
103
 */
104
typedef struct aos_shellchannel AosShellChannel;
105
typedef struct aos_shellstream AosShellStream;
104
/******************************************************************************/
105
/* SETTINGS                                                                   */
106
/******************************************************************************/
107

  
108
/******************************************************************************/
109
/* CHECKS                                                                     */
110
/******************************************************************************/
111

  
112
/******************************************************************************/
113
/* DATA STRUCTURES AND TYPES                                                  */
114
/******************************************************************************/
106 115

  
107 116
/**
108 117
 * @brief   AosShellChannel specific methods.
......
119 128
  /* event listener for the associated BaseAsynchronousChannel */           \
120 129
  event_listener_t listener;                                                \
121 130
  /* pointer to the next chennal in a AosShellStream */                     \
122
  AosShellChannel* next;                                                    \
131
  struct aos_shellchannel* next;                                            \
123 132
  /* flags related to the channel */                                        \
124 133
  uint8_t flags;
125 134

  
......
138 147
 * @brief   Shell channel class.
139 148
 * @details This class implements an asynchronous I/O channel.
140 149
 */
141
struct aos_shellchannel {
150
typedef struct aos_shellchannel {
142 151
  /** @brief Virtual Methods Table. */
143 152
  const struct AosShellChannelVMT* vmt;
144 153
  _aos_shell_channel_data
145
};
154
} AosShellChannel;
146 155

  
147 156
/**
148 157
 * @brief   AosShellStream methods.
......
173 182
 * @details This class implements an base sequential stream.
174 183
 * @todo    So far only output but no input is supported.
175 184
 */
176
struct aos_shellstream {
185
typedef struct aos_shellstream {
177 186
  const struct AosShellStreamVMT* vmt;
178 187
  _aos_shellstream_data
179
};
188
} AosShellStream;
180 189

  
181 190
/**
182 191
 * @brief   Shell command calback type.
......
351 360
  uint8_t config;
352 361
} aos_shell_t;
353 362

  
363
/******************************************************************************/
364
/* MACROS                                                                     */
365
/******************************************************************************/
366

  
367
/******************************************************************************/
368
/* EXTERN DECLARATIONS                                                        */
369
/******************************************************************************/
370

  
354 371
#ifdef __cplusplus
355 372
extern "C" {
356 373
#endif
......
371 388
}
372 389
#endif
373 390

  
391
/******************************************************************************/
392
/* INLINE FUNCTIONS                                                           */
393
/******************************************************************************/
394

  
374 395
#endif /* (AMIROOS_CFG_SHELL_ENABLE == true) || (AMIROOS_CFG_TESTS_ENABLE == true) */
375 396

  
376 397
#endif /* AMIROOS_SHELL_H */

Also available in: Unified diff