NetBurner 3.5.8
PDF Version
sensor.h
1/*NB_REVISION*/
2
3/*NB_COPYRIGHT*/
4
5#ifndef SENSOR_H_
6#define SENSOR_H_
7
8/* Build all 8 sensor rows and register every column with the SNMP
9 * agent. Call once from UserMain before anything starts servicing
10 * SNMP requests. */
11void InitSensors();
12
13/* Refresh the row structs with new readings. Call periodically (the
14 * example calls it every 5 s from UserMain's idle loop). No SNMP
15 * plumbing is touched -- the agent picks up new values on the next
16 * read because it holds raw pointers into the row array. */
17void PollSensors();
18
19/* Render the current sensor row contents as one <tr>...</tr> per row,
20 * suitable for embedding inside an HTML <table>. Used by the web UI
21 * (<!--CPPCALL ShowSensorRows --> in html/index.html). Each row is
22 * tagged with class="ok" / "warn" / "fault" based on sensorStatus. */
23void WriteSensorTableRows( int sock );
24
25#endif /* SENSOR_H_ */