Compatibility fixes
This commit is contained in:
parent
be95dbeedc
commit
c24925a4da
@ -7,7 +7,9 @@ namespace Arduino {
|
|||||||
|
|
||||||
#pragma region DRV8833
|
#pragma region DRV8833
|
||||||
|
|
||||||
DRV8833::DRV8833(Configuration config, Thing* parent) : Thing(Type::Undetermined, parent) {
|
DRV8833::DRV8833(Configuration config, Thing* parent) : Thing(parent) {
|
||||||
|
this->type = Type::Undetermined;
|
||||||
|
this->name = "DRV8833";
|
||||||
this->pinStandby = config.standby;
|
this->pinStandby = config.standby;
|
||||||
if (pinStandby != 255)
|
if (pinStandby != 255)
|
||||||
pinMode(pinStandby, OUTPUT);
|
pinMode(pinStandby, OUTPUT);
|
||||||
|
@ -7,8 +7,9 @@ namespace Arduino {
|
|||||||
|
|
||||||
#pragma region Digital input
|
#pragma region Digital input
|
||||||
|
|
||||||
DigitalInput::DigitalInput(unsigned char pin, Thing* parent)
|
DigitalInput::DigitalInput(unsigned char pin, Thing* parent) : Thing(parent) {
|
||||||
: Thing(Type::Undetermined, parent) {
|
this->type = Type::Switch;
|
||||||
|
this->name = "Digital Input";
|
||||||
this->pin = pin;
|
this->pin = pin;
|
||||||
pinMode(this->pin, INPUT);
|
pinMode(this->pin, INPUT);
|
||||||
std::cout << "digital input start\n";
|
std::cout << "digital input start\n";
|
||||||
|
@ -7,7 +7,8 @@ namespace RoboidControl {
|
|||||||
namespace Arduino {
|
namespace Arduino {
|
||||||
|
|
||||||
UltrasonicSensor::UltrasonicSensor(Configuration config, Thing* parent)
|
UltrasonicSensor::UltrasonicSensor(Configuration config, Thing* parent)
|
||||||
: Thing(Type::Undetermined, parent) {
|
: Thing(parent) {
|
||||||
|
this->type = Type::DistanceSensor;
|
||||||
this->name = "Ultrasonic sensor";
|
this->name = "Ultrasonic sensor";
|
||||||
this->pinTrigger = config.trigger;
|
this->pinTrigger = config.trigger;
|
||||||
this->pinEcho = config.echo;
|
this->pinEcho = config.echo;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user