I have been seeing the same issue. Did you find a resolution or open a bug report?
Posts made by mountainman
-
RE: isMetric incorrect on new 2.3.2 serial gateway with HomeAssistant
-
RE: Sensebendermicro.ino verify errors
Thanks @BearWithBeard it is working now.
@BearWithBeard said in Sensebendermicro.ino verify errors:
And finally, sha204_lib_return_codes.h and sha204_library.h can be obtained from the Security Personalizer sketch. If you're going to copy and paste those files into the Arduino project folder, you may need to replace the <...> brackets around the included file with "..." (e.g. #include "sha204_library.h"), or else the IDE might not find them.
I forgot I had to change the <...> brackets around the included file with "..." for the referenced libraries when copied locally. I also got platform.io setup so I'm going to transition to using it going forward in order to help pin the dependencies.
-
RE: Sensebendermicro.ino verify errors
Thanks @TRS-80 I started down the path of setting up Platform.io for that reason. Currently using it for building Marlin firmware but have not set it up for the MySensors yet. The library files all appear to be in MySensors Libraries so I don't know why it cannot find them:
sha204_lib_return_codes.h sha204_library.cpp sha204_library.h
-
RE: Sensebendermicro.ino verify errors
@PRGelBueno did you ever resolve the error? I'm seeing the same issue and have gone through the same troubleshooting steps to no avail.
SensebenderMicro:66:10: fatal error: sha204_lib_return_codes.h: No such file or directory #include <sha204_lib_return_codes.h> ^~~~~~~~~~~~~~~~~~~~~~~~~~~ compilation terminated. exit status 1 sha204_lib_return_codes.h: No such file or directory
Thanks,
Brendan -
RE: Sleep() Caused Insomnia when assisted by interrupts
I think I might be having a similar issue on the slim node. It seems to work fine when pulled down by the circuit but enters an endless loop between the time based interrupt and pin when the circuit is open and being pulled up.
What value of resistor are using for you pull up and were you having the issue on both rising/falling edge?
-
RE: Multimeter recommendation?
Temped by EEVblog BM235 Multimeter especially given it comes with some nice silicone leads.
https://www.eevblog.com/product/bm235-multimeter/
The flukes are very nice though!
-
RE: Help with W5100 Resetting with Domoticz
@sundberg84 I updated MY_GATEWAY_MAX_CLIENTS from 1 to 4 in MyConfig.h
This might help with you secondary controller issue.
-
RE: Help with W5100 Resetting with Domoticz
@sundberg84 For me running MSysC appears to have no impact although it will eventually lock up also (1 hr+). What revision of the libraries are you using? The ethernet gateway used to handle 4 connections simultaneously which I think may be configurable in the dev branch.
-
RE: Help with W5100 Resetting with Domoticz
Thanks for the reply sunberg84.
I have Myscontroller and openLuup but even with them off I get the same reset behaviour. I'm actually running Domoticz in response to openLuup locking up on sensor inclusion. Do your logs look similar (resets every 30 seconds) if you have a secondary controller running?
-
Help with W5100 Resetting with Domoticz
I have an ethernet gateway setup using an Uno with the Wiznet W5100 Shield (one with SD Card Slot). Previously been using it with Vera but due to UI7 getting corrupted during an upgrade looking to transfer to either Domoticz or openLupp.
Currently attempting to get this working on the development branch but was seeing the same behaviour on 1.5 stable branch.
In Domoticz I am connecting to the gateway but it resetting the connection every 30 seconds:
2016-02-06 12:38:24.261 MySensors: connected to: 192.168.172.66:5003
2016-02-06 12:38:26.261 MySensors: Gateway Ready...
2016-02-06 12:38:26.261 MySensors: VERSION from NodeID: 0, ChildID: 255, Payload: 2.0.0-beta
2016-02-06 12:38:27.262 MySensors: VERSION from NodeID: 0, ChildID: 255, Payload: 2.0.0-beta
2016-02-06 12:38:30.262 (My Sensors) Lighting 2 (Security Sensor)
2016-02-06 12:38:33.262 (My Sensors) Lighting 2 (Security Sensor)
2016-02-06 12:38:56.267 MySensors: Connection reset!
2016-02-06 12:38:56.267 TCP: Reconnecting in 30 seconds...
2016-02-06 12:39:26.270 TCP: Reconnecting...Constant loop of the above in the Domoticz log.
The serial log from the gateway
0;255;3;0;9;Starting gateway (RNNGA-, 2.0.0-beta)
0;255;3;0;9;Radio init successful.
IP: 192.168.172.66
0;255;3;0;9;Init complete, id=0, parent=0, distance=0
0;255;3;0;9;Eth: connect
0;255;3;0;9;Eth: 0;0;3;0;2;
0;255;3;0;9;read: 5-5-0 s=255,c=3,t=0,pt=1,l=1,sg=0:42
0;255;3;0;9;read: 5-5-0 s=1,c=1,t=0,pt=7,l=5,sg=0:22.9
0;255;3;0;9;read: 5-5-0 s=2,c=1,t=1,pt=2,l=2,sg=0:26
0;255;3;0;9;Eth: 0;0;3;0;2;Get Version
0;255;3;0;9;Eth: 0;0;3;0;18;PING
0;255;3;0;9;Eth: 0;0;3;0;18;PING
0;255;3;0;9;Eth: 0;0;3;0;18;PING
0;255;3;0;9;Eth: connect
0;255;3;0;9;Eth: 0;0;3;0;2;
0;255;3;0;9;Eth: 0;0;3;0;2;Get Version
0;255;3;0;9;Eth: 0;0;3;0;18;PING
0;255;3;0;9;Eth: 0;0;3;0;18;PING
0;255;3;0;9;Eth: 0;0;3;0;18;PING
0;255;3;0;9;Eth: connectI have tried various settings regards SOFTSPI and MY_W5100_SPI_EN but it is still behaving the same. Is this normal or can you please recommend what I should be looking at for troubleshooting?
-
RE: MQTT and Mysensors gateway All in one
Is it possible to use the same sensors with both ethernet and MQTT? I am currently using the ethernet gateway with vera but I would like to try MQTT/OpenHab. I would like to see the same sensors in both environments. Is the possible use the mutt gateway with vera?
Thanks in advance.
-
RE: My own board (50mm x 30mm)
http://dirtypcbs.com/about.php
If you need a specific quantity of boards the use a more expensive board house. The proto pack will be 10 +/- 1 boards.
-
RE: Relay & Sensor Battery powered
You could use a bi-stable latching relay which would not draw power after it finished actuating.
-
RE: implementing multiple sensors
The battery percentage is associated with the parent Arduino Node in the vera UI.
I have some LDRs ordered from Ebay so that is the next step. I had previously used the BH1750 I2C sensor in a multi sensor with the 1.3 lib but I want to debug on its own as it seemed to be giving unexpected readings.@codenea The instructions are pretty much from the main page although if I get a chance I try to draw it up and post some pics. My setup not very pretty yet with perf board and jumper wires. A dedicated PCB would be nice.
-
RE: implementing multiple sensors
Here is a version I'm currently using that makes use of interrupts so might be more suitable for a battery driven DHT/Motion multi sensor. It also includes the battery monitoring. Any feedback or improvements would be appreciated.
#include <SPI.h> #include <MySensor.h> #include <DHT.h> #define CHILD_ID_HUM 0 #define CHILD_ID_TEMP 1 #define CHILD_ID_MOTION 2 // Id of the sensor child #define HUMIDITY_SENSOR_DIGITAL_PIN 4 #define DIGITAL_INPUT_SENSOR 3 // The digital input you attached your motion sensor. (Only 2 and 3 generates interrupt!) #define INTERRUPT DIGITAL_INPUT_SENSOR-2 // Usually the interrupt = pin -2 (on uno/nano anyway) unsigned long SLEEP_TIME = F; // Sleep time between reports (in milliseconds) int BATTERY_SENSE_PIN = A0; // select the input pin for the battery sense point int oldValue=-1; MySensor gw; DHT dht; float lastTemp; float lastHum; boolean metric = false; int oldBatteryPcnt = 0; int battLoop =0; MyMessage msgHum(CHILD_ID_HUM, V_HUM); MyMessage msgTemp(CHILD_ID_TEMP, V_TEMP); // Initialize motion message MyMessage msg(CHILD_ID_MOTION, V_TRIPPED); boolean pinTriggered=0;//waitTime is number of seconds to hol in while loop long lastDebounceTime = 0; // the last time the output pin was toggled long debounceDelay = 50; // the debounce time; increase if the output flickers void setup() { // use the 1.1 V internal reference analogReference(INTERNAL); gw.begin(); dht.setup(HUMIDITY_SENSOR_DIGITAL_PIN); // Send the Sketch Version Information to the Gateway gw.sendSketchInfo("Motion Humidity w/ Batt", "1.0"); // Register all sensors to gw (they will be created as child devices) gw.present(CHILD_ID_HUM, S_HUM); gw.present(CHILD_ID_TEMP, S_TEMP); gw.present(CHILD_ID_MOTION, S_MOTION); pinMode(DIGITAL_INPUT_SENSOR,INPUT); // sets the motion sensor digital pin as input digitalWrite(DIGITAL_INPUT_SENSOR,HIGH); // Activate internal pull-up metric = gw.getConfig().isMetric; check_batt(); } void loop() { if (pinTriggered) { Serial.println(millis()-lastDebounceTime); // Read digital motion value boolean value = digitalRead(DIGITAL_INPUT_SENSOR); // If the switch changed, due to noise or pressing if (value != oldValue) { { lastDebounceTime = millis(); // Send in the new value gw.send(msg.set(value==HIGH ? 1 : 0)); battLoop++; oldValue = value; Serial.print("Mot: "); Serial.println(value); } } pinTriggered=0; // } } else { delay(dht.getMinimumSamplingPeriod()); float temperature = dht.getTemperature(); if (isnan(temperature)) { Serial.println("Failed reading temperature from DHT"); } else if (temperature != lastTemp) { lastTemp = temperature; if (!metric) { temperature = dht.toFahrenheit(temperature); } gw.send(msgTemp.set(temperature, 1)); battLoop++; Serial.print("T: "); Serial.println(temperature); } float humidity = dht.getHumidity(); if (isnan(humidity)) { Serial.println("Failed reading humidity from DHT"); } else if (humidity != lastHum) { lastHum = humidity; gw.send(msgHum.set(humidity, 1)); battLoop++; Serial.print("H: "); Serial.println(humidity); } if (battLoop > 10) { check_batt(); battLoop=0; } } // Sleep until interrupt comes in on motion sensor. Send update every two minute. pinTriggered = gw.sleep(INTERRUPT, CHANGE, SLEEP_TIME); } void check_batt() { // get the battery Voltage int sensorValue = analogRead(BATTERY_SENSE_PIN); Serial.println(sensorValue); // 1M, 470K divider across battery and using internal ADC ref of 1.1V // Sense point is bypassed with 0.1 uF cap to reduce noise at that point // ((1e6+470e3)/470e3)*1.1 = Vmax = 3.44 Volts // 3.44/1023 = Volts per bit = 0.003363075 float batteryV = sensorValue * 0.003363075; int batteryPcnt = sensorValue / 10; Serial.print("Battery Voltage: "); Serial.print(batteryV); Serial.println(" V"); Serial.print("Battery percent: "); Serial.print(batteryPcnt); Serial.println(" %"); if (oldBatteryPcnt != batteryPcnt) { // Power up radio after sleep gw.sendBatteryLevel(batteryPcnt); oldBatteryPcnt = batteryPcnt; } }
-
RE: Binarysensor with sleep
Thanks @Yveaux. Its on the list but it be a while before funds recover to get another toy.
Would using a pull-down resistor before more efficient than using the internal pull-up?
-
RE: Binarysensor with sleep
I'm just running the current though a fluke 189 so likely not very accurate vs the uCurrent. Should give rough order of magnitude at least.
Just reran transmit test using the fast min max and peak is now 25mA!
BTW, Did you build the uCurrent yourself?
-
RE: Binarysensor with sleep
I am trying to build a mailbox sensor myself using a reed switch. I have 3.3v mini pro with the regulator cut per the battery power directions. (http://www.mysensors.org/build/battery).
Modified the binary sketch to wake on interrupt on pin 3. Currently I have all the de-bounce logic commented out to make the interrupt work. What issues might this cause and should I be looking at adding debounce back in?
Measuring current when sleeping with magnetic target far (i.e. open circuit) I am reading 7.6 uA and ~100 uA when it is target near. Ideally i would like these reversed as the sensor will spend the majority of it time with target near. Is there anything I can do to reduce the target near current, such wiring a external resistor?
One option would be to find some normally closed reed switches but I wanted to explore other options first.
BTW, Peak current when radio is transmitting is 6.13 mA.
Thanks,
Brendan