mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Add basic support for Emerson Netsure Controllers (#12091)
This commit is contained in:
@@ -1183,6 +1183,7 @@ function fahrenheit_to_celsius($value, $scale = 'fahrenheit')
|
||||
* @param string $scale fahrenheit or celsius
|
||||
* @return string (containing a float)
|
||||
*/
|
||||
|
||||
function celsius_to_fahrenheit($value, $scale = 'celsius')
|
||||
{
|
||||
if ($scale === 'celsius') {
|
||||
@@ -1191,6 +1192,15 @@ function celsius_to_fahrenheit($value, $scale = 'celsius')
|
||||
return sprintf('%.02f', $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts string to float
|
||||
*
|
||||
*/
|
||||
function string_to_float($value)
|
||||
{
|
||||
return sprintf('%.02f', $value);
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts uW to dBm
|
||||
* $value must be positive
|
||||
|
Reference in New Issue
Block a user