Skip to content

Commit

Permalink
div 1000 for logging voltmeter
Browse files Browse the repository at this point in the history
  • Loading branch information
jantje committed Jun 22, 2017
1 parent d1cde2e commit e30fb72
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions SerialDataInterface/SerialDataInterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ const char STATENAME[] PROGMEM="StateName";
const char STATE[] PROGMEM="State";
const char MULTIPLIER[] PROGMEM ="Multiplier";
const char MULTIPLIER_DIV_10[] PROGMEM ="Multiplier/10";
const char MULTIPLIER_DIV_1000[] PROGMEM ="Multiplier/1000";

const char PINVALUE[] PROGMEM ="PinValue";
const char PIN[] PROGMEM = "Pin";
Expand Down
2 changes: 2 additions & 0 deletions SerialDataInterface/SerialDataInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ extern const char DONE[]PROGMEM;
extern const char STATENAME[] PROGMEM;
extern const char STATE[] PROGMEM;
extern const char MULTIPLIER_DIV_10[] PROGMEM;
extern const char MULTIPLIER_DIV_1000[] PROGMEM;

#define CLASSSEPERATOR '.'
#define FIELDSEPERATOR ';'
#define FP(name) ((const __FlashStringHelper *)(name))
Expand Down
2 changes: 1 addition & 1 deletion VoltMeter/VoltMeter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ void VoltMeter::loop()
void VoltMeter::serialRegister(const __FlashStringHelper* Name)
{
FieldData::set(Name,F("CentiVolt"),0,&myCentiVolt);
FieldData::setNext((__FlashStringHelper *)MULTIPLIER,MOD_WRITE|MOD_SAVE,&myMultiplyerValue);
FieldData::setNext((__FlashStringHelper *)MULTIPLIER_DIV_1000,MOD_WRITE|MOD_SAVE,&myMultiplyerValue);

#ifdef DETAILED_SERIAL_LOGGING
FieldData::setNext(F("Value"),0,&myActualReadValue);
Expand Down

0 comments on commit e30fb72

Please sign in to comment.