Наши бренды

Impact-Company-Logo-English Black-01-177x54

Добро пожаловать на сайт Schneider Electric

Добро пожаловать на наш сайт.
		
Чем мы можем помочь сегодня?
SCADAPack 474: Logic Blocks for Pulse Counting and DI-Based Reset

This article explains how to implement a pulse counting mechanism using SCADAPack 474 logic, leveraging a soft counter and a digital input (DI) for reset functionality. The logic is designed to work with physical I/O constraints, where the external counter retains its value and cannot be reset to zero.


Connections

  • Pulse Input: Connect the pulse signal to PIO_SP474_CI1, which acts as the physical counter input.
  • Soft Counter: Use a SoftCounter variable to track the pulse count logically.
  • Reset Input: Connect a digital input to PIO_SP474_DI1, which will be used to trigger a logical reset.

Key Logic Operations

  1. Copy Counter Value to SoftCounter
    The current value from PIO_SP474_CI1 is copied to SoftCounter.VALUE during each scan cycle.

  2. Reset Temporary Counter Value
    A MOVE block resets tempCounterValue when required.

  3. Trigger-Based Reset Using DI1
    When PIO_SP474_DI1 transitions from high to low (falling edge), the value of PIO_SP474_CI1 is loaded into tempCounterValue. This simulates a reset by establishing a new reference point.

  4. Calculate Difference and Update SoftCounter
    The logic compares PIO_SP474_CI1.VALUE with tempCounterValue using GT, LT, and EQ blocks.
    Based on the comparison, a SUB_UDINT block calculates the difference and updates SoftCounter.VALUE.


Working Principle

Since the physical counter (PIO_SP474_CI1) cannot be reset, the logic uses a reference value (tempCounterValue) to simulate a reset. The SoftCounter reflects the number of pulses counted since the last reset trigger, calculated as:

The below image shows a screenshot of the counter working principle.

Working principle of the counter

This approach ensures accurate pulse tracking while respecting the hardware limitations of SCADAPack I/O.

Schneider Electric Казахстан

Вложения
scadapack474_counter.rcz [162.99 KB]
Узнайте больше
Линейка:
Узнайте больше
Линейка:
  • Документация по продукту
  • Загрузка ПО
  • Система подбора продукции
  • Замена продукта
  • Центр справки и связи
  • Найти наши офисы
  • Получить коммерческое предложение
  • Где купить
  • Сообщество Schneider Electric
  • Карьера
  • Сведения о компании
  • Сообщить о нарушении
  • Доступность
  • Отдел новостей
  • Инвесторы
  • EcoStruxure
  • Поиск вакансий
  • Блог
  • Политика конфиденциальности
  • Уведомление об использовании файлов cookie
  • Change your cookie settings