void LOGGER_init__(LOGGER *data__, BOOL retain) {
  __INIT_VAR(data__->EN,__BOOL_LITERAL(TRUE),retain)
  __INIT_VAR(data__->ENO,__BOOL_LITERAL(TRUE),retain)
  __INIT_VAR(data__->TRIG,__BOOL_LITERAL(FALSE),retain)
  __INIT_VAR(data__->MSG,__STRING_LITERAL(0,""),retain)
  __INIT_VAR(data__->LEVEL,LOGLEVEL__INFO,retain)
  __INIT_VAR(data__->TRIG0,__BOOL_LITERAL(FALSE),retain)
}

// Code part
void LOGGER_body__(LOGGER *data__) {
  // Control execution
  if (!__GET_VAR(data__->EN)) {
    __SET_VAR(data__->,ENO,,__BOOL_LITERAL(FALSE));
    return;
  }
  else {
    __SET_VAR(data__->,ENO,,__BOOL_LITERAL(TRUE));
  }
  // Initialise TEMP variables

  if ((__GET_VAR(data__->TRIG,) && !(__GET_VAR(data__->TRIG0,)))) {
    #define GetFbVar(var,...) __GET_VAR(data__->var,__VA_ARGS__)
    #define SetFbVar(var,val,...) __SET_VAR(data__->,var,__VA_ARGS__,val)

   LogMessage(GetFbVar(LEVEL),(char*)GetFbVar(MSG, .body),GetFbVar(MSG, .len));
  
    #undef GetFbVar
    #undef SetFbVar
;
  };
  __SET_VAR(data__->,TRIG0,,__GET_VAR(data__->TRIG,));

  goto __end;

__end:
  return;
} // LOGGER_body__() 





void ANALOGIN_init__(ANALOGIN *data__, BOOL retain) {
  __INIT_LOCATED(BOOL,__QX0_0,data__->PL0_0,retain)
  __INIT_LOCATED_VALUE(data__->PL0_0,__BOOL_LITERAL(FALSE))
  __INIT_LOCATED(BOOL,__QX0_1,data__->PL0_1,retain)
  __INIT_LOCATED_VALUE(data__->PL0_1,__BOOL_LITERAL(FALSE))
  __INIT_LOCATED(BOOL,__QX0_2,data__->PL0_2,retain)
  __INIT_LOCATED_VALUE(data__->PL0_2,__BOOL_LITERAL(FALSE))
  __INIT_LOCATED(BOOL,__QX0_3,data__->PL1_0,retain)
  __INIT_LOCATED_VALUE(data__->PL1_0,__BOOL_LITERAL(FALSE))
  __INIT_LOCATED(BOOL,__QX0_4,data__->PL1_1,retain)
  __INIT_LOCATED_VALUE(data__->PL1_1,__BOOL_LITERAL(FALSE))
  __INIT_LOCATED(BOOL,__QX0_5,data__->PL1_2,retain)
  __INIT_LOCATED_VALUE(data__->PL1_2,__BOOL_LITERAL(FALSE))
  __INIT_LOCATED(UINT,__IW0,data__->ANAIN0,retain)
  __INIT_LOCATED_VALUE(data__->ANAIN0,0)
  __INIT_LOCATED(UINT,__IW1,data__->ANAIN1,retain)
  __INIT_LOCATED_VALUE(data__->ANAIN1,0)
  __INIT_VAR(data__->_TMP_GE1_OUT,__BOOL_LITERAL(FALSE),retain)
  __INIT_VAR(data__->_TMP_GE6_OUT,__BOOL_LITERAL(FALSE),retain)
  __INIT_VAR(data__->_TMP_GE11_OUT,__BOOL_LITERAL(FALSE),retain)
  __INIT_VAR(data__->_TMP_LE16_OUT,__BOOL_LITERAL(FALSE),retain)
  __INIT_VAR(data__->_TMP_LT21_OUT,__BOOL_LITERAL(FALSE),retain)
  __INIT_VAR(data__->_TMP_LT26_OUT,__BOOL_LITERAL(FALSE),retain)
}

// Code part
void ANALOGIN_body__(ANALOGIN *data__) {
  // Initialise TEMP variables

  __SET_VAR(data__->,_TMP_GE1_OUT,,GE__BOOL__UINT(
    (BOOL)__BOOL_LITERAL(TRUE),
    NULL,
    (UINT)2,
    (UINT)__GET_LOCATED(data__->ANAIN0,),
    (UINT)__UINT_LITERAL(0x4000)));
  __SET_LOCATED(data__->,PL0_0,,__GET_VAR(data__->_TMP_GE1_OUT,));
  __SET_VAR(data__->,_TMP_GE6_OUT,,GE__BOOL__UINT(
    (BOOL)__BOOL_LITERAL(TRUE),
    NULL,
    (UINT)2,
    (UINT)__GET_LOCATED(data__->ANAIN0,),
    (UINT)__UINT_LITERAL(0x8000)));
  __SET_LOCATED(data__->,PL0_1,,__GET_VAR(data__->_TMP_GE6_OUT,));
  __SET_VAR(data__->,_TMP_GE11_OUT,,GE__BOOL__UINT(
    (BOOL)__BOOL_LITERAL(TRUE),
    NULL,
    (UINT)2,
    (UINT)__GET_LOCATED(data__->ANAIN0,),
    (UINT)__UINT_LITERAL(0xC000)));
  __SET_LOCATED(data__->,PL0_2,,__GET_VAR(data__->_TMP_GE11_OUT,));
  __SET_VAR(data__->,_TMP_LE16_OUT,,LE__BOOL__UINT(
    (BOOL)__BOOL_LITERAL(TRUE),
    NULL,
    (UINT)2,
    (UINT)__GET_LOCATED(data__->ANAIN1,),
    (UINT)__UINT_LITERAL(0x4000)));
  __SET_LOCATED(data__->,PL1_0,,__GET_VAR(data__->_TMP_LE16_OUT,));
  __SET_VAR(data__->,_TMP_LT21_OUT,,LT__BOOL__UINT(
    (BOOL)__BOOL_LITERAL(TRUE),
    NULL,
    (UINT)2,
    (UINT)__GET_LOCATED(data__->ANAIN1,),
    (UINT)__UINT_LITERAL(0x8000)));
  __SET_LOCATED(data__->,PL1_1,,__GET_VAR(data__->_TMP_LT21_OUT,));
  __SET_VAR(data__->,_TMP_LT26_OUT,,LT__BOOL__UINT(
    (BOOL)__BOOL_LITERAL(TRUE),
    NULL,
    (UINT)2,
    (UINT)__GET_LOCATED(data__->ANAIN1,),
    (UINT)__UINT_LITERAL(0xC000)));
  __SET_LOCATED(data__->,PL1_2,,__GET_VAR(data__->_TMP_LT26_OUT,));

  goto __end;

__end:
  return;
} // ANALOGIN_body__() 





