Can a regular 8-bit ATmega replace a Siemens PLC?

The basic task of the PLC controller is to generate control signals in response to changes in input signals, in accordance with the adopted control or regulation algorithm. This reaction depends on the results of arithmetic and logical operations performed for the current values of the controller inputs, its internal variables and the programmed time conditions. It may also depend on operations performed on data transmitted in networks connecting many measuring elements, drivers, regulators or computers.

ATmega 1284 microcontroller

Some theoretical information about the ATmega microcontroller.

The ATmega core is a RISC architecture that has over 130 assembly language instructions. Part of the core is the ALU arithmetic and logic unit. Executes arithmetic, logical and bitwise instructions. ATmega microcontrollers are equipped with a multiplier that operates in only two clock cycles. The ALU has direct access to all working registers, each of which can be used as an accumulator. Even though ATmega is an 8-bit microcontroller, its command word is sixteen bits long. By reading instructions as double-byte words and executing them using pipeline processing, significant performance benefits can be achieved. Since ATmega systems execute most instructions within one clock cycle, processing speeds of up to 1 MIPS (million operations per second) for each 1 MHz of clock frequency can be achieved, especially since the SU 1.5 controller’s central unit is clocked at 14.7456 MHz. Most of these assembly instructions execute in one clock cycle. It has three types of memory: Flash (program memory), SRAM (data memory), EEPROM (non-volatile data memory).

Siemens PLC controller

Theoretical information about the Siemens PLC.

The PLC controller consists of a central unit, an input module and an output module. Input module through which signals from sensors, setters and measuring devices in the facility are introduced to the controller – these signals constitute the controller’s inputs. Output module that transmits calculated control signals to actuating elements and devices – these signals constitute the controller outputs. The central unit, by reading data from the input module and based on the internal program, controls the outputs in the output module. The central unit (CPU) of the PLC controller is not only a microprocessor but also has a program, data memory, and memory for non-volatile data.

Returning to the question at the beginning, can ATmega replace a Siemens PLC?

If we add elements to the ATmega microcontroller (such as drivers, multiplexers, decoders, voltage converters, power stages, filters, converters, display, keyboard, buzzer, galvanic isolation, protections, connectors for connecting cables, housing) that will enable its cooperation with the level of signals used in industrial automation, we will get a controller that will work as efficiently as a Siemens PLC controller. The SU 1.5 controller uses an 8-bit ATmega 1284 microcontroller, thanks to the previously mentioned additional systems, it enables work with signals used in industrial automation.

The table below compares the SU 1.5 PLC and the corresponding Siemens PLC. For comparison purposes, the Siemens controller configuration closest to the SU 1.5 controller was selected.

Peryferia Sterownik SU 1.5 Sterownik PLC Siemens
Jednostka centralna
  • ATmega 1284,
  • pamięć programu 128KB,
  • zegar RTC,
  • czas wykonania instrukcji bitowej 0,067us.
  • Simatic S7-1200, CPU 1212,
  • pamięć programu 50KB,
  • zegar RTC,
  • czas wykonania instrukcji bitowej 0,1us.
  • binarne: 8x24V DC,
  • analogowe: 2 x napięciowe 0..10V DC,
  • temperaturowe: 2xPT100 -50..+160°C.
  • binarne: 8x24V DC,
  • analogowe: 2 x napięciowe 0..10V DC,
  • dodatkowa płytka sygnałowa: 1xPT100.
  • binarne: 4 x przekaźnikowe i 4x24V DC,
  • analogowe: 2 x napięciowe 0..10V DC.
  • binarne: 6x24V DC,
  • dodatkowy mod. rozsz.: 2 x napięciowe lub prądowe.
Komunikacja RS232 lub RS485 Dodatkowy moduł komunikacyjny: RS422/485
Wyświetlacz Tekstowy 2×16 znaków Brak
Klawiatura 6 przycisków Brak
Sygnalizacja akustyczna Buzzer Brak

Comparison of the capabilities of the SU 1.5 controller and the Siemens PLC controller

As can be seen in the table above, the parameters of the ATmega1284 microcontroller and the Siemens controller central unit are comparable, both in terms of program memory and execution speed (with an advantage for ATmega). In order to obtain a number of inputs and outputs in the Siemens PLC controller similar to the number of inputs and outputs in the SU 1.5 PLC programmable controller, the Siemens controller must be equipped with additional modules, which increases the cost of the entire complete Siemens controller, where the central unit itself is not the cheapest. Additionally, the Siemens controller does not have a display, keyboard or acoustic signaling, which allows the SU 1.5 controller to, for example, change operating parameters or display current values and alarms without connecting a computer to the controller. Thanks to this, we do not have to install an additional HMI panel, which significantly reduces investment costs.

Programs for the ATmega microcontroller used in the SU 1.5 controller can be written in assembly language (Atmel Studio), C language (Atmel Studio), Basic language (BASCOM) and in Arduino (Arduino IDE). Apart from Basic, environments for other programming languages are free. However, programs for the Siemens PLC controller can be written in the TIA Portal environment, which is paid.

Returning to the question asked at the beginning of the article, can the 8-bit ATmega efficiently replace the Siemens PLC?

The arguments presented above prove that ATmega can effectively replace the Siemens PLC controller. And the SU 1.5 controller itself also seems to be an attractive controller for applications not only in industrial automation. Thanks to the fast central unit, it can effectively compete with other PLC controllers, e.g. from Siemens. Especially since the programming environments for ATmega are free, and the Siemens PLC controller itself, in a configuration similar to the SU 1.5 controller, is several times more expensive.

Scroll to Top