AsIOAcc.fun 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. {REDUND_CONTEXT} {REDUND_UNREPLICABLE} FUNCTION_BLOCK AsIOAccRead (*reads noncyclical register (only inputs); asynchronous execution*)
  2. VAR_INPUT
  3. enable :BOOL; (*enables execution*)
  4. pDeviceName :UDINT; (*device name given as a pointer*)
  5. pChannelName :UDINT; (*pointer to the channel name*)
  6. END_VAR
  7. VAR_OUTPUT
  8. status :UINT; (*execution status: ERR_OK, ERR_FUB_ENABLE_FALSE, ERR_FUB_BUSY, 0xXXXX = see help*)
  9. value :UDINT; (*value read*)
  10. END_VAR
  11. VAR
  12. intern :IOAC_I_TYPE; (*internal variable*)
  13. END_VAR
  14. END_FUNCTION_BLOCK
  15. {REDUND_CONTEXT} {REDUND_UNREPLICABLE} FUNCTION_BLOCK AsIOAccWrite (*writes noncyclical register (ONLY outputs); asynchronous execution*)
  16. VAR_INPUT
  17. enable :BOOL; (*enables execution*)
  18. pDeviceName :UDINT; (*device name given as a pointer*)
  19. pChannelName :UDINT; (*pointer to the channel name*)
  20. value :UDINT; (*value to be written*)
  21. END_VAR
  22. VAR_OUTPUT
  23. status :UINT; (*execution status: ERR_OK, ERR_FUB_ENABLE_FALSE, ERR_FUB_BUSY, 0xXXXX = see help*)
  24. END_VAR
  25. VAR
  26. intern :IOAC_I_TYPE; (*internal variable*)
  27. END_VAR
  28. END_FUNCTION_BLOCK
  29. {REDUND_CONTEXT} {REDUND_UNREPLICABLE} FUNCTION_BLOCK AsIOAccReadReg (*reads noncyclical register (SGC only); asynchronous execution*)
  30. VAR_INPUT
  31. enable : BOOL; (*enables execution*)
  32. nodeNr : USINT; (*node number of x2x module*)
  33. registerNr : UINT; (*register number*)
  34. size : USINT; (*register size*)
  35. END_VAR
  36. VAR_OUTPUT
  37. status : UINT; (*execution status: ERR_OK, ERR_FUB_ENABLE_FALSE, ERR_FUB_BUSY, 0xXXXX = see help*)
  38. value : UDINT; (*regsiter value*)
  39. END_VAR
  40. VAR
  41. i_state : UINT; (*internal variable*)
  42. i_result : UINT; (*internal variable*)
  43. i_tmp : UDINT; (*internal variable*)
  44. END_VAR
  45. END_FUNCTION_BLOCK
  46. {REDUND_CONTEXT} {REDUND_UNREPLICABLE} FUNCTION_BLOCK AsIOAccWriteReg (*writes noncyclical register (SGC only); asynchronous execution*)
  47. VAR_INPUT
  48. enable : BOOL; (*enables execution*)
  49. nodeNr : USINT; (*node number of x2x module*)
  50. registerNr : UINT; (*register number*)
  51. size : USINT; (*register size*)
  52. value : UDINT; (*new register value*)
  53. END_VAR
  54. VAR_OUTPUT
  55. status : UINT; (*execution status: ERR_OK, ERR_FUB_ENABLE_FALSE, ERR_FUB_BUSY, 0xXXXX = see help*)
  56. END_VAR
  57. VAR
  58. i_state : UINT; (*internal variable*)
  59. i_result : UINT; (*internal variable*)
  60. i_tmp : UDINT; (*internal variable*)
  61. END_VAR
  62. END_FUNCTION_BLOCK