Manual:The Dude v6/Functions

From MikroTik Wiki
Jump to navigation Jump to search

Applies to RouterOS: v6.34+

Overview

The Functions pane lists all the functions that can be used in the Dude, for example in Charts. You can open up predefined functions so see how they are written. The function language consists of expressions and formulas, similar to Excel spreadsheet formulas. You can use SNMP OIDs and other values when writing a new function.


Adding new functions

Check interface status usign SNMP

Simple command to monitor link state. The last OID digit represents interface number.

if((oid_raw("1.3.6.1.2.1.2.2.1.8.1")=1),"Running", "Down")