pufferspeicher.awlpro 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270
  1. <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
  2. <!-- Awlsim project file generated by awlsim-0.66.0-pre -->
  3. <awlsim_project date_create="2015-02-01 16:51:34.626142"
  4. date_modify="2018-07-08 18:00:10.844447"
  5. format_version="1">
  6. <!-- CPU core configuration -->
  7. <cpu>
  8. <!-- CPU core feature specification -->
  9. <specs call_stack_size="256"
  10. nr_accus="2"
  11. nr_counters="256"
  12. nr_flags="2048"
  13. nr_inputs="128"
  14. nr_localbytes="1024"
  15. nr_outputs="128"
  16. nr_timers="256"
  17. parenthesis_stack_size="7" />
  18. <!-- CPU core configuration -->
  19. <config clock_memory_byte="-1"
  20. cycle_time_limit_us="1000000"
  21. ext_insns_enable="0"
  22. mnemonics="0"
  23. ob_startinfo_enable="0"
  24. run_time_limit_us="-1" />
  25. </cpu>
  26. <!-- AWL/STL language configuration -->
  27. <language_awl>
  28. <!-- AWL/STL source code -->
  29. <source enabled="1"
  30. name="OB1"
  31. type="0"><![CDATA[
  32. ORGANIZATION_BLOCK OB 1
  33. VAR_TEMP
  34. OB1_EV_CLASS : BYTE; // Bits 0-3 = 1 (Coming event), Bits 4-7 = 1 (Event class 1)
  35. OB1_SCAN_1 : BYTE; // 1 (Cold restart scan 1 of OB 1), 3 (Scan 2-n of OB 1)
  36. OB1_PRIORITY : BYTE; // Priority of OB execution
  37. OB1_OB_NUMBR : BYTE; // 1 (Organization block 1, OB 1)
  38. OB1_RESERVED_1 : BYTE;
  39. OB1_RESERVED_2 : BYTE;
  40. OB1_PREV_CYCLE : INT; // Cycle time of previous OB 1 scan (milliseconds)
  41. OB1_MIN_CYCLE : INT; // Minimum cycle time of OB 1 (milliseconds)
  42. OB1_MAX_CYCLE : INT; // Maximum cycle time of OB 1 (milliseconds)
  43. OB1_DATE_TIME : DATE_AND_TIME; // Date and time OB 1 started
  44. END_VAR
  45. BEGIN
  46. CALL "pufferspeicher_aufruf"
  47. END_ORGANIZATION_BLOCK
  48. ]]></source>
  49. <!-- AWL/STL source code -->
  50. <source enabled="1"
  51. name="Pufferspeicher"
  52. type="0"><![CDATA[
  53. FUNCTION "pufferspeicher" : VOID
  54. TITLE =
  55. VERSION : 0.1
  56. VAR_INPUT
  57. zaehler : COUNTER ;
  58. anlage_ein : BOOL ;
  59. ruecksetzen : BOOL ;
  60. lichtschranke_1 : BOOL ;
  61. lichtschranke_2 : BOOL ;
  62. oberer_grenzwert : INT ;
  63. unterer_grenzwert : INT ;
  64. END_VAR
  65. VAR_OUTPUT
  66. bandmotor : BOOL ;
  67. meldelampe : BOOL ;
  68. fuellstand : INT ;
  69. END_VAR
  70. VAR_TEMP
  71. anzahl : WORD ;
  72. END_VAR
  73. BEGIN
  74. NETWORK
  75. TITLE =
  76. U #lichtschranke_1;
  77. U #anlage_ein;
  78. ZV #zaehler;
  79. U #lichtschranke_2;
  80. U #anlage_ein;
  81. ZR #zaehler;
  82. U #ruecksetzen;
  83. U #anlage_ein;
  84. L C#0;
  85. S #zaehler;
  86. NOP 0;
  87. L #zaehler;
  88. T #anzahl;
  89. NOP 0;
  90. NOP 0;
  91. NETWORK
  92. TITLE =
  93. U #anlage_ein;
  94. U( ;
  95. L #anzahl;
  96. L #oberer_grenzwert;
  97. <I ;
  98. ) ;
  99. = #bandmotor;
  100. NETWORK
  101. TITLE =
  102. U #anlage_ein;
  103. U( ;
  104. L #anzahl;
  105. L #unterer_grenzwert;
  106. <I ;
  107. ) ;
  108. = #meldelampe;
  109. NETWORK
  110. TITLE =
  111. L #anzahl;
  112. T #fuellstand;
  113. END_FUNCTION
  114. FUNCTION "pufferspeicher_aufruf" : VOID
  115. TITLE =
  116. VERSION : 0.1
  117. BEGIN
  118. NETWORK
  119. TITLE =
  120. U E 0.0;
  121. = L 0.0;
  122. BLD 103;
  123. U E 0.1;
  124. = L 0.1;
  125. BLD 103;
  126. U E 1.1;
  127. = L 0.2;
  128. BLD 103;
  129. U E 1.2;
  130. = L 0.3;
  131. BLD 103;
  132. CALL "pufferspeicher" (
  133. zaehler := Z 1,
  134. anlage_ein := L 0.0,
  135. ruecksetzen := L 0.1,
  136. lichtschranke_1 := L 0.2,
  137. lichtschranke_2 := L 0.3,
  138. oberer_grenzwert := 40,
  139. unterer_grenzwert := 15,
  140. bandmotor := A 4.1,
  141. meldelampe := A 5.1,
  142. fuellstand := AW 6);
  143. NOP 0;
  144. NETWORK
  145. TITLE =
  146. U E 0.0;
  147. = L 0.0;
  148. BLD 103;
  149. U E 0.1;
  150. = L 0.1;
  151. BLD 103;
  152. U E 2.1;
  153. = L 0.2;
  154. BLD 103;
  155. U E 2.2;
  156. = L 0.3;
  157. BLD 103;
  158. CALL "pufferspeicher" (
  159. zaehler := Z 2,
  160. anlage_ein := L 0.0,
  161. ruecksetzen := L 0.1,
  162. lichtschranke_1 := L 0.2,
  163. lichtschranke_2 := L 0.3,
  164. oberer_grenzwert := 30,
  165. unterer_grenzwert := 10,
  166. bandmotor := A 4.2,
  167. meldelampe := A 5.2,
  168. fuellstand := AW 8);
  169. NOP 0;
  170. END_FUNCTION
  171. ]]></source>
  172. </language_awl>
  173. <!-- Symbol table configuration -->
  174. <symbols>
  175. <!-- symbol table source code -->
  176. <source enabled="1"
  177. name="Symbol table"
  178. type="3"><![CDATA[
  179. 126,array_db DB 60 DB 60
  180. 126,array_uebung FC 60 FC 60
  181. 126,BLKMOV SFC 20 SFC 20 Copy Variables
  182. 126,CREAT_DB SFC 22 SFC 22 Create Data Block
  183. 126,CTD SFB 1 SFB 1 Count Down
  184. 126,CTU SFB 0 SFB 0 Count Up
  185. 126,date_and_time_db DB 20 DB 20
  186. 126,date_and_time_uebung FC 8 FC 8
  187. 126,db_dynamisch FC 20 FC 20
  188. 126,db_zugriff FC 7 FC 7
  189. 126,dbtest_fb FB 40 FB 40
  190. 126,dbtest_fc FC 10 FC 10
  191. 126,DEL_DB SFC 23 SFC 23 Delete Data Block
  192. 126,DELETE FC 104 FC 104 Delete String
  193. 126,DT_DAY FC 107 FC 107 DT to DAY
  194. 126,flankenerkennung FB 20 FB 20
  195. 126,impulszaehler FB 30 FB 30
  196. 126,impulszaehler_aufruf FB 31 FB 31
  197. 126,laufbandsteuerung FC 3 FC 3
  198. 126,laufbandsteuerung_aufrufFC 4 FC 4
  199. 126,Motor UDT 99 UDT 99
  200. 126,multiinst_aufruf FB 100 FB 100
  201. 126,pufferspeicher FC 5 FC 5
  202. 126,pufferspeicher_aufruf FC 6 FC 6
  203. 126,READ_CLK SFC 1 SFC 1 Read System Clock
  204. 126,Rollfeld_Motor_aufruf FC 53 FC 53
  205. 126,Rollfeld_Motor_FC FC 52 FC 52
  206. 126,Rollfeld_Motoren DB 51 DB 51
  207. 126,SB_DT_DT FC 34 FC 34 Subtract DT - DT
  208. 126,stoeranzeige_fb FB 1 FB 1
  209. 126,stoeranzeige_fc FC 1 FC 1
  210. 126,string_db DB 50 DB 50
  211. 126,string_uebung FC 50 FC 50
  212. 126,taktgenerator FB 15 FB 15
  213. 126,taktgenerator_aufruf FB 16 FB 16
  214. 126,tauchbad FB 10 FB 10
  215. 126,tauchbad_aufruf FB 11 FB 11
  216. 126,TEST_DB SFC 24 SFC 24 Test Data Block
  217. 126,TON SFB 4 SFB 4 Generate an On Delay
  218. 126,TP SFB 3 SFB 3 Generate a Pulse
  219. 126,zaehler_fc FC 2 FC 2
  220. ]]></source>
  221. </symbols>
  222. <!-- Core server link configuration -->
  223. <core_link>
  224. <!-- Locally spawned core server -->
  225. <spawn_local enable="1"
  226. interpreters="$DEFAULT"
  227. port_range_begin="4183"
  228. port_range_end="8278" />
  229. <!-- Remote server connection -->
  230. <connect host="localhost"
  231. port="4151"
  232. timeout_ms="3000" />
  233. <!-- Transport tunnel -->
  234. <tunnel local_port="-1"
  235. type="0">
  236. <ssh executable="ssh"
  237. port="22"
  238. user="pi" />
  239. </tunnel>
  240. </core_link>
  241. <!-- Graphical user interface configuration -->
  242. <gui>
  243. <editor autoindent="1"
  244. paste_autoindent="1"
  245. validation="1" />
  246. </gui>
  247. </awlsim_project>