| 
									
										
										
										
											2011-04-13 19:23:53 +00:00
										 |  |  | <?php | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2015-07-13 20:10:26 +02:00
										 |  |  | /* | 
					
						
							|  |  |  |  * Observium Network Management and Monitoring System | 
					
						
							| 
									
										
										
										
											2011-09-16 01:58:23 +00:00
										 |  |  |  * Copyright (C) 2006-2011, Observium Developers - http://www.observium.org | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * This program is free software: you can redistribute it and/or modify | 
					
						
							|  |  |  |  * it under the terms of the GNU General Public License as published by | 
					
						
							|  |  |  |  * the Free Software Foundation, either version 3 of the License, or | 
					
						
							|  |  |  |  * (at your option) any later version. | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * See COPYING for more details. | 
					
						
							|  |  |  |  */ | 
					
						
							| 
									
										
										
										
											2011-04-19 16:47:49 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2012-05-25 12:24:34 +00:00
										 |  |  | // Call poll_sensor for each sensor type that we support.
 | 
					
						
							| 
									
										
										
										
											2015-07-13 20:10:26 +02:00
										 |  |  | $supported_sensors = array( | 
					
						
							|  |  |  |     'current'     => 'A', | 
					
						
							|  |  |  |     'frequency'   => 'Hz', | 
					
						
							|  |  |  |     'humidity'    => '%', | 
					
						
							|  |  |  |     'fanspeed'    => 'rpm', | 
					
						
							|  |  |  |     'power'       => 'W', | 
					
						
							|  |  |  |     'voltage'     => 'V', | 
					
						
							|  |  |  |     'temperature' => 'C', | 
					
						
							|  |  |  |     'dbm'         => 'dBm', | 
					
						
							|  |  |  |     'charge'      => '%', | 
					
						
							|  |  |  |     'load'        => '%', | 
					
						
							|  |  |  |     'state'       => '#', | 
					
						
							| 
									
										
										
										
											2016-03-22 10:37:07 -04:00
										 |  |  |     'signal'      => 'dBm', | 
					
						
							| 
									
										
										
										
											2015-07-13 20:10:26 +02:00
										 |  |  | ); | 
					
						
							| 
									
										
										
										
											2011-04-13 19:23:53 +00:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2015-07-13 20:10:26 +02:00
										 |  |  | foreach ($supported_sensors as $sensor_type => $sensor_unit) { | 
					
						
							|  |  |  |     poll_sensor($device, $sensor_type, $sensor_unit); | 
					
						
							| 
									
										
										
										
											2011-09-16 01:58:23 +00:00
										 |  |  | } |