reafectored stuff and corrected shit to make everything compiling
This commit is contained in:
@@ -7,6 +7,8 @@
|
||||
|
||||
#include "Solenoid.h"
|
||||
|
||||
#include <thread>
|
||||
|
||||
namespace flippR_driver
|
||||
{
|
||||
namespace output
|
||||
@@ -14,10 +16,9 @@ namespace output
|
||||
namespace items
|
||||
{
|
||||
|
||||
Solenoid::Solenoid(std::shared_ptr<utility::IOutputGPIOInterface> output_gpio_interface, unsigned int address, unsigned int i2c_address, unsigned int data_pin, std::string name, std::chrono::milliseconds deactivation_time)
|
||||
:
|
||||
OutputItem(output_gpio_interface, address, i2c_address, data_pin, name),
|
||||
deactivation_time(deactivation_time)
|
||||
Solenoid::Solenoid(std::shared_ptr<utility::IOutputGPIOInterface> output_gpio_interface, unsigned int address, unsigned int i2c_address, unsigned int data_pin, std::string name, std::chrono::milliseconds deactivation_time):
|
||||
OutputItem(output_gpio_interface, address, i2c_address, data_pin, name),
|
||||
deactivation_time(deactivation_time)
|
||||
{}
|
||||
|
||||
void Solenoid::triggerTask()
|
||||
@@ -31,7 +32,7 @@ void Solenoid::triggerTask()
|
||||
|
||||
void Solenoid::trigger()
|
||||
{
|
||||
std::async(std::launch::async, &Solenoid::triggerTask);
|
||||
this->trigger_task = std::async(std::launch::async, &Solenoid::triggerTask, this);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user