standard.h 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263
  1. /* Automation Studio Generated Header File, Format Version 1.00 */
  2. /* do not change */
  3. #ifndef STANDARD_H_
  4. #define STANDARD_H_
  5. #ifdef __cplusplus
  6. extern "C" {
  7. #endif
  8. #include <bur/plc.h>
  9. #define TP_10mstyp TP_10ms_typ
  10. #define TOF_10mstyp TOF_10ms_typ
  11. #define TON_10mstyp TON_10ms_typ
  12. #define TPtyp TP_typ
  13. #define TOFtyp TOF_typ
  14. #define TONtyp TON_typ
  15. #define SEMAtyp SEMA_typ
  16. #define RStyp RS_typ
  17. #define SRtyp SR_typ
  18. #define R_TRIGtyp R_TRIG_typ
  19. #define F_TRIGtyp F_TRIG_typ
  20. #define CTUtyp CTU_typ
  21. #define CTDtyp CTD_typ
  22. #define CTUDtyp CTUD_typ
  23. #define RF_TRIGtyp RF_TRIG_typ
  24. /* Constants */
  25. /* Datatypes */
  26. /* Datatypes of function blocks */
  27. typedef struct TP_10ms
  28. {
  29. /* VAR_INPUT (analogous) */
  30. unsigned long PT;
  31. /* VAR_OUTPUT (analogous) */
  32. unsigned long ET;
  33. /* VAR (analogous) */
  34. unsigned long StartTime;
  35. /* VAR_INPUT (digital) */
  36. plcbit IN;
  37. /* VAR_OUTPUT (digital) */
  38. plcbit Q;
  39. } TP_10ms_typ;
  40. typedef struct TOF_10ms
  41. {
  42. /* VAR_INPUT (analogous) */
  43. unsigned long PT;
  44. /* VAR_OUTPUT (analogous) */
  45. unsigned long ET;
  46. /* VAR (analogous) */
  47. unsigned long StartTime;
  48. /* VAR_INPUT (digital) */
  49. plcbit IN;
  50. /* VAR_OUTPUT (digital) */
  51. plcbit Q;
  52. /* VAR (digital) */
  53. plcbit M;
  54. } TOF_10ms_typ;
  55. typedef struct TON_10ms
  56. {
  57. /* VAR_INPUT (analogous) */
  58. unsigned long PT;
  59. /* VAR_OUTPUT (analogous) */
  60. unsigned long ET;
  61. /* VAR (analogous) */
  62. unsigned long StartTime;
  63. /* VAR_INPUT (digital) */
  64. plcbit IN;
  65. /* VAR_OUTPUT (digital) */
  66. plcbit Q;
  67. /* VAR (digital) */
  68. plcbit M;
  69. } TON_10ms_typ;
  70. typedef struct TP
  71. {
  72. /* VAR_INPUT (analogous) */
  73. plctime PT;
  74. /* VAR_OUTPUT (analogous) */
  75. plctime ET;
  76. /* VAR (analogous) */
  77. plctime StartTime;
  78. unsigned long Restart;
  79. /* VAR_INPUT (digital) */
  80. plcbit IN;
  81. /* VAR_OUTPUT (digital) */
  82. plcbit Q;
  83. } TP_typ;
  84. typedef struct TOF
  85. {
  86. /* VAR_INPUT (analogous) */
  87. plctime PT;
  88. /* VAR_OUTPUT (analogous) */
  89. plctime ET;
  90. /* VAR (analogous) */
  91. plctime StartTime;
  92. unsigned long Restart;
  93. /* VAR_INPUT (digital) */
  94. plcbit IN;
  95. /* VAR_OUTPUT (digital) */
  96. plcbit Q;
  97. /* VAR (digital) */
  98. plcbit M;
  99. } TOF_typ;
  100. typedef struct TON
  101. {
  102. /* VAR_INPUT (analogous) */
  103. plctime PT;
  104. /* VAR_OUTPUT (analogous) */
  105. plctime ET;
  106. /* VAR (analogous) */
  107. plctime StartTime;
  108. unsigned long Restart;
  109. /* VAR_INPUT (digital) */
  110. plcbit IN;
  111. /* VAR_OUTPUT (digital) */
  112. plcbit Q;
  113. /* VAR (digital) */
  114. plcbit M;
  115. } TON_typ;
  116. typedef struct SEMA
  117. {
  118. /* VAR_INPUT (digital) */
  119. plcbit CLAIM;
  120. plcbit RELEASE;
  121. /* VAR_OUTPUT (digital) */
  122. plcbit BUSY;
  123. /* VAR (digital) */
  124. plcbit X;
  125. } SEMA_typ;
  126. typedef struct RS
  127. {
  128. /* VAR_INPUT (digital) */
  129. plcbit SET;
  130. plcbit RESET1;
  131. /* VAR_OUTPUT (digital) */
  132. plcbit Q1;
  133. } RS_typ;
  134. typedef struct SR
  135. {
  136. /* VAR_INPUT (digital) */
  137. plcbit SET1;
  138. plcbit RESET;
  139. /* VAR_OUTPUT (digital) */
  140. plcbit Q1;
  141. } SR_typ;
  142. typedef struct R_TRIG
  143. {
  144. /* VAR_INPUT (digital) */
  145. plcbit CLK;
  146. /* VAR_OUTPUT (digital) */
  147. plcbit Q;
  148. /* VAR (digital) */
  149. plcbit M;
  150. } R_TRIG_typ;
  151. typedef struct F_TRIG
  152. {
  153. /* VAR_INPUT (digital) */
  154. plcbit CLK;
  155. /* VAR_OUTPUT (digital) */
  156. plcbit Q;
  157. /* VAR (digital) */
  158. plcbit M;
  159. } F_TRIG_typ;
  160. typedef struct CTU
  161. {
  162. /* VAR_INPUT (analogous) */
  163. unsigned short PV;
  164. /* VAR_OUTPUT (analogous) */
  165. unsigned short CV;
  166. /* VAR_INPUT (digital) */
  167. plcbit CU;
  168. plcbit RESET;
  169. /* VAR_OUTPUT (digital) */
  170. plcbit Q;
  171. /* VAR (digital) */
  172. plcbit M;
  173. } CTU_typ;
  174. typedef struct CTD
  175. {
  176. /* VAR_INPUT (analogous) */
  177. unsigned short PV;
  178. /* VAR_OUTPUT (analogous) */
  179. unsigned short CV;
  180. /* VAR_INPUT (digital) */
  181. plcbit CD;
  182. plcbit LOAD;
  183. /* VAR_OUTPUT (digital) */
  184. plcbit Q;
  185. /* VAR (digital) */
  186. plcbit M;
  187. } CTD_typ;
  188. typedef struct CTUD
  189. {
  190. /* VAR_INPUT (analogous) */
  191. signed short PV;
  192. /* VAR_OUTPUT (analogous) */
  193. signed short CV;
  194. /* VAR_INPUT (digital) */
  195. plcbit CU;
  196. plcbit CD;
  197. plcbit RESET;
  198. plcbit LOAD;
  199. /* VAR_OUTPUT (digital) */
  200. plcbit QU;
  201. plcbit QD;
  202. /* VAR (digital) */
  203. plcbit MU;
  204. plcbit MD;
  205. } CTUD_typ;
  206. typedef struct RF_TRIG
  207. {
  208. /* VAR_INPUT (digital) */
  209. plcbit CLK;
  210. /* VAR_OUTPUT (digital) */
  211. plcbit Q;
  212. /* VAR (digital) */
  213. plcbit M;
  214. } RF_TRIG_typ;
  215. /* Prototyping of functions and function blocks */
  216. void TP_10ms(TP_10ms_typ* inst);
  217. void TOF_10ms(TOF_10ms_typ* inst);
  218. void TON_10ms(TON_10ms_typ* inst);
  219. void TP(TP_typ* inst);
  220. void TOF(TOF_typ* inst);
  221. void TON(TON_typ* inst);
  222. void SEMA(SEMA_typ* inst);
  223. void RS(RS_typ* inst);
  224. void SR(SR_typ* inst);
  225. void R_TRIG(R_TRIG_typ* inst);
  226. void F_TRIG(F_TRIG_typ* inst);
  227. void CTU(CTU_typ* inst);
  228. void CTD(CTD_typ* inst);
  229. void CTUD(CTUD_typ* inst);
  230. void RF_TRIG(RF_TRIG_typ* inst);
  231. #ifdef __cplusplus
  232. };
  233. #endif
  234. #endif /* STANDARD_H_ */