Reasons for problems with Siemens S7-200 subroutine - Database & Sql Blog Articles

Brand AVX TPSE226M035R0125 Low impedance tantalum capacitor AVX 22
Electronic scale crystal oscillator 3.2*2.5mm 3225 16M (16.000MHZ) 12PF 10PPM 20PPM 30PPM
Probe domestic switch needle KG-300K needle head diameter is 3.0mm normally open switch needle
SMD aluminum electrolytic capacitor

The subroutine SBR_0 in the previous log is called twice in OB1. When running the program, it is found that the small switch connected to I0.0 is turned on, and Q0.0 and Q0.1 are turned ON at the same time. This is because the address of the output parameter "motor" assigned to SBR_0 is L0.2, and the value of L0.2 is ON after the first call of SBR_0. When SBR_0 is called for the second time, although the start button I0.2 is OFF, since the local variable area is common when SBR_0 is called twice, the output parameter "Motor" (L0.2) is still ON, so the second time After calling SBR_0, the output parameter "Motor" causes Q0.1 to be ON due to the execution of the procedure in Figure 4-40. The local variables of the subroutine must follow the principle of “use first value after use”.
The subroutine of the S7-200 uses temporary variables to pass parameters. The parameters of the OUT type do not read the arguments into the formal parameters. Therefore, the use of the OUT parameters in the contacts here occurs when the temporary variables are not assigned. The above problem can be solved by changing the variable type of the output parameter "Motor" to IN_OUT. This is because the subroutine is called twice, and the operation result returned by the parameter "motor" is saved by Q0.0 and Q0.1 respectively. When the subroutine SBR_0 is called for the second time, the "O #motor" instruction is executed because of "motor". It is the IN_OUT parameter, which is the value saved to Q0.1 in the previous scan cycle, regardless of the value of the parameter "Motor" after the first call of the subroutine in this scan cycle.
Simply put, for a circuit with a memory function, a memory unit is needed to hold the value of the variable to be memorized. The FB of the S7-300 can be saved with static variables, while the subroutine of the S7-200 has no static variables. Only the actual parameters of the IN_OUT variable (Q0.1 in this example) are used to save the variable values.

Wire To Board Connectors

1.ANTENK Wire to Board connectors are avialable in different terminations and sizes intended for use on a variety of applications. These connectors provide power and signal with different body styles, termination options, and centerlines. To find the wire to board set required, click on the appropriate sub section below.

2.Our products are widely used in electronic equipments,such as monitors ,electronic instruments,computer motherboards,program-controlled switchboards,LED,digital cameras,MP4 players,a variety of removable storage disks,cordless telephones,walkie-talkies,mobile phones,digital home appliances and electronic toys,high-speed train,aviation,communication station,Military and so on


Antenk Wire To Board Connectors Ranges:

Power Wire to Board
IDC Wire to Board
Locking Wire to Board
Latching Wire to Board
Fine Pitch Wire to Board


Wire to Board Connectors Information
Description
Wire-to-board connectors are used to interconnect printed circuit boards (PCBs) by using connectors attached to wires.

Specifications
Specifications for a wire to board connector include the following.
Wire-entry angle - There are three wire-entry angle styles: vertical, right-angle, and bottom-entry.
Wire size - Wire size is usually measured in American wire gauge (AWG), a standard for non-ferrous wire conductor sizes. The term "gauge" refers to the wire`s diameter. The higher the gauge number, the smaller the diameter and the thinner the wire.
Circuits or positions - With wire to board connectors, the number of circuits or positions may range from 1 to 120.
Pitch or center spacing - Pitch or center spacing is measured in millimeters (mm) or inches.
Lock to mating style - There are three basic lock-to-mating styles: positive, friction, and friction ramp.
Maximum current - The maximum current or current-carrying capacity is measured in amperes (A) and ranges from 1.0 A to 50. A.

Termination Methods
Crimp is the physical compression of a contact wire around a conductor to make an electrical and mechanical connection. Insulation displacement connectors (IDC) slice through the cable insulation to make a connection. Choices for termination method also include cage clamp, screw, tabs, and solder cups.

PCB Mounting Styles
With wire to board connectors, there are four choices for PCB mounting.
Through-hole technology (THT) mounts components on a PCB by inserting component leads through holes in the board and then soldering the leads in place on the opposite side of the board.
Surface mount technology (SMT) adds components to a PCB by soldering component leads or terminals to the top surface of the board. SMT components have a flat surface that is soldered to a flat pad on the face of the PCB. Typically, the PCB pad is coated with a paste-like formulation of solder and flux.
Press-fit and compression-style Board To Board Connectors are also commonly available.Wire to Board Connectors Information

Standards
Wire-to-board connectors carry approvals from various national and international organizations. In North America, they often bear marks from Underwriters Laboratories (UL) and/or the Canadian Standards Association (CSA).
A wire to board connector for the European marketplace should comply with the Restriction of Hazardous Substances (RoHS) and Waste Electrical and Electronic Equipment (WEEE) directives from the European Union (EU). Wire-to-board connectors that comply with other requirements are also available.
BS 9526 N0001 - Specification for multi-contact edge socket electrical connectors.

Wire To Board Connectors,Wire Harness,Pcb Wire To Board Connector,Pin Wire To Board Connector,IDC Wire to Board,Locking Wire to Board,Latching Wire to Board,Fine Pitch Wire to Board

ShenZhen Antenk Electronics Co,Ltd , https://www.antenkconn.com

Posted on