newdevice: Added basic support for Omnitron iConverters (#6336)

* Added basic support for Omnitron iConverters

* Fixed discovery issue & cropped logo
This commit is contained in:
Lorenzo Zafra
2017-04-04 12:02:50 -06:00
committed by Tony Murray
parent 7d656ac4c4
commit 9b62ea2cbf
7 changed files with 34 additions and 0 deletions

View File

@@ -0,0 +1,12 @@
os: omnitron-iconverter
text: 'Omnitron iConverter'
type: management
icon: omnitron
mib_dir:
- omnitron
#over:
#- { graph: device_current, text: 'Current' }
#- { graph: device_voltage, text: 'Voltage' }
discovery:
- sysObjectId:
- .1.3.6.1.4.1.7342.5.

View File

@@ -0,0 +1,14 @@
<?php
// SNMPv2-MIB::sysDescr.1 = STRING: "Omnitron iConverter GM4-HPOE 8991T14F v4.5.28 s/n 00711452 - [x]"
$description = $poll_device['sysDescr'];
preg_match('~Omnitron\siConverter\s(?\'hardware\'.*?)\s(?\'version\'v.*) s\/n~', $description, $matches);
if ($matches['hardware']) {
$hardware = $matches['hardware'];
}
if ($matches['version']) {
$version = $matches['version'];
}