Analog Table and Operations

From Mikrodev Documentation
Jump to navigation Jump to search
Download Project Files

What You Need to Know Before Design

Diagram Algorithm

  • The analog values read out for periods of five seconds will be collected. The values will be maximum 30 pieces. In the readings above 30 pieces, the first written value will be deleted and the last read value will be written. The system will operate when digital input 0 is activated, it will stop when it is disabled.

Diagram Solition

analog_table.png

  • Analog input value was be read with AI0.
  • If the system is on (when DI0 is in high signal state), the system will be triggered by the signal from the timing trigger and through the And gate.
  • An analog table was created with an array of 30 values. Each rising edge to the Clk input of the analog table block will read the new value from AI0. When analog table type FIFO is selected and 30 table size is filled, the last read value will be overwritten with the first read value.
  • Analog table operation block also collects the values in the table.