mirror of
https://github.com/thelsing/knx.git
synced 2024-12-18 19:08:18 +01:00
add writeMemory to facade, remove debug output from platform
This commit is contained in:
parent
6334bfe3cb
commit
dc362a79c3
@ -34,18 +34,18 @@ void measureTemp()
|
||||
currentValue *= 100 * 100;
|
||||
|
||||
// write new value to groupobject
|
||||
goCurrent.objectWriteFloat(currentValue);
|
||||
goCurrent.objectWriteFloatDpt9(currentValue);
|
||||
|
||||
if (currentValue > maxValue)
|
||||
{
|
||||
maxValue = currentValue;
|
||||
goMax.objectWriteFloat(maxValue);
|
||||
goMax.objectWriteFloatDpt9(maxValue);
|
||||
}
|
||||
|
||||
if (currentValue < minValue)
|
||||
{
|
||||
minValue = currentValue;
|
||||
goMin.objectWriteFloat(minValue);
|
||||
goMin.objectWriteFloatDpt9(minValue);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -76,7 +76,7 @@ void EspPlatform::closeMultiCast()
|
||||
|
||||
bool EspPlatform::sendBytes(uint8_t * buffer, uint16_t len)
|
||||
{
|
||||
printHex("<- ",buffer, len);
|
||||
//printHex("<- ",buffer, len);
|
||||
int result = 0;
|
||||
result = _udp.beginPacketMulticast(_mulitcastAddr, _mulitcastPort, WiFi.localIP());
|
||||
result = _udp.write(buffer, len);
|
||||
@ -97,7 +97,7 @@ int EspPlatform::readBytes(uint8_t * buffer, uint16_t maxLen)
|
||||
}
|
||||
|
||||
_udp.read(buffer, len);
|
||||
printHex("-> ", buffer, len);
|
||||
//printHex("-> ", buffer, len);
|
||||
return len;
|
||||
}
|
||||
|
||||
|
2
src/knx
2
src/knx
@ -1 +1 @@
|
||||
Subproject commit f50f03ad6edaa73c6bc41496de696e1d7306b30b
|
||||
Subproject commit fd2334a4af59e9cea5325d399afc639517a5d41a
|
@ -9,6 +9,7 @@ KnxFacade knx;
|
||||
KnxFacade::KnxFacade() : _bau(_platform)
|
||||
{
|
||||
manufacturerId(0xfa);
|
||||
_bau.addSaveRestore(this);
|
||||
}
|
||||
|
||||
bool KnxFacade::enabled()
|
||||
@ -61,6 +62,11 @@ void KnxFacade::readMemory()
|
||||
_bau.readMemory();
|
||||
}
|
||||
|
||||
void KnxFacade::writeMemory()
|
||||
{
|
||||
_bau.writeMemory();
|
||||
}
|
||||
|
||||
void KnxFacade::loop()
|
||||
{
|
||||
if (currentState)
|
||||
@ -108,7 +114,7 @@ void KnxFacade::start()
|
||||
|
||||
pinMode(_buttonPin, INPUT);
|
||||
attachInterrupt(_buttonPin, buttonDown, FALLING);
|
||||
|
||||
|
||||
switchToSate(noWifiState);
|
||||
checkStates();
|
||||
_ticker.attach_ms(100, doLed);
|
||||
|
@ -21,6 +21,7 @@ public:
|
||||
uint32_t buttonPin();
|
||||
void buttonPin(uint32_t value);
|
||||
void readMemory();
|
||||
void writeMemory();
|
||||
void loop();
|
||||
void knxLoop();
|
||||
void registerGroupObjects(GroupObject* groupObjects, uint16_t count);
|
||||
|
Loading…
Reference in New Issue
Block a user