From: Frank Mori Hess Date: Fri, 28 Mar 2008 21:10:56 +0000 (+0000) Subject: Added wrapper for comedi_internal_trigger(). X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=3b34f5f08d93b6d9eb86f8448d8ba0702ac4945d;p=comedilib.git Added wrapper for comedi_internal_trigger(). --- diff --git a/c++/include/comedilib.hpp b/c++/include/comedilib.hpp index b3fb775..95b5703 100644 --- a/c++/include/comedilib.hpp +++ b/c++/include/comedilib.hpp @@ -405,6 +405,18 @@ namespace comedi return result; } unsigned index() const {return _index;}; + void internal_trigger(unsigned trig_num) const + { + int retval = comedi_internal_trigger(comedi_handle(), index(), trig_num); + if(retval < 0) + { + std::ostringstream message; + message << __PRETTY_FUNCTION__ << ": comedi_internal_trigger() failed."; + std::cerr << message.str() << std::endl; + comedi_perror("comedi_internal_trigger"); + throw std::runtime_error(message.str()); + } + } unsigned max_buffer_size() const { int retval = comedi_get_max_buffer_size(comedi_handle(), index());