Skip to product information
1 of 1

Level measurement with ultrasound

Regular price €4,90 EUR
Regular price Sale price €4,90 EUR
Sale Sold out
ChatGPT:

Description
The FB_Tankstand_Ultraschall function block monitors the fill level of a tank using an ultrasonic sensor, scales the raw value to centimeters and percent, controls a refill valve, and reports when predefined limits are exceeded or not reached. When the stop signal is activated, all alarms are reset, the valve is closed, and the status is set to "System stopped."

Note: All modules are designed exclusively as a learning and optimization basis and are not approved for live operation. System modules, in particular, must be finally tested and commissioned by qualified personnel before productive use.

How it works

  • Stop ( Stop=TRUE ):
    → Reset alarms, VentilNachfuellen=FALSE , StatusText=“System gestoppt” , RETURN
  • Calculate fill level :
    → Distance from the lid scaled to cm, subtracted from total height → Füllstand_cm , then converted to percent
  • Undershooting MinLimit ( Füllstand_cm < MinGrenze ):
    AlarmMIN=TRUE , VentilNachfuellen=TRUE , StatusText=“Füllstand zu niedrig – Nachfüllen aktiv”
  • Exceeding MaxLimit ( Füllstand_cm > MaxGrenze ):
    AlarmMAX=TRUE , VentilNachfuellen=FALSE , StatusText=“Füllstand zu hoch – Alarm!”
  • In the target range ( MinGrenze ≤ Füllstand_cm ≤ MaxGrenze ):
    VentilNachfuellen=FALSE , StatusText=“Füllstand im Sollbereich”
  • Acknowledgement ( Quittieren=TRUE ):
    AlarmMIN=FALSE , AlarmMAX=FALSE , reset error flag, StatusText=“Fehler quittiert – Überwachung läuft”

Technical details

  • Entrances:
    SensorRAW (INT), Stop , Start , Quittieren (each BOOL),
    Tankhöhe_cm , MinGrenze , MaxGrenze (REAL)
  • Calculation:
    Abstand_cm = SensorRAW × (Tank height_cm / 27648)
    Füllstand_cm = Tank height_cm – Distance_cm
    FüllstandProzent = fill level_cm / tank height_cm × 100
  • Outputs/Variables:
    AlarmMIN , AlarmMAX (BOOL), VentilNachfuellen (BOOL), StatusText (STRING)
  • Logic:
    – IF/ELSIF with RETURN on stop, no timers

Possible applications
Level monitoring in water and wastewater plants, chemical and food tanks, test benches, retrofitting in existing plants and PLC training.

compatibility
Siemens S7-1200/S7-1500, TIA Portal ≥ V13 (V16+ recommended for HMI/PLCSIM)

Scope of delivery
.scl file with declaration of all inputs/outputs, variables, and feedback parameters; header comment with customization instructions; download link after purchase.

Support
Adjustment of limit values, integration of additional sensors or HMI layouts – individual advice via shop message or email.