00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #include "sensor.h"
00011 Sensor::Sensor(int iMsec)
00012 {
00013 objList = new QObjectList();
00014 objList->setAutoDelete( true );
00015 msec = iMsec;
00016 }
00017
00018 void Sensor::start()
00019 {
00020 if (!timer.isActive())
00021 {
00022 connect (&timer,SIGNAL(timeout()),this,SLOT(update()));
00023 timer.start( (msec == 0)?1000:msec);
00024 }
00025 }
00026
00027 Sensor::~Sensor()
00028 {
00029 objList->clear();
00030 delete objList;
00031 }
00032
00033 void Sensor::addMeter( SensorParams *sp )
00034 {
00035 objList->append(sp);
00036
00037 }
00038
00039 void Sensor::setMaxValue( SensorParams* )
00040 {
00041 }