Kkula
Browse Questions » LOGO! - Projects: Displaying Timer countdown

About User

Questions Asked: 37.9K

Answers Given: 32

0
  • Open

LOGO! - Projects: Displaying Timer countdown

Hi there,
I've been searching the forum for two days, and still haven't found the answer to my problem.
I'm trying to do a very simple task - I have a timer running and I want to display the time on the display as it counts. I can't see any parameter in the timer function to pass the data to the message text block.
Am I doing something wrong, or is it just not possible?
Thanks!

0 Likes 0 Favourites 0 Followers 0 Comments
Answers(8)

LED Dimmer Control with Digital Input - Sample Program

Here's a conceptual approach and resources to help you implement LED dimmer control (0...10V) using a digital input with push-on/off and long-push dimming functionality in a Siemens PLC environment (TIA Portal). A direct, ready-to-download program requires specifics about your PLC model and hardware configuration.

Core Logic

  1. Digital Input Monitoring: Use a digital input (e.g., I0.0) to detect push events.
  2. Edge Detection: Implement edge detection (rising/falling edge) to distinguish between short and long pushes. Consider using Siemens' built-in functions or create custom logic.
  3. Timer Function: Utilize a timer (TON - Timer On Delay) to differentiate short (ON/OFF) from long (dimming) pushes. A short pulse triggers ON/OFF, a longer pulse initiates dimming.
  4. PWM Output: Generate a PWM (Pulse Width Modulation) signal corresponding to the 0-10V range using a physical output (e.g., Q0.0). Scale the PWM duty cycle to the desired dimming level.
  5. Dimming Control: Increment/decrement the PWM duty cycle based on the long push direction. Limit the dimming range to 0-10V equivalent.

Resources & Example Blocks

  • Siemens Industry Online Support: https://support.industry.siemens.com/ - Search for "PWM generation TIA Portal" and "Digital Input Processing"
  • Siemens Documentation: Refer to your PLC's manual for detailed information on PWM output configuration and timer functions.
  • Example Code Snippets (Conceptual): Look for examples demonstrating timer usage and PWM generation in the Siemens community forums.

Important Considerations

  • Hardware Compatibility: Ensure your PLC's output module supports PWM.
  • 0-10V Interface: Use appropriate circuitry to convert the PWM signal to a 0-10V analog signal for the LED dimmer.
  • Safety: Implement appropriate safety measures to protect the LED dimmer and PLC.

Please provide your PLC model and hardware details for more specific guidance.

0

Terminating Unused Analog Outputs in LOGO!

Hello Andrey,

Yes, it's generally recommended to terminate unused analog outputs in your LOGO! design to prevent potential interference or unexpected behavior. While your data is utilized for computations, floating analog outputs can sometimes cause noise or instability.

The most effective way to terminate them is to connect them to ground (0V) via a resistor. A value between 10kΩ and 100kΩ is typically suitable. This provides a defined state for the output.

You can find more detailed information on this topic, including diagrams, within the LOGO! documentation on SiePortal:

Siemens SiePortal - LOGO! 8 Analog Output Termination

Best regards,
Siemens Self Support

0

LOGO! 8 and Modbus Override for Flip-Flop Logic

You're encountering a common issue when combining local logic (flip-flop) with Modbus control in LOGO! 8. The LOGO! prioritizes its internal logic. Directly overriding a flip-flop output via Modbus and then reverting to the flip-flop behavior requires a specific approach.

Here's a recommended solution:

  1. Use a Flag/Memory Bit: Instead of directly controlling the output, control a flag/memory bit (e.g., MB1). The flip-flop logic then controls the output based on this flag.
  2. Modbus Control of the Flag: Map the flag (MB1) to a Modbus register. Write '0' to the register to force the output OFF, and '1' to force it ON – bypassing the flip-flop.
  3. Override Reset with Input: Use an input (your button) to toggle the flag. However, only allow the toggle to happen if the Modbus register is in a specific 'auto' state (e.g., a value of '2'). This way, Modbus control has precedence. Use a comparison block to check the Modbus register value before toggling the flag.

Resources:

SiePortal Note: Searching SiePortal for "LOGO! Modbus Override" and "LOGO! Flip-Flop Control" will provide further detailed examples and blocks.

0

Debugging RPM Display Issues with Counter & TD Module

You're encountering issues with displaying RPM using a counter and a TD module (0BA6.ES3 + TD) in your Siemens system. The flickering and inaccurate readings are common challenges with frequency-to-RPM conversion. Here’s a structured approach to debugging:

1. Hardware Considerations (Flickering on Actual Hardware)

  • Input Signal Quality: Ensure your 10V, 50-500Hz input signal is clean and stable. Noise can cause erratic counting. Use a scope to verify.
  • Wiring: Double-check the wiring between the frequency source and input channel I3. A loose connection or improper shielding can introduce noise.
  • TD Module Configuration: Verify the input characteristics (voltage level, signal type) are correctly configured in the TD module's hardware configuration.
  • Counter Mode: Confirm you are using the correct counter mode for your signal. An up/down counter might be more stable than a simple up-counter if the signal isn’t perfectly consistent.

2. Software/Code Issues (Simulation & Hardware)

  • Reset Pulse: The core of the problem likely lies with how the reset pulse is handled. The counter needs a reliable, periodic reset signal synchronized with the RPM calculation. The current setup seems to be updating on every pulse rather than the calculated RPM period.
  • Simulation: The simulation issue (B001 always zero) indicates a problem with the simulated input. Ensure the simulation is correctly generating a pulse train corresponding to the desired frequency. Manually triggering the counter with rapid clicks is not representative of a real-world frequency input.
  • Scaling & Units: Double-check the scaling factor used to convert Hz to RPM. An incorrect factor will produce wrong results.
  • Data Type: Confirm that the data types used for the counter value and RPM display are appropriate (e.g., INT, REAL) to avoid truncation errors.

3. Debugging Steps & Resources

  1. Monitor Intermediate Values: In your TIA Portal project, monitor the raw counter value (B001), the frequency calculation, and the scaled RPM value in real-time. This will help identify where the error is occurring.
  2. Breakpoints: Use breakpoints in your code to step through the logic and inspect variable values at each stage.
  3. SiePortal Support: Search Siemens Industry Online Support for similar issues and solutions related to counters, frequency measurement, and TD modules.
  4. Example Code Review: Carefully review the provided code example. Pay close attention to how the reset pulse is used and how the frequency is calculated.

Important: The Counter Threshold Trigger block's lack of hysteresis can be mitigated in software by adding logic to filter out spurious counts. However, addressing the core reset pulse and signal quality issues is crucial for a reliable RPM display.

0

Virtual Display & Curve Visualization in LOGO!

Yes, visualizing curves similar to the LOGO! virtual display is possible, but requires a different approach than directly replicating the LOGO! environment.

LOGO! 8.3 introduced the virtual display feature for direct visualization. For older versions or when integrating with a SCADA system, you’ll need to use alternative methods. Here's how:

  • HMI/SCADA System: The recommended method is to use a Human Machine Interface (HMI) or SCADA system (like Siemens WinCC, TIA Portal WinCC, or third-party options). These platforms allow you to create custom graphical displays and chart trends of your LOGO! data.
  • Data Logging & External Tools: Log data from the LOGO! (using network variables or Modbus TCP) to a data logger or historian. Then, utilize external charting software (like Excel, Matlab, or dedicated trending tools) to visualize the curves.

Resources:

If you provide more details about your LOGO! version and desired level of integration, I can offer more specific guidance.

0
Logo! 8 - Simple Pump/Blower Control

Controlling Pumps/Blowers with Logo! 8 Timers

Hi Roy, welcome to Logo! programming. Here's a simple approach to control your pumps and blowers based on time, assuming you've already set up the clock and a timer block:

Steps:

  1. Timer Configuration: For each pump/blower, use an ON timer block. Configure each timer with the desired start time and duration (how long it should run).
  2. Wiring to Outputs: Connect the output (Q) of each timer block to the corresponding output connected to your pump or blower. When the timer is active (running), its output will be ON, activating the device.
  3. Clock as Trigger: Ensure the clock's daily update signal triggers your timers. Typically, this is a constant signal.

Example: Pump 1 runs from 8:00 AM for 30 minutes. Set the timer for 8:00 AM, duration 30 minutes, and connect its output to the relay controlling Pump 1.

For detailed guidance, refer to the Logo! 8 Documentation and consider watching some introductory tutorials on Siemens' support website. You can also search SiePortal for "Logo 8 basic time control" for example programs.

Good luck!

0
Emergency Stop with LOGO! 24CE

Using an Emergency Stop Push Button with LOGO! 24CE (Transistor Outputs)

To implement an Emergency Stop (E-Stop) with your LOGO! 24CE utilizing transistor outputs, you'll need to wire the E-Stop button to a suitable input and configure a network to de-energize the relevant outputs.

Wiring & Configuration:

  1. Wiring: Connect the E-Stop button as a normally closed (NC) contact to a LOGO! input (e.g., I1). This means the input is HIGH when the button is *not* pressed.
  2. Network Configuration: Create a network in the LOGO!Soft Comfort software.
    • Use the E-Stop input (I1) as a condition in an AND or OR gate. An AND gate is generally recommended for safety.
    • Connect the output of the gate to the transistor outputs you want to control.
    • Configure the gate so that *any* activation of the E-Stop (opening the NC contact - input goes LOW) immediately de-energizes the outputs.

Important Considerations:

  • Safety Circuit: For critical applications, consider a separate, dedicated safety relay alongside the LOGO! 24CE.
  • Self-Monitoring: Utilize LOGO!'s diagnostic functions to monitor the E-Stop input and the status of the controlled outputs.
  • Documentation: Refer to the LOGO! 24CE documentation and LOGO!Soft Comfort help files for detailed information on safety functions and network configuration.

For more detailed guidance, including example programs and safety standards, please visit the Siemens Support website:

Siemens Support - LOGO! Emergency Stop
0

Displaying Timer Value in a Message Text Block

You are right to question this, as directly passing the timer's current value to a message text block within the standard Timer function isn't a built-in feature in TIA Portal.

Here are common workarounds to achieve this:

  1. Using a Data Block: Store the timer's current value (.Q output or .CTU/.CTD) in a data block variable. Then, link the message text block to display that variable. This is the recommended approach.
  2. Using a Function Block (FB): Encapsulate the timer within a function block and include an output parameter for the current timer value. Display that output.
  3. Indirect Addressing (More Complex): Use indirect addressing with an array to store timer values, but this is generally more complex than the Data Block approach.

See this SiePortal FAQ for more details and examples:

How do you display the current value of a timer on a HMI?

Important: Ensure the data type of the displayed variable in the message text block matches the data type of the timer's current value.

0