Revision 933df08e os/core/inc/aos_system.h

View differences:

os/core/inc/aos_system.h
58 58
/**
59 59
 * @brief   Major version of the implemented SSSP.
60 60
 */
61
#define AOS_SYSTEM_SSSP_MAJOR                   1
61
#define AOS_SYSTEM_SSSP_VERSION_MAJOR           1
62 62

  
63 63
/**
64 64
 * @brief   Minor version of the implemented SSSP.
65 65
 */
66
#define AOS_SYSTEM_SSSP_MINOR                   3
66
#define AOS_SYSTEM_SSSP_VERSION_MINOR           4
67

  
68
/**
69
 * @brief   Timeout delay according to SSSP.
70
 * @details SSSP defines timeouts to be ten times longer than the signal delay time.
71
 */
72
#define AOS_SYSTEM_SSSP_TIMEOUT                 (10 * AMIROOS_CFG_SSSP_SIGNALDELAY)
67 73

  
68 74
/**
69 75
 * @brief   Enumerator to identify shutdown types.
......
78 84
} aos_shutdown_t;
79 85

  
80 86
/**
81
 * @brief   Enumerator of the several stages of SSSP
87
 * @brief   Enumerator of the several stages of SSSP.
82 88
 */
83 89
typedef enum aos_ssspstage {
84
  AOS_SSSP_STARTUP_1_1  = 0x0000, /**< Identifier of SSSP startup phase stage 1-1. */
85
  AOS_SSSP_STARTUP_1_2  = 0x0001, /**< Identifier of SSSP startup phase stage 1-2. */
86
  AOS_SSSP_STARTUP_1_3  = 0x0002, /**< Identifier of SSSP startup phase stage 1-3. */
87
  AOS_SSSP_STARTUP_2_1  = 0x0004, /**< Identifier of SSSP startup phase stage 2-1. */
88
  AOS_SSSP_STARTUP_2_2  = 0x0005, /**< Identifier of SSSP startup phase stage 2-2. */
89
  AOS_SSSP_STARTUP_3_1  = 0x0008, /**< Identifier of SSSP startup phase stage 3-1. */
90
  AOS_SSSP_STARTUP_3_2  = 0x0009, /**< Identifier of SSSP startup phase stage 3-2. */
91
  AOS_SSSP_STARTUP_3_3  = 0x000A, /**< Identifier of SSSP startup phase stage 3-3. */
92
  AOS_SSSP_STARTUP_3_4  = 0x000B, /**< Identifier of SSSP startup phase stage 3-4. */
93
  AOS_SSSP_OPERATION    = 0x0100, /**< Identifier of SSSP operation pahse. */
94
  AOS_SSSP_SHUTDOWN_1_1 = 0x0200, /**< Identifier of SSSP shutdown phase stage 1-1. */
95
  AOS_SSSP_SHUTDOWN_1_2 = 0x0201, /**< Identifier of SSSP shutdown phase stage 1-2. */
96
  AOS_SSSP_SHUTDOWN_1_3 = 0x0202, /**< Identifier of SSSP shutdown phase stage 1-3. */
97
  AOS_SSSP_SHUTDOWN_2_1 = 0x0204, /**< Identifier of SSSP shutdown phase stage 2-1. */
98
  AOS_SSSP_SHUTDOWN_2_2 = 0x0205, /**< Identifier of SSSP shutdown phase stage 2-2. */
99
  AOS_SSSP_SHUTDOWN_3   = 0x0208, /**< Identifier of SSSP shutdown phase stage 3. */
90
  AOS_SSSP_STARTUP_1_1  = 0x10, /**< Identifier of SSSP startup phase stage 1-1. */
91
  AOS_SSSP_STARTUP_1_2  = 0x11, /**< Identifier of SSSP startup phase stage 1-2. */
92
  AOS_SSSP_STARTUP_1_3  = 0x12, /**< Identifier of SSSP startup phase stage 1-3. */
93
  AOS_SSSP_STARTUP_2_1  = 0x14, /**< Identifier of SSSP startup phase stage 2-1. */
94
  AOS_SSSP_STARTUP_2_2  = 0x15, /**< Identifier of SSSP startup phase stage 2-2. */
95
  AOS_SSSP_STARTUP_3_1  = 0x18, /**< Identifier of SSSP startup phase stage 3-1. */
96
  AOS_SSSP_STARTUP_3_2  = 0x19, /**< Identifier of SSSP startup phase stage 3-2. */
97
  AOS_SSSP_STARTUP_3_3  = 0x1A, /**< Identifier of SSSP startup phase stage 3-3. */
98
  AOS_SSSP_STARTUP_3_4  = 0x1B, /**< Identifier of SSSP startup phase stage 3-4. */
99
  AOS_SSSP_OPERATION    = 0x20, /**< Identifier of SSSP operation pahse. */
100
  AOS_SSSP_SHUTDOWN_1_1 = 0x30, /**< Identifier of SSSP shutdown phase stage 1-1. */
101
  AOS_SSSP_SHUTDOWN_1_2 = 0x31, /**< Identifier of SSSP shutdown phase stage 1-2. */
102
  AOS_SSSP_SHUTDOWN_1_3 = 0x32, /**< Identifier of SSSP shutdown phase stage 1-3. */
103
  AOS_SSSP_SHUTDOWN_2_1 = 0x34, /**< Identifier of SSSP shutdown phase stage 2-1. */
104
  AOS_SSSP_SHUTDOWN_2_2 = 0x35, /**< Identifier of SSSP shutdown phase stage 2-2. */
105
  AOS_SSSP_SHUTDOWN_3   = 0x38, /**< Identifier of SSSP shutdown phase stage 3. */
100 106
} aos_ssspstage_t;
101 107

  
102 108
/**
109
 * @brief   Type to represent module IDs.
110
 */
111
typedef uint16_t aos_ssspmoduleid_t;
112

  
113
/**
103 114
 * @brief   AMiRo-OS base system structure.
104 115
 */
105 116
typedef struct aos_system {
......
112 123
     * @brief   Current SSSP stage of the system.
113 124
     */
114 125
    aos_ssspstage_t stage;
126

  
127
    /**
128
     * @brief   Module identifier.
129
     * @details A value of 0 indicates an uninitialized ID.
130
     *          The vlaues 0 and ~0 are reserved und must not be set.
131
     */
132
    aos_ssspmoduleid_t moduleId;
115 133
  } sssp;
116 134

  
117 135
  /**
......
151 169

  
152 170
/**
153 171
 * @brief   Printf function that uses the default system I/O stream.
172
 *
173
 * @param[in] fmt   Formatted string to print.
154 174
 */
155 175
#define aosprintf(fmt, ...)                     chprintf((BaseSequentialStream*)&aos.iostream, fmt, ##__VA_ARGS__)
156 176

  

Also available in: Unified diff