• Home
  • User Manual
  • Tutorials
  • Updates
Search Results for

    Show / Hide Table of Contents
    • Welcome to twin
    • Getting Started
      • Install and uninstall twin
      • Install and uninstall a licence
      • Start twin
    • Simulation Component Library
      • Automation
        • ScriptComponent
        • Sequence
      • BitManipulator
        • BitsToBytesConverter
        • BytesToBitsConverter
        • EndiannessChanger
      • BooleanOperations
        • BooleanFunction
        • Invert
        • InputSwitch
      • ControlPanel
        • ControlPanel
      • Conveyor
        • Conveyor
        • VacuumConveyor
      • Debug
        • Counter
      • DataManipulator
        • DataReader
        • DataTypeConverter
        • DataWriter
      • FMU
        • FMU
      • Gripper
        • KinematicGripper
        • ObjectCoupler
        • VacuumGripper
      • HardwareConnector
        • PLCConnector
        • RobotControllerConnector
      • Math
        • Gain
        • LinearFunction
        • LowPassFilter
        • NumberComparer
        • Sum
      • Motor
        • FCControlledMotor
        • ServoMotor
      • Movers
        • BoolToSignedDirection
        • DynamicCylinder
        • DynamicRotationMover
        • DynamicTranslationMover
        • KinematicCylinder
        • KinematicPathMover
        • KinematicRotationMover
        • KinematicTranslationMover
      • ObjectManipulator
        • Colorizer
        • Object3DCutter
        • VisibilityChanger
      • Sensors
        • AngleLimitSwitch
        • CollisionObserver
        • DistanceSensor
        • DynamicObjectDetector
        • LightBarrier
        • PositionLimitSwitch
        • PositionTracker
      • Sinks
        • FileLogger
        • CollisionSink
        • RaySink
      • Sources
        • BoolConstant
        • BoxSource
        • DoubleConstant
        • Object3DFileSource
        • Object3DSource
        • RandomBoolean
        • RandomNumber
        • SinusGenerator
        • SphereSource
        • StringConstant
      • Timers
        • IntervalTrigger
        • TOF
        • TON
    • Collision Detection
      • What is essential for collision detection?
      • Where can I find the mesh simplifiers?
      • Which mesh simplification methods are available?
    • twin Mirror
      • Install the twin Mirror
      • Embed the twin Mirror into your HMI
      • React on user-events
      • Manipulate 3D objects
      • Add labels and buttons
    • Video Guides
      • Install twin
      • How to handle twin
      • Organize projects
      • Import CAD files
      • Handle 3D objects
      • Organize simulation components
      • Activate physics in your simulation
      • Simulate conveyor systems
      • Simulate cylinders
      • Simulate axis systems and portals
      • Simulate sensors
      • Simulate grippers
      • Create program sequences
      • Connect to PLCs
      • Simulate robots
      • Model complex mechanical motion systems
      • Debug and analyse signals in twin
      • Best practices for maintenance efficient project development
      • FAQ

    BitsToBytesConverter

    This simulation component converts bits to bytes.

    BitsToBytesConverter

    When to use

    Use this simulation component if you need to convert single bits to bytes. This is very practical for setting individual bits that are written to a PLC in the form of a few bytes.

    How to use

    Add this simulation component from the simulation component library. Define the OutputDataType property for the Output. Depending on the OutputDataType the necessary input bits will be created (e.g. an output of type WORD is represented by 16 input bits). Depending on the bit values the corresponding output value of the defined type is calculated.

    Parameters

    OutputDataType

    Indicates the target output data type.

    Protocol Description
    WORD An output data type of 2 unsigned bytes which are represented by 16 input bits.
    DWORD An output data type of 4 unsigned bytes which are represented by 32 input bits.

    Inputs

    BIT_X

    Depending on the OutputDataType property the necessary input bits are available which are used to calculate the output.

    Outputs

    Output

    An output which is defined by the OutputDataType property. The unsigned value represents the state of the inputs bits.

    Example

    In this example, the first two bits are set which indicates an unsigned, 16-bit output value of 3.

    BitsToBytes Example

    Further Information

    For more details visit the Video Guides section, where you can find a video guide demonstrating this topic under Connect to MotoSim.

    In this article
    Back to top Copyright © Eberle Automatische Systeme GmbH & Co KG