Inst ToolsInst ToolsInst Tools
  • Courses
  • Videos
  • Q & A
    • Interview
      • Instrumentation
      • Electronics
      • Electrical
      • Practical Questions
    • MCQ
      • Instrumentation MCQ
      • Electrical MCQ
      • Electronics MCQ
      • Control Systems MCQ
      • Analog Electronics MCQ
      • Digital Electronics MCQ
      • Power Electronics MCQ
      • Microprocessor MCQ
      • Multiple Choice Questions
  • EE
    • Electronics
      • Electronics Q & A
      • Electronic Basics
      • Electronic Devices & Circuits
      • Electronics Animation
      • Digital Electronics
    • Electrical
      • Electrical Basics
      • Electrical Q & A
      • Power Electronics
      • Electrical Machines
      • Electrical Animation
      • Power Systems
      • Switchgear & Protection
      • Transmission & Distribution
  • Measure
    • Control Valves
    • Calibration
    • Temperature
    • Pressure
    • Flow
    • Level
    • Analyzers
    • Switches
    • Vibration
    • Solenoid Valve
  • Control
    • PLC Tutorials
    • Control Systems
    • Safety Instrumented System (SIS)
    • Communication
    • Fire & Gas System
  • More
    • Design
    • Tools
    • Animation
    • Basics
    • Formulas
    • Standards
    • TextBooks
    • Common
    • Software
    • Excel Tools
    • Erection & Commissioning
    • Process Fundamentals
    • Videos
    • Books
Search
All rights reserved. Reproduction in whole or in part without written permission is prohibited.
Reading: Converter Instruction in Siemens PLC Programming
Share
Notification Show More
Font ResizerAa
Inst ToolsInst Tools
Font ResizerAa
  • Courses
  • PLC Tutorials
  • Control Systems
Search
  • Courses
  • Videos
  • Q & A
    • Interview
    • MCQ
  • EE
    • Electronics
    • Electrical
  • Measure
    • Control Valves
    • Calibration
    • Temperature
    • Pressure
    • Flow
    • Level
    • Analyzers
    • Switches
    • Vibration
    • Solenoid Valve
  • Control
    • PLC Tutorials
    • Control Systems
    • Safety Instrumented System (SIS)
    • Communication
    • Fire & Gas System
  • More
    • Design
    • Tools
    • Animation
    • Basics
    • Formulas
    • Standards
    • TextBooks
    • Common
    • Software
    • Excel Tools
    • Erection & Commissioning
    • Process Fundamentals
    • Videos
    • Books
Follow US
All rights reserved. Reproduction in whole or in part without written permission is prohibited.
Inst Tools > Blog > PLC Tutorials > Converter Instruction in Siemens PLC Programming

Converter Instruction in Siemens PLC Programming

Last updated: March 4, 2021 1:11 pm
Editorial Staff
PLC Tutorials
No Comments
Share
3 Min Read
SHARE

Let’s study the working of converter instruction in Siemens PLC programming using different ladder logics and programs.

Contents
Converter Instruction in PLCBlock DescriptionRound to double integer:Truncate double integer part:Ceiling:Floor:Ladder LogicLadder Description:Network 1:Network 2:Network 3:Network 4:

Converter Instruction in PLC

Converter Instruction in Siemens PLC Programming

Block Description

Round to double integer:

It reads the input floating point value and converts it to double integer and round to nearest integer. The result is output by the parameter OUT.

Rounding to Nearest Integer in PLC

Truncate double integer part:

It reads the input floating point value and converts it to double integer and round to zero mode. The result is output by the parameter OUT.

Truncate Double Integer Part in PLC Logic

Ceiling:

It reads the input floating point value and converts it to double integer. The result is the lowest integer which is greater than the floating point number i.e  Round to + infinity mode. The result is output by the parameter OUT.

Ceiling Instruction in PLC

Floor:

It reads the input floating point value and converts it to double integer. The result is the greatest integer component which is greater than the floating point number i.e Round to -infinity mode. The result is output by the parameter OUT.

Floor Instruction in PLC

Ladder Logic

PLC Programming Example using Converters

Ladder Description:

Network 1:

If I0.0 is pressed, value in MD0 (99.78) is read as a floating point number and converted to the closest double integer(100). The result of round to integer is stored in MD4(100).

Network 2:

If I0.0 is pressed, value in MD0 (99.78) is read as a floating point number and converted to the double integer. The integer part of the floating point number is the result. The result is stored in MD12 (99).

Network 3:

If I0.0 is pressed, value in MD0 (99.78) is read as a floating point number and converted to the double integer by round function . The result is stored in MD12 (100).

Network 4:

If I0.0 is pressed, value in MD0 (99.78)is read as a floating point number and converted to the double integer by the round to – infinity mode. The result is stored in MD16(99).

Note: For positive numbers, trunc and floor give the same result. But for negative numbers, floor rounds down and trunc rounds up. This is because trunc always rounds toward 0.

Author: Hema Sundaresan

If you liked this article, then please subscribe to our YouTube Channel for PLC and SCADA video tutorials.

You can also follow us on Facebook and Twitter to receive daily updates.

Read Next:

  • JUMP Instruction in PLC Programs
  • Master Control Reset (MCR) in PLC
  • One-Shot Rising & Falling Instructions
  • Sequence and Logic Control in PLC
  • Scaling with Parameters Instruction
  • What is DCS and ESD Systems?
Don't Miss Our Updates
Be the first to get exclusive content straight to your email.
We promise not to spam you. You can unsubscribe at any time.
Invalid email address
You've successfully subscribed !

Recommended Articles

Five Types of PLC Programming languages
How to Start Writing SCL Language in Siemens Tia Portal?
How to Interchange ON Delay Timer and OFF Delay Timer in a PLC
Types of Digital Outputs in PLC
PLC Program for Alarm Security System
Types of Noise in Electronics
Share This Article
Facebook Whatsapp Whatsapp LinkedIn Copy Link
Share
Leave a Comment

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Stay Connected

128.3kFollowersLike
69.1kFollowersFollow
208kSubscribersSubscribe
38kFollowersFollow

Categories

Recent Comments

  • William Snyder on Top Non-PLC Certification Courses for Automation Professionals
  • Kamli on Top Free PLC Software
  • Guifty Shimica on Top Non-PLC Certification Courses for Automation Professionals
  • Guifty Shimica on Top Non-PLC Certification Courses for Automation Professionals

Related Articles

Ladder Logic Example of Two Motors

Ladder Logic Example of Two Motors Interlinked with another Motor

What is a Floating License - Automation Software Systems

What is a Floating License? – Automation Software Systems

Garage Door Roller Shutter

Shutter Door Control using Motor and Limit Switches

plc-analog-signals-wiring-techniques

PLC Analog Signals Wiring Techniques

Automated Garage Gate Control - PLC Ladder Logic

Automated Garage Gate Control – PLC Ladder Logic

Single-acting Pneumatic Cylinder operation with Limit Switch

Single-acting Pneumatic Cylinder Operation with Limit Switch

Siemens S7 300 and STEP 7 PLC program using SIMATIC Software

PLC Handbook

PLC Handbook

More Articles

Transformers Questions & Answers Part-2

Transformers Questions & Answers Part-2

Electrical Machines Objective Questions

Electrical Machines MCQ Series 8

Over Pressure cases for Pressure Relief Valve Sizing

Over Pressure cases for Pressure Relief Valve Sizing

Top 10 Facts about HART Technology

Top 10 Facts about HART Technology

Temperature Switch

Temperature Switch Working Principle

Orifice Flange Rating

Why Orifice Flow Meter Flange is Not Recommended 150# Rating?

Instrumentation Engineering Documents

Instrumentation Engineering Documents Questions Answers

How is Data Stored in Standard Modbus Protocol?

How is Data Stored in Standard Modbus Protocol?

Follow US
All rights reserved. Reproduction in whole or in part without written permission is prohibited.
Welcome Back!

Sign in to your account

Username or Email Address
Password

Lost your password?