Example of profibus file pfb.cfg.
Command |
Description |
---|---|
PROFIBUS_ADDRESS 3 |
Profibus node number (exclude dip-switch set) |
BLOCK_TO_RBX 1 |
Block one definition from network to Robox |
BLOCK_STATUS 0xFF |
16 word-configured data in I/O with consistency on the block |
O-0 SEM 1 |
Defines the use of a semaphore for data exchange |
O-1 res 1 |
Reserve one byte |
O-2 R_16_I 3000 -R 15 |
Copies the data contained in the "incoming" block from the network into R registers 3000 to 3014 |
BLOCK_FROM_RBX 1 |
Defines block one from Robox to Network |
O-0 SEM 1 |
Defines the use of a semaphore for data exchange |
O-1 res 1 |
Reserve one byte |
O-2 R_16_I 1500 -R 15 |
Copies the data contained in R registers 1500 to 1514 into the "departing" block on the network |
NOTE: The presence of the traffic light allows you to be able to manage from the program when to activate/suspend the physical copy of the values contained in the block being received to the registers.
Example
;Profibus configuration file ;------------------------------------------------------------- ENABLE_RESET ;board reset with DP ON and no data-exchange RUN_ALWAYS REAL_AS_FLOAT BLOCK_TO_RBX 1 BLOCK_STATUS 0xFF O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 R_16_I 3000 -R 12 O-26 R_16 3012 -R 3 BLOCK_FROM_RBX 1 O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 res 30 ; tutti free BLOCK_TO_RBX 2 BLOCK_STATUS 0xFF O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 res 30 ; tutti free BLOCK_FROM_RBX 2 O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 R_16_I 3015 -R 11 O-24 RR 1800 -R 2 BLOCK_TO_RBX 3 BLOCK_STATUS 0xFF O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 res 30 ; tutti free BLOCK_FROM_RBX 3 O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 RR 426 O-6 R_16_I 3032 -R 9 O-24 R_16 3041 -R 4 BLOCK_TO_RBX 4 BLOCK_STATUS 0xFF O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 res 30 ; tutti free BLOCK_FROM_RBX 4 O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 R_16_I 3045 -R 13 O-28 R_16 3058 -R 2 BLOCK_TO_RBX 5 BLOCK_STATUS 0xFF O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 R_16_I 3060 -R 13 O-28 R_16 3073 -R 2 BLOCK_FROM_RBX 5 O-0 SEM 1 ; ex Fix_sts O-1 res 1 ; ex Echo b O-2 R_16_I 3075 -R 15 |
Example
;---------------------------------- ;Profibus Robox configuration file ;---------------------------------- PROFIBUS_ADDRESS 3 ENABLE_RESET DISABLE_COM_ALARM MIDDLE_BIG_ENDIAN ;----------------------- ; block from plc to ROBOX ;----------------------- BLOCK_TO_RBX 1 BLOCK_STATUS 0xFF ;O-0 wr_r 1000 16 O-0 R_32 1000 -R8 BLOCK_TO_RBX 2 BLOCK_STATUS 0xFF ;O-0 wr_r 1016 16 O-0 R_32 1008 -R8 ;----------------------- ; block from ROBOX to Plc ;----------------------- BLOCK_FROM_RBX 1 ;O-0 rd_r 1050 16 O-0 R_32 1050 -R8 BLOCK_FROM_RBX 2 ;O-0 rd_r 1066 16 O-0 R_32 1058 -R8 |