happyhippo
Member
Hey,
I have a TP177B PN/DP and a S7-300 (323-2 DP). For my project I need to connect them and let them communicate via Profibus. Making the program for the TP177B and the S7 isn't really a problem. The only problem I have is that the output on my S7 won't be high (1).
My testconfiguration:
I made a button on my TP177B that activates M0.0 (SetBit). On my S7 program I have this:
so the output should be high, softwarematicly and on the PLC. When I set everything up with Profibus and test it, I see that when I push the button, M0.0 (and ofcourse Q0.0) are green (in my S7 program), meaning that M0.0 is high, and Q0.0 should be high (on the PLC). Softwarematicly everything works and Q0.0 is high, but the output isn't high on my PLC.
Some extra info about my program:
I have tried every output, and not one is actually making the output on my PLC high.
I hope you can help me, my project needs to be finished in 2 weeks and this is the only thing that is stopping me from completing my project.
Kind regards,
happyhippo
I have a TP177B PN/DP and a S7-300 (323-2 DP). For my project I need to connect them and let them communicate via Profibus. Making the program for the TP177B and the S7 isn't really a problem. The only problem I have is that the output on my S7 won't be high (1).
My testconfiguration:
I made a button on my TP177B that activates M0.0 (SetBit). On my S7 program I have this:
Code:
A M0.0
= Q0.0
so the output should be high, softwarematicly and on the PLC. When I set everything up with Profibus and test it, I see that when I push the button, M0.0 (and ofcourse Q0.0) are green (in my S7 program), meaning that M0.0 is high, and Q0.0 should be high (on the PLC). Softwarematicly everything works and Q0.0 is high, but the output isn't high on my PLC.
Some extra info about my program:
Code:
ORGANIZATION_BLOCK OB 1
TITLE = "Main Program Sweep (Cycle)"
VERSION : 0.1
VAR_TEMP
OB1_EV_CLASS : BYTE ; //Bits 0-3 = 1 (Coming event), Bits 4-7 = 1 (Event class 1)
OB1_SCAN_1 : BYTE ; //1 (Cold restart scan 1 of OB 1), 3 (Scan 2-n of OB 1)
OB1_PRIORITY : BYTE ; //Priority of OB Execution
OB1_OB_NUMBR : BYTE ; //1 (Organization block 1, OB1)
OB1_RESERVED_1 : BYTE ; //Reserved for system
OB1_RESERVED_2 : BYTE ; //Reserved for system
OB1_PREV_CYCLE : INT ; //Cycle time of previous OB1 scan (milliseconds)
OB1_MIN_CYCLE : INT ; //Minimum cycle time of OB1 (milliseconds)
OB1_MAX_CYCLE : INT ; //Maximum cycle time of OB1 (milliseconds)
OB1_DATE_TIME : DATE_AND_TIME ; //Date and time OB1 started
END_VAR
BEGIN
NETWORK
TITLE =
A M 0.0;
= Q 0.0;
END_ORGANIZATION_BLOCK
ORGANIZATION_BLOCK OB 82
TITLE = "I/O Point Fault"
VERSION : 0.1
VAR_TEMP
OB82_EV_CLASS : BYTE ; //16#39, Event class 3, Entering event state, Internal fault event
OB82_FLT_ID : BYTE ; //16#XX, Fault identifcation code
OB82_PRIORITY : BYTE ; //Priority of OB Execution
OB82_OB_NUMBR : BYTE ; //82 (Organization block 82, OB82)
OB82_RESERVED_1 : BYTE ; //Reserved for system
OB82_IO_FLAG : BYTE ; //Input (01010100), Output (01010101)
OB82_MDL_ADDR : WORD ; //Base address of module with fault
OB82_MDL_DEFECT : BOOL ; //Module defective
OB82_INT_FAULT : BOOL ; //Internal fault
OB82_EXT_FAULT : BOOL ; //External fault
OB82_PNT_INFO : BOOL ; //Point information
OB82_EXT_VOLTAGE : BOOL ; //External voltage low
OB82_FLD_CONNCTR : BOOL ; //Field wiring connector missing
OB82_NO_CONFIG : BOOL ; //Module has no configuration data
OB82_CONFIG_ERR : BOOL ; //Module has configuration error
OB82_MDL_TYPE : BYTE ; //Type of module
OB82_SUB_MDL_ERR : BOOL ; //Sub-Module is missing or has error
OB82_COMM_FAULT : BOOL ; //Communication fault
OB82_MDL_STOP : BOOL ; //Module is stopped
OB82_WTCH_DOG_FLT : BOOL ; //Watch dog timer stopped module
OB82_INT_PS_FLT : BOOL ; //Internal power supply fault
OB82_PRIM_BATT_FLT : BOOL ; //Primary battery is in fault
OB82_BCKUP_BATT_FLT : BOOL ; //Backup battery is in fault
OB82_RESERVED_2 : BOOL ; //Reserved for system
OB82_RACK_FLT : BOOL ; //Rack fault, only for bus interface module
OB82_PROC_FLT : BOOL ; //Processor fault
OB82_EPROM_FLT : BOOL ; //EPROM fault
OB82_RAM_FLT : BOOL ; //RAM fault
OB82_ADU_FLT : BOOL ; //ADU fault
OB82_FUSE_FLT : BOOL ; //Fuse fault
OB82_HW_INTR_FLT : BOOL ; //Hardware interupt input in fault
OB82_RESERVED_3 : BOOL ; //Reserved for system
OB82_DATE_TIME : DATE_AND_TIME ; //Date and time OB82 started
END_VAR
BEGIN
END_ORGANIZATION_BLOCK
ORGANIZATION_BLOCK OB 85
TITLE = "Organization Block (OB) Not Loaded Fault"
VERSION : 0.1
VAR_TEMP
OB85_EV_CLASS : BYTE ; //16#35 Event class 3
OB85_FLT_ID : BYTE ; //16#XX, Fault identification code
OB85_PRIORITY : BYTE ; //Priority of OB Execution
OB85_OB_NUMBR : BYTE ; //85 (Organization block 85, OB85)
OB85_RESERVED_1 : BYTE ; //Reserved for system
OB85_RESERVED_2 : BYTE ; //Reserved for system
OB85_RESERVED_3 : INT ; //Reserved for system
OB85_ERR_EV_CLASS : BYTE ; //Class of event causing error
OB85_ERR_EV_NUM : BYTE ; //Number of event causing error
OB85_OB_PRIOR : BYTE ; //Priority of OB causing error
OB85_OB_NUM : BYTE ; //Number of OB causing error
OB85_DATE_TIME : DATE_AND_TIME ; //Date and time OB85 started
END_VAR
BEGIN
END_ORGANIZATION_BLOCK
ORGANIZATION_BLOCK OB 86
TITLE = "Loss Of Rack Fault"
VERSION : 0.1
VAR_TEMP
OB86_EV_CLASS : BYTE ; //16#38/39 Event class 3
OB86_FLT_ID : BYTE ; //16#C1/C4/C5, Fault identifcation code
OB86_PRIORITY : BYTE ; //Priority of OB Execution
OB86_OB_NUMBR : BYTE ; //86 (Organization block 86, OB86)
OB86_RESERVED_1 : BYTE ; //Reserved for system
OB86_RESERVED_2 : BYTE ; //Reserved for system
OB86_MDL_ADDR : WORD ; //Base address of IM module in rack with fault
OB86_RACKS_FLTD : ARRAY [0 .. 31 ] OF BOOL ; //Racks in fault
OB86_DATE_TIME : DATE_AND_TIME ; //Date and time OB86 started
END_VAR
BEGIN
END_ORGANIZATION_BLOCK
I have tried every output, and not one is actually making the output on my PLC high.
I hope you can help me, my project needs to be finished in 2 weeks and this is the only thing that is stopping me from completing my project.
Kind regards,
happyhippo
Last edited: