root: add rest of sensors as static project. Modbus: debug additions
This commit is contained in:
25
GMP252Sensor/src/GMP252.cpp
Normal file
25
GMP252Sensor/src/GMP252.cpp
Normal file
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* GMP252.cpp
|
||||
*
|
||||
* Created on: 20 Oct 2022
|
||||
* Author: evgenymeshcheryakov
|
||||
*/
|
||||
|
||||
#include "GMP252.h"
|
||||
|
||||
GMP252::GMP252(): sens{240}, regInt{&sens, 0x0100}, regFloat{&sens, 0x0000}{
|
||||
|
||||
sens.begin(9600);
|
||||
|
||||
}
|
||||
|
||||
int GMP252:: read() {
|
||||
int result = regInt.read();
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
GMP252::~GMP252() {
|
||||
// TODO Auto-generated destructor stub
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user