24 #include <sys/siginfo.h> 25 #include <sys/neutrino.h> 34 m_made_periodic(false),
41 "Could not create timer channel." <<
endl);
55 "No timer channel available! Cannot make this thread periodic!" <<
endl);
59 struct sigevent event;
62 coid = ConnectAttach(0, 0,
m_chid, 0, 0);
66 "Could not attach to the timer channel! Cannot make this thread periodic!" <<
endl);
70 SIGEV_PULSE_INIT(&event, coid, SIGEV_PULSE_PRIO_INHERIT,
ePT_PULSE_TIMER, 0);
72 int res = timer_create(CLOCK_REALTIME, &event, &
m_timerid);
76 "Could not create timer! Cannot make this thread periodic!" <<
endl);
91 struct itimerspec timer;
94 timer_settime(
m_timerid, 0, &timer, NULL);
106 rcvid = MsgReceivePulse(
m_chid, &msg,
sizeof(msg), NULL);
virtual ~PeriodicThreadImplQNX()
virtual void makePeriodic()
PeriodicThreadImplQNX(const icl_core::TimeSpan &period)
Contains icl_core::thread::PeriodicThreadImplQNX.
Contains logging definitions for the icl_core_thread library.
ThreadStream & endl(ThreadStream &stream)
struct timespec timespec() const
Repesents absolute times.
virtual bool setPeriod(const icl_core::TimeSpan &period)
virtual icl_core::TimeSpan period() const
icl_core::TimeSpan m_period
#define LOGGING_ERROR_C(streamname, classname, arg)
virtual void waitPeriod()