image thumbnail
from Code Coverage Tool by Mark Walker
Code Coverage Tool measures C statement coverage in generated code.

rtwtypes_h.html
RTW Report - rtwtypes.h

File: c:\projects\cov\tst9a\controller_model_ert_rtw\rtwtypes.h

    1   /*
    2    * File: rtwtypes.h
    3    *
    4    * Definitions required by Real-Time Workshop generated code.
    5    *
    6    * Real-Time Workshop version: 7.2
    7    * Generated on: 2009-05-14 12:41:20
    8    */
    9   
   10   #ifndef __RTWTYPES_H__
   11   #define __RTWTYPES_H__
   12   #ifndef TRUE
   13   # define TRUE                          (1U)
   14   #endif
   15   
   16   #ifndef FALSE
   17   # define FALSE                         (0U)
   18   #endif
   19   
   20   #ifndef __TMWTYPES__
   21   #define __TMWTYPES__
   22   #include <limits.h>
   23   
   24   /*=======================================================================*
   25    * Target hardware information
   26    *   Device type: 32-bit Generic
   27    *   Number of bits:     char:   8    short:   16    int:  32
   28    *                       long:  32      native word size:  32
   29    *   Byte ordering: Unspecified
   30    *   Signed integer division rounds to: Undefined
   31    *   Shift right on a signed integer as arithmetic shift: on
   32    *=======================================================================*/
   33   
   34   /*=======================================================================*
   35    * Fixed width word size data types:                                     *
   36    *   int8_T, int16_T, int32_T     - signed 8, 16, or 32 bit integers     *
   37    *   uint8_T, uint16_T, uint32_T  - unsigned 8, 16, or 32 bit integers   *
   38    *   real32_T, real64_T           - 32 and 64 bit floating point numbers *
   39    *=======================================================================*/
   40   typedef signed char int8_T;
   41   typedef unsigned char uint8_T;
   42   typedef short int16_T;
   43   typedef unsigned short uint16_T;
   44   typedef int int32_T;
   45   typedef unsigned int uint32_T;
   46   typedef float real32_T;
   47   typedef double real64_T;
   48   
   49   /*===========================================================================*
   50    * Generic type definitions: real_T, time_T, boolean_T, int_T, uint_T,       *
   51    *                           ulong_T, char_T and byte_T.                     *
   52    *===========================================================================*/
   53   typedef double real_T;
   54   typedef double time_T;
   55   typedef unsigned char boolean_T;
   56   typedef int int_T;
   57   typedef unsigned int uint_T;
   58   typedef unsigned long ulong_T;
   59   typedef char char_T;
   60   typedef char_T byte_T;
   61   
   62   /*===========================================================================*
   63    * Complex number type definitions                                           *
   64    *===========================================================================*/
   65   #define CREAL_T
   66   
   67   typedef struct {
   68     real32_T re;
   69     real32_T im;
   70   } creal32_T;
   71   
   72   typedef struct {
   73     real64_T re;
   74     real64_T im;
   75   } creal64_T;
   76   
   77   typedef struct {
   78     real_T re;
   79     real_T im;
   80   } creal_T;
   81   
   82   typedef struct {
   83     int8_T re;
   84     int8_T im;
   85   } cint8_T;
   86   
   87   typedef struct {
   88     uint8_T re;
   89     uint8_T im;
   90   } cuint8_T;
   91   
   92   typedef struct {
   93     int16_T re;
   94     int16_T im;
   95   } cint16_T;
   96   
   97   typedef struct {
   98     uint16_T re;
   99     uint16_T im;
  100   } cuint16_T;
  101   
  102   typedef struct {
  103     int32_T re;
  104     int32_T im;
  105   } cint32_T;
  106   
  107   typedef struct {
  108     uint32_T re;
  109     uint32_T im;
  110   } cuint32_T;
  111   
  112   /*=======================================================================*
  113    * Min and Max:                                                          *
  114    *   int8_T, int16_T, int32_T     - signed 8, 16, or 32 bit integers     *
  115    *   uint8_T, uint16_T, uint32_T  - unsigned 8, 16, or 32 bit integers   *
  116    *=======================================================================*/
  117   #define MAX_int8_T                     ((int8_T)(127))
  118   #define MIN_int8_T                     ((int8_T)(-128))
  119   #define MAX_uint8_T                    ((uint8_T)(255U))
  120   #define MIN_uint8_T                    ((uint8_T)(0U))
  121   #define MAX_int16_T                    ((int16_T)(32767))
  122   #define MIN_int16_T                    ((int16_T)(-32768))
  123   #define MAX_uint16_T                   ((uint16_T)(65535U))
  124   #define MIN_uint16_T                   ((uint16_T)(0U))
  125   #define MAX_int32_T                    ((int32_T)(2147483647))
  126   #define MIN_int32_T                    ((int32_T)(-2147483647-1))
  127   #define MAX_uint32_T                   ((uint32_T)(0xFFFFFFFFU))
  128   #define MIN_uint32_T                   ((uint32_T)(0U))
  129   
  130   /* Logical type definitions */
  131   #if !defined(__cplusplus) && !defined(__true_false_are_keywords)
  132   #  ifndef false
  133   #   define false                       (0U)
  134   #  endif
  135   
  136   #  ifndef true
  137   #   define true                        (1U)
  138   #  endif
  139   #endif
  140   
  141   /*
  142    * Real-Time Workshop assumes the code is compiled on a target using a 2's compliment representation
  143    * for signed integer values.
  144    */
  145   #if ((SCHAR_MIN + 1) != -SCHAR_MAX)
  146   #error "This code must be compiled using a 2's complement representation for signed integer values"
  147   #endif
  148   
  149   /*
  150    * Maximum length of a MATLAB identifier (function/variable/model)
  151    * including the null-termination character. Referenced by
  152    * rt_logging.c and rt_matrx.c.
  153    */
  154   #define TMW_NAME_LENGTH_MAX            64
  155   
  156   /* This ID is used to detect inclusion of an incompatible rtwtypes.h */
  157   #define RTWTYPES_ID_C08S16I32L32N32F1
  158   #else                                  /* __TMWTYPES__ */
  159   #define TMWTYPES_PREVIOUSLY_INCLUDED
  160   #endif                                 /* __TMWTYPES__ */
  161   
  162   /* Block D-Work pointer type */
  163   typedef void * pointer_T;
  164   
  165   /* Simulink specific types */
  166   #ifndef __SIMSTRUC_TYPES_H__
  167   #define __SIMSTRUC_TYPES_H__
  168   
  169   /* States of an enabled subsystem */
  170   typedef enum {
  171     SUBSYS_DISABLED = 0,
  172     SUBSYS_ENABLED = 2,
  173     SUBSYS_BECOMING_DISABLED = 4,
  174     SUBSYS_BECOMING_ENABLED = 8,
  175     SUBSYS_TRIGGERED = 16
  176   } CondStates;
  177   
  178   /* Trigger directions: falling, either, and rising */
  179   typedef enum {
  180     FALLING_ZERO_CROSSING = -1,
  181     ANY_ZERO_CROSSING = 0,
  182     RISING_ZERO_CROSSING = 1
  183   } ZCDirection;
  184   
  185   /* Previous state of a trigger signal */
  186   typedef uint8_T ZCSigState;
  187   
  188   /* Initial value of a trigger zero crossing signal */
  189   #define UNINITIALIZED_ZCSIG            0x03U
  190   #define NEG_ZCSIG                      0x02U
  191   #define POS_ZCSIG                      0x01U
  192   #define ZERO_ZCSIG                     0x00U
  193   
  194   /* Current state of a trigger signal */
  195   typedef enum {
  196     FALLING_ZCEVENT = -1,
  197     NO_ZCEVENT = 0,
  198     RISING_ZCEVENT = 1
  199   } ZCEventType;
  200   
  201   /* Enumeration of built-in data types */
  202   typedef enum {
  203     SS_DOUBLE = 0,                       /* real_T    */
  204     SS_SINGLE = 1,                       /* real32_T  */
  205     SS_INT8 = 2,                         /* int8_T    */
  206     SS_UINT8 = 3,                        /* uint8_T   */
  207     SS_INT16 = 4,                        /* int16_T   */
  208     SS_UINT16 = 5,                       /* uint16_T  */
  209     SS_INT32 = 6,                        /* int32_T   */
  210     SS_UINT32 = 7,                       /* uint32_T  */
  211     SS_BOOLEAN = 8                       /* boolean_T */
  212   } BuiltInDTypeId;
  213   
  214   #define SS_NUM_BUILT_IN_DTYPE          ((int_T)SS_BOOLEAN+1)
  215   
  216   typedef int_T DTypeId;
  217   
  218   #endif                                 /* __SIMSTRUC_TYPES_H__ */
  219   #endif                                 /* __RTWTYPES_H__ */

Contact us at files@mathworks.com