mirror of
https://git.intern.spaceteamaachen.de/ALPAKA/TACOS.git
synced 2025-08-06 01:37:33 +00:00
Added initWatchdog function to startup
This commit is contained in:
@@ -52,11 +52,17 @@ namespace sta
|
||||
* @tparam T The class of the thread to be created. A subclass of TacosThread.
|
||||
* @param states A list of states in which the thread should run.
|
||||
* @param args The constructor arguments for the provided class.
|
||||
*
|
||||
* @return uint16_t A shared pointer to the created thread.
|
||||
*/
|
||||
template<typename T, typename ... Args>
|
||||
void addThread(std::list<uint16_t> states, Args ... args)
|
||||
std::shared_ptr<T> addThread(std::list<uint16_t> states, Args ... args)
|
||||
{
|
||||
Manager::instance()->registerThread(std::make_shared<T>(args...), states);
|
||||
std::shared_ptr<T> thread_ptr = std::make_shared<T>(args...);
|
||||
|
||||
Manager::instance()->registerThread(thread_ptr, states);
|
||||
|
||||
return thread_ptr;
|
||||
}
|
||||
} // namespace tacos
|
||||
}
|
||||
|
Reference in New Issue
Block a user