Hi @hard-shovel !
Unfortunately, your advice did not help me. I see in the debugger that an interrupt is continually being processed, but reading the buttons does not happen :(.
Hi @hard-shovel !
Unfortunately, your advice did not help me. I see in the debugger that an interrupt is continually being processed, but reading the buttons does not happen :(.
@hard-shovel Thank you for your explanations!
Tomorrow I'll try it.
@hard-shovel Many thanks for your advice!
I still have one more incomprehensible moment. TTP229 is connected via a two-wire line, and in the settings you need to specify _dv_pin and _rst_pin. What pins should I specify in the settings?
Hello!
Can you please tell me why the node with the TCP229 does not send the Passcode to my gateway.
I see that this node sends the battery level, creates a topic in the mqtt. I see in the debugger in the console that the buttons are being pressed, but nothing happens after that. Unfortunately, for TTP229 devices there is little information in the documentation of the NodeManager and I do not understand what needs to be done to make everything work correctly.
Here is my current code.
// General settings
#define SKETCH_NAME "KeyPad Node"
#define SKETCH_VERSION "1.0.1"
#define MY_DEBUG
// NRF24 radio settings
#define MY_RADIO_NRF24
#define MY_NODE_ID 55
#define MY_RF24_SPI_SPEED (2*1000000ul)
// Advanced settings
#define MY_BAUD_RATE 9600
#define MY_SPLASH_SCREEN_DISABLED
/**********************************
* MySensors gateway configuration
*/
#define MY_MQTT_CLIENT_ID "KeyPad"
/***********************************
* NodeManager modules for supported sensors
*/
#define USE_BATTERY
#define USE_TTP
/***********************************
* NodeManager built-in features
*/
// Enable/disable NodeManager's features
#define FEATURE_DEBUG ON
#define FEATURE_POWER_MANAGER OFF
#define FEATURE_INTERRUPTS ON
#define FEATURE_CONDITIONAL_REPORT OFF
#define FEATURE_EEPROM OFF
#define FEATURE_SLEEP ON
#define FEATURE_RECEIVE ON
#define FEATURE_TIME OFF
#define FEATURE_RTC OFF
#define FEATURE_SD OFF
#define FEATURE_HOOKING OFF
/***********************************
* Load NodeManager Library
*/
#include "NodeManagerLibrary.h"
NodeManager node;
/***********************************
* Add your sensors below
*/
// built-in sensors
SensorBattery battery(node);
SensorTTP ttp(node);
/***********************************
* Main Sketch
*/
// before
void before() {
// setup the serial port baud rate
Serial.begin(MY_BAUD_RATE);
/*
* Configure your sensors below
*/
node.setReportIntervalSeconds(10);
ttp.setPasscodeLength(4);
node.setSleepMinutes(5);
battery.setReportIntervalMinutes(10);
/*
* Configure your sensors above
*/
node.before();
}
// presentation
void presentation() {
// call NodeManager presentation routine
node.presentation();
}
// setup
void setup() {
// call NodeManager setup routine
node.setup();
}
// loop
void loop() {
// call NodeManager loop routine
node.loop();
}
#if FEATURE_RECEIVE == ON
// receive
void receive(const MyMessage &message) {
// call NodeManager receive routine
node.receive(message);
}
#endif
#if FEATURE_TIME == ON
// receiveTime
void receiveTime(unsigned long ts) {
// call NodeManager receiveTime routine
node.receiveTime(ts);
}
#endif
Thank you in advance for your help!
@mfalkvidd said in Suddenly, the node stopped working.:
Many thanks @mfalkvidd!
You were right! Something strange happened to Arduino. Moreover, I was able to write down the cleareepromconfig example and clear the memory, but after this procedure I could not write anything into the memory of Arduino.
I have little experience with Arduino and this happened to me for the first time.
Hi!
Tell me, please, where to look.
The problem is as follows. I launched 5 months ago a network on Nrf24, consisting of a gate and one node based on MySensors. Until yesterday everything worked without problems. Yesterday afternoon, for no apparent reason, the node suddenly fell off. I tried to replace the Nrf24 modules and reflash the ARDUINO Mini Pro atmega328 3.3V - nothing has changed. Capacitors are standing.
Here is a piece of the log at the time of the disappearance of the node:
Feb 8 12:42:44 raspberrypi mysgw: TSF:MSG:READ,1-1-0,s=1,c=1,t=16,pt=0,l=1,sg=0:1
Feb 8 12:42:44 raspberrypi mysgw: Sending message on topic: domoticz/in/MyMQTT/1/1/1/0/16
Feb 8 12:42:48 raspberrypi mysgw: TSF:MSG:READ,1-1-255,s=255,c=3,t=7,pt=0,l=0,sg=0:
Feb 8 12:42:48 raspberrypi mysgw: TSF:MSG:BC
Feb 8 12:42:48 raspberrypi mysgw: TSF:MSG:FPAR REQ,ID=1
Feb 8 12:42:48 raspberrypi mysgw: TSF:PNG:SEND,TO=0
Feb 8 12:42:48 raspberrypi mysgw: TSF:CKU:OK
Feb 8 12:42:48 raspberrypi mysgw: TSF:MSG:GWL OK
Feb 8 12:42:48 raspberrypi mysgw: !TSF:MSG:SEND,0-0-1-1,s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=NACK:0
Feb 8 12:42:51 raspberrypi mysgw: TSF:MSG:READ,1-1-255,s=255,c=3,t=7,pt=0,l=0,sg=0:
Feb 8 12:42:51 raspberrypi mysgw: TSF:MSG:BC
Feb 8 12:42:51 raspberrypi mysgw: TSF:MSG:FPAR REQ,ID=1
Feb 8 12:42:51 raspberrypi mysgw: TSF:CKU:OK,FCTRL
Feb 8 12:42:51 raspberrypi mysgw: TSF:MSG:GWL OK
Feb 8 12:42:51 raspberrypi mysgw: !TSF:MSG:SEND,0-0-1-1,s=255,c=3,t=8,pt=1,l=1,sg=0,ft=0,st=NACK:0
Feb 8 12:42:53 raspberrypi mysgw: TSM:READY:NWD REQ
Feb 8 12:42:53 raspberrypi mysgw: TSF:MSG:SEND,0-0-255-255,s=255,c=3,t=20,pt=0,l=0,sg=0,ft=0,st=OK:
Feb 8 12:42:55 raspberrypi mysgw: TSF:MSG:READ,1-1-255,s=255,c=3,t=7,pt=0,l=0,sg=0:
Feb 8 12:42:55 raspberrypi mysgw: TSF:MSG:BC
Feb 8 12:42:55 raspberrypi mysgw: TSF:MSG:FPAR REQ,ID=1
Feb 8 12:42:55 raspberrypi mysgw: TSF:CKU:OK,FCTRL
Feb 8 12:42:55 raspberrypi mysgw: TSF:MSG:GWL OK
Here's what the node writes in the logs:
0 MCO:BGN:INIT NODE,CP=RNNNA--,VER=2.1.1
4 TSM:INIT
4 TSF:WUR:MS=0
12 TSM:INIT:TSP OK
14 !TSF:SID:FAIL,ID=0
16 TSM:FAIL:CNT=1
18 TSM:FAIL:PDT
10020 TSM:FAIL:RE-INIT
10022 TSM:INIT
In what direction to dig?