I like the joke : )
I'll try to keep it simple. Most of my sensors are just reporting temperature and humidity. Since I can assign them to a room in home assistant. They don't need anything fancy.
I like the joke : )
I'll try to keep it simple. Most of my sensors are just reporting temperature and humidity. Since I can assign them to a room in home assistant. They don't need anything fancy.
I moved my MySensors nodes from Domoticz to Home Assistant. Domoticz didn't really do anything with the sketch name. Home Assistant uses it in the device names.
I had named my sketches by processor and function, BT8_BME280 for example. This makes sense when programming, but makes the device names in Home Assistant seem rather random.
I can have the sketch present anything want for a sketch name. Maybe using just the node function would be better?
Anyone have a naming system that makes sense in Home Assistant?
Update. There is a lot of thinking about this online. For example: https://github.com/Trikos/Home-Assistant-Naming-Convention
But also, I can rename in home assistant, so doing it in the sketch isn't that important.
Your analysis of the problem seems correct.
This sounds very frustrating, and I am afraid I can't help much.
From your earlier post, the transport is just shutting down because it had too many failed attempts to find a parent. That is normal operation. My memory is that it will just try again after a while.
Nice. I know there are RFM69's, but I've seen quite a few requests for the CC1101. Always good to have options.
I did something similar with the WIO-E5 chips in my repo. The E5 is not quite ready for prime time, but the basics are working.
I have many MySensors nodes, and still adding more. Good to see some new code for it.
@Meldrew-s-mate Hi. This site is about building sensors using Arduino that report data back wirelessly to a gateway. There may be some useful information here, but it doesn't sound like what you are really looking for. Try searching on the web for Cerbo GX and Home Assistant. Home Assistant is a popular home control program. Someone may have already figured out how to connect to it, or you might get a link to something helpful.
@lostintheethes Sounds like a nice set up. I have had good luck with bme280's without doing anything special. I usually get about a year out of a coin cell battery. I check the temperature every 3 minutes, but I don't send unless it changes more than .1 I haven't really tested accuracy, but it seems about right.
Has anyone developed a PA LNA driver for the BT832X (Fanstell NRF5 module)? Works quite well without it, but wondering if could be even better.
@NeverDie , you had a remote control using PA. Was there any additional code for that from stock MySensors NRF5? Did you ever do anything with the LNA part?
: ) That looks right. I have not written a receiveTime function for years and have just been copying the one in MockMySensors over and over.
I have found that controllers can be very slow to respond to time requests. Same experience for Domoticz and for Homeassistant. Try a wait(1500) after the time request.
I didn't see anything obviously wrong, so I tried compiling your code. Your code compiled fine for me. I used ESP8266 Boards (2.5.0-Beta3) -> Generic ESP8266 Module.
Unfortunately, that doesn't help much with figuring out why your compiler is giving the error.
This is only a partial answer.
You have to implement a function on the node to receive the data: void receive(const MyMessage &message)
Go to this page https://www.mysensors.org/download/sensor_api_20 and scroll down to "Handling incoming radio messages".
I'm pretty sure I have seen someone on this site doing exactly what you are looking for, but I didn't find it when I looked. They had a node with an LCD display they could send text to.
Hope this gets you started : )
Another thing to check if you updated MySensors after a long time. The update overwrites the MyConfig.h file. If you had any custom settings in that file, you have to go back and reset them. This used to get me because I use 915Mhz with the RFM69 radios. Updates would change it back to the default, and I would have to go change it back.
Quick Range Check on the WIO-E5-LE. The LE version uses only the low power PA, +14dBm max. Using the default settings except for 915MHz
#define MY_SX126x_FREQUENCY (SX126x_915MHZ)
#define MY_SX126x_LORA_SF LORA_SF7
#define MY_SX126x_LORA_BW LORA_BW_125
#define MY_SX126x_LORA_CR LORA_CR_4_5
I get about 190 meter range, just walking around the neighborhood, line of site except for some trees and power lines.
No tuning on the antenna. Just using a 77.9mm wire.
Not as dramatic as some have achieved with LoRa radio's, but plenty good enough for my house and yard : )
@GLAB You can set the frequencies using the settings in MyConfig.h, which is in the MySensors folder. If you put any of the defines from MyConfig.h into your sketch, they will override the MyConfig.h setting for that sketch only.
If you are using the RF24 radio, there are different channels which correspond to a given frequency. The default is channel 76. There is a list of typical channels in MyConfig.h. If you want to change the channel for all the sketches, change it in MyConfig.h. If you want to change it just for the sketch, add a define to the sketch. For example:
#define MY_RF24_CHANNEL (84)
The problem with changing the channel in a sketch is that the gateway has to be on the same channel to receive from the node. So, normally it makes sense to change in MyConfig.h because you usually want the gateway and all the nodes on the same channel.
Other radio's like the RFM69 list the frequency instead of using a channel. They can be overridden in the sketch as well. You can find the defines that are needed in MyConfig.h
Sounds like a challenging problem. Maybe an air quality sensor would help? I don't know if pot smoke would trigger one of those at the levels you are concerned about. The BME680 is supposed to be a good sensor for air quality. I haven't used it, and some others on this site have not been that impressed. See this thread: https://forum.mysensors.org/topic/12197/best-voc-sensor-for-detecting-a-wide-range-of-voc-s
Maybe look at some law enforcement sites to see if there is anything they use (besides dogs : ).
Adding my thanks!
I know it's been quiet around here lately, but my google site search of the MySensors site is still one of my most used links.
If you haven's already, add #define MY_DEBUG to your sketch. Then, look at the serial output from the node.
If you see sancheck fail, then something is probably wrong with the wiring.
You can also paste the serial output into the decoder here: https://www.mysensors.org/build/parser
That should give you more readable info about what is gong on.
You should be able to add up to 254 nodes on one gateway.
You might be able to get some info from the Domoticz log. In Domoticz, go to Setup->Log.
If you reset your new node, you should see messages showing the presentation info and maybe the first values.
If you don't see that, double check your hardware.
If you do see it, it should be in the Setup->Devices list.
@Nicklas-Starkel
8 years -- amazing! I have temperature sensors that get over 2 years on a pair of AA batteries, but they do read every 3 minutes: )
Hi All,
I have been messing around with a module called the Wio-E5 from Seeed Studio.
Ever since the NRF5 series came out I have wanted something similar but with a LoRa or RFM69 radio. The Wio-E5 looked like just the thing:
https://www.seeedstudio.com/LoRa-E5-Wireless-Module-Tape-Reel-p-5302.html
https://wiki.seeedstudio.com/LoRa-E5_STM32WLE5JC_Module/
Cortex-M4 processor and SX1262 radio on a chip (STM32WLE5 series)
Supposedly low power consumption (still testing).
The module is small, but hand solderable package.
I finally have one of these running as a coin cell powered temperature / humidity sensor.
My very basic E5 node and gateway
I have been able to get it to talk to my RMF95 gateway also.
If you want to give it a try, I have added code to the MySensors fork on my github: https://github.com/spike314/MySensors
in the development branch.
You will need:
And, there you go!
It's all still a bit rough. I'll post some more notes and sample code when I get a chance.
Happy New Year!
Wow. Has it been 5 years?
I haven't really used development because master has been working for me. Just added some new NRF5 nodes a couple of weeks ago.
@karlheinz2000
Sorry I missed your original post. I've used the WhiskyDelta code successfully for gateways using the 401 and 411. Glad you found it.
Hi @adds666 . I think it is this bit in the receive() function near the bottom of the code. It gets the value from the V_PERCENTAGE message and maps into the setPattern value:
case RGB_NextPatternChild: // next pattern if (message.type == V_PERCENTAGE) { // Percentage indicates the pattern setPattern = map(message.getInt(), 0, 100, 0, 15) % lastPatternIdx ; // mapper dimmer value to state 0..9 and wrap setLightPattern((setPattern), 500 ); Sprint("Pattern: ") ; Sprintln(setPattern) ; } else if (message.type == V_STATUS){ // if off switch pattern to default == 0 setPattern = 0 ; setLightPattern((setPattern), 500 ); Sprint("Pattern: ") ; Sprintln(setPattern) ; } break ;
Ah ha. It worked. Updated the 250KBS callouts per the pull request.
NRF5 communicates normally.
Thanks!
Thanks @mfalkvidd I'll check these out.
I'm seeing an upgrade to 1MBS in my future, but I have a lot on nodes that would need to be updated. I'll probably put that off as long as I can : )
Hi All,
I have not been able to connect my NRF52832 nodes to the gateway when using the MySensors development branch. I used the MySensors PassiveNode sketch to run some tests. It is a very simple sketch that sends random temperature readings. I tried the basic passive node, commenting out passive node, and disabling the uplink check on using both branches. Results:
So the node appears to have some difficulty receiving messages from the gateway and has different issues between Master and Development branches. I have done some diffs of likely files but nothing jumps out at me as a suspicious difference between Master and Development.
I'm using MY_RADIO_NRF5_ESB and assigning a static node number.
I have to define MY_NRF5_ESB_MODE (NRF5_250KBPS) when using the Development Branch because my network is 250KBPS. I know this is deprecated. Could the low data rate be causing the receive issues?
Can anyone point me to next steps for troubleshooting?
I realize I hadn't paid that much attention to the rated shelf life of the batteries. More than a year on a battery seemed good enough. But now I need to shop around. Maybe a less cheap coin cell would actually be cheaper in the long run.
My Subaru remote key fob battery goes dead frustratingly often. I was blaming the fob, but maybe that is unfair. Going to buy a better quality coin cell next time.
I'm amazed what can be done with the basic low power instructions on the MySensors site. I have played with a few different types of batteries all in low power temperature nodes.
2 x Alkaline AA. I routinely get more than 2 years with arduino pro mini and dallas sensor.
LIFEPO4 AAA. This is a really weird battery. I got about 10 months out of it. Difficult size to find. i would stick with AA.
I have an LIFEPO4 AA powered node, but don't have good data on it. Over a year.
CR2032 coin cell. I get over a year using NRF5 and BME280.
The LIFEPO4 is nice for PIR nodes because they have very flat voltage curve around 3.2 to 3 volts. And rechargeable.
Check out the Hammond 1551V1gY (vented) or 1151SNAP1GY (unvented).
They look like they are about the same size. I've been using the vented ones for temp/humidity sensors. Not as ugly as most project boxes.
This seems to be a fairly common problem with PIR motion sensors.
One trick is to add a short sleep statement before your final one to let all the voltages settle:
// Short sleep to let voltages settle (change duration as needed)
sleep(500);
// Sleep until interrupt comes in on motion sensor. Send update every ten seconds for testing.
sleep(digitalPinToInterrupt(DIGITAL_INPUT_SENSOR), CHANGE, 10000);
code_text
Thanks. I'll have to try them out. It is crazy how cheap it has become at least for small prototypes.
I've been using something that looks similar called Command Strips.
They work pretty well, but there are a few downsides.
That said, I have had better luck with these than sticky-both-sides tape or other kinds of velcro.
How is the shipping time vs cost for JLCPCB and PCBway?
I'm in the US and just ordering small prototype numbers, so OshPark works well for me. But I am thinking of a larger qty order at some point.
That is odd. I have one that I bought a year or so ago. Looks just like yours, from what I can tell from the photo. But it works with the pinout as labeled.
@NeverDie Interesting chip for a sensor node. All the other NRF52s have way more capability than we are likely to use in a low power sensor node. The 52805 seems to have just enough. Hope you are able to make some progress.
After correcting a wiring error (duh!) I was able to erase using my J-Link Mini EDU.
I used Nordic's nrfjprog:
nrfjprog --family NRF52 --recover
nrfjprog --family NRF52 --recover
I had to run it twice to get the unlock. I think this makes sense after reading the devzone article.
Once unlocked, I could use my black magic probe for programming. I expect the blackmagic folks haven't had time to adapt to the new lock scheme yet.
With respect to initial erase of NRF52, I have been using @BearWithBeard Black Magic Probe instructions successfully for years. But, my latest set of Minew boards doesn't respond.
I found that there is a new lock procedure from Nordic:
I have tried upgrading my gdb and also J-Link EDU and nrfjprog tool chains and have not successfully connected to the new boards yet.
Has anyone had success with unlocking one of these new boards?
@ejlane
Yeah. I did this a while ago and I will have to dig into my notes to figure it out. I don't recall how I combined the STM code with tekka's multiple transport (which i think was in the development branch already), but it was not much more than cut and paste. I have an NRF24 and an RFM69 running on one and an RFM95 on another. I can figure out the details when I get back home in May.
I have a multi-transport gateway running on an STM32F411 black pill using the KooLru code with arduino. It pretty much just worked.
I don't know about sleep however. I've mostly used the blue pills and black pills for powered things like gateways.
There is also this: https://github.com/mysensors-rus/STM32_Mysensors_bootloader
Which makes me think a MCU/LoRA with potential for OTA updates is not far out of reach.
But it would take a better coder than me : )
I'm wondering if anyone has experience with the SEEED LORA-E5 Module, or the STM32WLE5JC.
It is an interesting looking module:
https://www.seeedstudio.com/LoRa-E5-Wireless-Module-Tape-Reel-p-5302.html
It has STM32WLE5JC, ARM Cortex-M4 and SX126x embedded and is aimed at IOT. Arduino has a Generic STM32WLE5JC board type. Seems like this combo might not be too difficult to slot into MySensors using the RFM95 libraries.
It would be nice to have a sub-gHZ radio and processor in the same module,
Happy New Year to all!
I hope 2022 brings you good times and some fun new IOT projects!
I just downloaded KiCad 6.0 as a present to myself, so I predict some new PCB designs are in my future for 2022 : )
Hi @wackowizzard. Welcome to the MySensors site.
Take a look at some of the projects on OpenHardware.io https://www.openhardware.io/explore It will give you many examples of different sensor projects. Most projects just do one thing. Temperature and Humidity or motion are the most common. A few do use many of the sensors you want. See Berk's https://www.openhardware.io/view/8259/Air-quality-and-weather-forecast-sensor for example.
The MySensors framework is supported by Home Assistant.
Battery or wire power will depend mostly on the power consumption of you sensors. Many can be quite low power and run for years on batteries. This is common topic of discussion in the forums.
If you read through the "Getting Started" and "Build" sections on the MySensors site, you will get a lot of information and ideas about how to build the sensor you described.
@KevinT Very cool.
How does it respond to the PIR. Does it stop the door if it sees motion?
@Max-Kurilov
Hi Max. I can't help with the Vera, but there is a log parser here: https://www.mysensors.org/build/parser
that might make debugging the MySensors messages a little easier.
What the "right" controller is depends a lot on what you are looking for. When I first found MySensors, Vera was pretty much the standard. The controller world has evolved a lot since then. Probably looking at recent posts in the controller forum will give you a sense of what people are using now. I would be interesting to do a true survey.
It's actually at this link posted earlier in the thread: What did you build today (Pictures) ?:
I mostly use it with BME280 modules for temperature and humidity, but I have tried some other I2C modules in it.
I'm still experimenting with the motion detector. That will probably get it's own board at some point. It doesn't really fit the enclosure I designed this board for.
I made a simple board to use as a CR2032 battery simulator. It is actually two identical pcb's back to back. I added pins for applying power and another set for measuring current. Now I need a better ammeter. The uA scale works well when sleeping, but the mA scale doesn't seem to pick up the awake current.
Another outside influence may just be Covid and Work From Home.
I have been very fortunate to be able to work from home over the past year, but I find at the end of the day I abandon my computer and my office and don't return. My hobbies are heavily computer based and have suffered. I often think about new cool sensors and what project to tackle next, but my hobby environment feels too much like my work environment. I'm going to have to rethink that going forward because at least some work from home seems like it will be the new normal.
My stove does not have the ignition cuttoff, and it isn't that old. I am getting a newer one soon. Maybe it will have that feature. I would love to monitor the gas flow, but don't want to mess with the gas line.
I should have thought about heat and not just flame -- good idea. There are some thermal sensors on adafruit that might work, and probably other similar options.
Does anyone have an idea for detecting whether a stove burner is on? I have a stove with gas burners.
I have tried the flame detectors, but the normal flame from the stove is too blue. I want to be able to see a burner that was left on but not wait for the fire that the flame sensors would be good for.
There is an example in the MySensors examples.
https://github.com/mysensors/MySensors/tree/master/examples/PHSensor
This should be fairly straight forward as long as you just want to send the values to Domoticz and don't need the LC display. MySensors supports a water quality sensor that includes temperature and pH variables.
You would present S_WATER_QUALITY and send the temperature values as V_TEMP messages and the pH values as V_PH messages.
See table here: https://www.mysensors.org/download/serial_api_20#variable-types
I checked the Domoticz release notes and it says this type of meter is included for MySensors. But, I have not tried it.
Oops. I wasn't very clear.
My split coil has a cable with an audio plug on the end. Like this one:
https://www.electrodragon.com/product/yhdc-non-invasive-ac-current-sensor-100a30a/
So I used an audio jack on the board to plug the split coil into. That makes it easy to swap different rating coils. The picture above is 100A, but I'm using the 30A coil for the car charger.
Then the coil goes around one of the power wires going out to the charger.
A real car : )
Roll your own MySensors version can be surprisingly simple from a hardware perspective. I did this to monitor my electric car. Plug a split coil to the audio jack:
The thinking about it part, not so easy! Good reference site:
https://learn.openenergymonitor.org
C and R depend on your split coil. Calibration is a real challenge. For my car, I know what it draws from plugging into commercial chargers, and I was not worried about precision. For unknown loads around the house, you would have to have something known to calibrate against. Also, the coil has to go around 1 leg of the power wiring. which means you need an adapter cable with the line and neutral split out (but still insulated).
Hi @electrik
You can program these ibeacons to work with MySensors.
I reprogrammed one by soldering some wires to a jlink adapter. Not elegant, but it worked.
Some type of push pin setup would be good if you are going to actually use these modules.
The version I got had only a button on the board, and no way to easily add any other sensors, so they weren't very useful. It would be interesting to try the ones with the temperature and acceleromator.
@berkseo
Hey. Our own berkseo is on Hackaday. Congrats!
https://hackaday.com/2021/03/11/nrf52-weather-station-gives-forecast-with-style/
The Hammond 1551V series are good for a coin cell based temperature / humidity sensor:
https://www.newark.com/hammond/1551v1gy/enclosure-small-abs-grey/dp/84AC4152?st=1551v
It has just enough room for a NRF5 module, temp/humidity sensor module, and a coin cell battery.
And, it is not too ugly for sticking on a wall in your house.
If you want a little more space for your circuit board, you can go with the 1551v3gy.
@skywatch These used the Fanstel BT832. Not sure about the bootloader. I just programmed them as they came. I programmed them using Arduino and the MySensors MyBoardNRF5 files, and a black magic probe for the programmer.
I know what you mean.
I have several Pi's. I upgraded them from Stretch to Buster using instructions found here https://pimylifeup.com/upgrade-raspbian-stretch-to-raspbian-buster/
I only got the courage to ugrade my domoticz server after having upgraded 3 others first with no problems.
But it did work.
I recently completed an experiment with 2 nearly identical nodes and had very good results just using @NeverDie MySleepPrepare() without any other real effort to reduce power consumption.
The nodes were NRF52832 and BME280. One with a CR2032 Coin cell and the other with a LiFePo4 (AAA size). The CR2032 lasted a little longer in this application.
I stopped when the CR2032 dropped below 1.8V because that was the low voltage rating for both the processor and the BME, but the node still appeared to be working normally.
Vertical axis is volts. Horizontal axis is days.
Wow. Very cool! Now I'm thinking of some similar projects I need to do for Summer.
I have 2 motion sensors on Domoticz, and they both show the battery level.
Maybe it is because your level doesn't get sent often enough. I do send a battery level every 30 minutes even if the value hasn't changed (which is way too often. But, I am still experimenting with these nodes.)
Or, maybe it has to do with the Domoticz version. My Domoticz version is 2020.2
@lood29 Interesting. Looks like I can cut the threshold way down. I'll give that a try.
@lood29
I recently got a PYD1598 sensor up an running. I made a lot of guesses at the settings and would like to hear what you are using. I wound up with:
Pulse Detection Mode 0 = signal has to exceed the threshold and change of sign
High Pass Filter Freq. 1 = 0.2 Hz
Filter Source 0 = PIR (BPF)
Window Time 0 = 2 seconds
Pulse Counter 0 = 1 pulse
Blind Time 2 seconds
Threshold = 128
I played around with the threshold a little, but didn't get a very good sense of the tradeoff of sensitivity vs false alarms (working in a relatively small room). The 128 seems to work, but wondering if there are better settings.
@BearWithBeard
Wow. Thanks. So many times, I have wanted a function like this, but I did not know it existed. I'm going to have to go back to the documentation and see what other good tricks I have missed.
@Yveaux
Another experiment, using 2mm machined pins and sockets. Since the RFM69HCW and the RFM95's share the same pinout, I could switch radios easily for testing.
Thanks @tekka
This is awesome and came along at the perfect time. I have 4 networks because of experimenting over the years and have been meaning to clean up the rats-nest of wires that is my current set of serial gateways. Enter Multi-Transport.
I made a gateway with NRF24 and RFM95 (915Mhz) running off an STM32F411 black pill. Worked right off the bat.
Now I just need to duplicate for RFM69 and RFM95(433Mhz).
I am testing a node with a DigiPyro, PYD 1598 motion detector. It is advertised to be low power and runs from 1.8 to 3.6 volts, so should run well with a coin cell. They have to be programmed with several options and I have not found a lot of documentation. I went with what seemed like the most sensitive choices and it seems to work so far. More research needed . ...
https://www.excelitas.com/product/pyd-1588-pyd-1598-low-power-digipyros
I bought a couple of these from DigiKey for around $4 each. Now they are more than $12 each and there is no stock. So, these may not be as good a choice as they seemed at first. We'll see . ...
@NeverDie
It isn't very scientific, but I think the range is roughly equivalent to a BT832. I can reach my gateway from everywhere in my house except the far corner of the basement, same as the BT. That corner is behind a chimney an lots of plumbing -- RFM69 territory. Maybe the BT832F would work there. Haven't tried those.
After fixing a missing trace on my dev board (my fault, not Oshpark's), and updating my J-link and bmp software. I am able to program these.
I popped the shield off of one just to confirm I ordered the right version. The part numbering vs processor is not very clear on Aliexpress. No surprises there.
I received a few of the Minew MS50SFB modules. They appear to need unlocking similar to the E73 modules. I have tried using instructions as for E73, but no luck so far with either
gdb
https://forum.mysensors.org/topic/9266/guide-nrf5-nrf51-nrf52-for-beginners/54?_=1598203470928
acts like it is working, but doesn't really unlock the module.
or J-link
https://forum.mysensors.org/topic/9266/guide-nrf5-nrf51-nrf52-for-beginners/33?_=1598203470928
returns error from nrfjprob. In J-Link application can not connect
Yes it is possible, using the SWDIO and SWDCLK pads.
I programmed one to operate with MySensors using a black magic probe, but the J-Link also supports SWD programming.
The tricky part is connecting to the pads. I just soldered on some wires -- not a very elegant solution, but it worked.
You can get a reasonably priced J-Link EDU from Adafruit:
https://www.adafruit.com/product/3571
Hi @David-Marlinge
I have struggled with these meters in Domoticz also. I am using an S_Power meter for an energy monitor which looks like what you are using. This is my understanding:
The value on the top of the bar is the power you have most recently sent (in Watts).
Domoticz calculates kWh from the watts and the time it was sent.
kWh used today is shown on the Utility screen (your 2036.992).
Overall kWh is what is shown on the device tab (your 2311414.016).
I present an S_POWER device, then measure the current and multiply by the voltage to get the power in watts. Then I send that with a V_WATT message. I don't calculate the kWh. Domoticz calculates kWh from the Watts I send and time I send it.
For example:
present(CHILD_ID_PWR, S_POWER, "Emon 38/26H");
. . . . . . . .
MyMessage Msg_Pwr(CHILD_ID_POWER, V_WATT);
. . . . . .
send(Msg_Pwr.set(Pwr, 1));
Then the Pwr value should show up in that top bar. Domoticz will calculate the kWh used based on the time of the power updates.
I have not really used the V_KWH variable, so I'm not sure how that fits in with this one.
Cool!
I have some E78's laying around because they seemed like a nice processor/radio package. But that looked like too big a project for my skills.
I'm going to have to dig them out now that there might be a path to get them to work with MySensors.
@TRS-80 I have similar thoughts for a controller for my heater (hot water radiators with an oil boiler and 4 zones).
For 1 and 2, I realized I could wire my node into the zone controller. It has a common, so I can derive the node power from the controller. Since it works over radio, it doesn't have to be where the old thermostat was. I have temperature sensors in all the rooms.
The node controls 4 solid state relays that are wired in parallel with the existing zone thermostats. That helps with 5. The idea was to set the conventional thermostats at a low value. Then if my node failed, at least the old thermostats would kick the heater on before the pipes started to freeze. Also as a fail safe, if the node has the heat on and doesn't hear from the controller periodically, it will shut off. Still working on that part.
As for controlling it, there is a domoticz plug in here: https://www.domoticz.com/wiki/Plugins/Smart_Virtual_Thermostat.html
It only works for heat, but the underlying code is pretty straight forward, and it lets you average sensors. There might be something there you can adopt. I ran it with a MySensors modified space heater all last winter and it worked well.
Unfortunately, something kept killing the radio on my node, maybe a spike from zone controller relays. I haven't sorted it out yet, so the heater thermostat remains a work in progress.
I had a similar problem with weather sensors, but it was a while ago and Domoticz has been updated since then.
I was presenting temp, hum, baro. Domoticz always assumed it was a weather sensor if I presented the baro -- and the humidity wouldn't update. It didn't matter if I used separate child IDs or the same one.
I really only wanted temperature and humidity, so I quit presenting the baro and the Domoticz temp/hum has always worked well.
I just assumed I was doing something wrong, but your problem sounds similar. Maybe it's a Domoticz bug.
Does anyone have any experience with the minew modules?
I've been using the Fanstel BT832 series with success, but I have been looking at this one to get a few more hand-solderable GPIOs.
If you haven't done so, copy the MyBoardNRF5.h and .cpp files to the same directory as your sketch.
Also, your configuration shows S132 (SoftDevice). Soft Device is not supported for MySensors, so pick None.
@BearWithBeard said in GUIDE - NRF5 / NRF51 / NRF52 for beginners:
From the two ports the BMP provides, you want to use the GDB Server. If Windows only provides generic names for both ("USB Serial Device" or something), the one with the lower number should be the right choice.
Strangely, my BMP uses the higher port number as the GDB server and the lower one as the serial port. I think this is unusual since it is opposite of what most guides say to expect. So, try the higher one if the lower one doesn't work.
I haven't used these yet, but it looks like @NeverDie has a project using the amplifiers here:
https://www.openhardware.io/view/491/PA-LNA-nRF52832-ESP-LINK-Shield-for-Wemos-D1-Mini-ESP8266
MySensors is built around nodes that collect data and send it over radio to a gateway connected to the controller.
For your application, it sounds like you would create a node that collects information from your controller. Then you would need to add a MySensors gateway to your Domoticz setup.
I'm not sure what you mean when you say your controller can transmit the information. If your controller and Domoticz are on the same network, you could have your controller send data directly to Domoticz using http. There is info about that in the Domoticz Wiki. Or, if your controller and Domotics are on the same network, you could add a MySensors MQTT gateway to the network and have your controller sent data using MQTT messages.
Take a look at the Getting Started and Build pages on this site and you will get a good idea of how MySensors could fit in.
@NeverDie Of course the oven is the way it is meant to be done.
I have the oven waiting to convert, but that's still ahead on my project list : )
I would also be interested in hearing tips for this type of soldering (thru-hole to pads)
I tried the thru-hole method with the LGA pads on the back of an BT832. It wasn't very successful, I was only able to get one of the 5 holes in my pattern to connect. These look larger and more widely spaced, so it probably works better.
The NRF51822 uses the same Nordic radio protocol as the NRF24, so you don't have to set up a new gateway. If you build an NRF5 based sensor, it can send signals to your NRF24 gateway.
I have not used the NRF51822, but have used the NRF52832. The sketches worked, although the pinouts are different from the arduino processors, so you may have to tweak those.
If you haven't seen it already, check out these threads:
https://forum.mysensors.org/topic/9266/guide-nrf5-nrf51-nrf52-for-beginners/11
https://www.openhardware.io/view/376/MySensors-NRF5-Platform
I got tired of twisting DuPont cabels to get from different programmers to different boards.
This is an adapter that lets me connect the programmers I commonly use (Jlink-mini, BMP, STLink clone) with the boards I commonly program with straight through wires. I left a couple unpopulated for future in and out.
That is weird. I can't see what is wrong. Especially since it compiled the one in digitalWrite.
I just tried pasting your code into a sketch I was working on and it verified (different board and radio, but it doesn't seem like that should matter).
Using Arduino 1.8.9
I tried this one: https://github.com/replaysMike/Binner
Close to what I want, but I couldn't get the digikey and mouser downloads to work. That would have made it really useful.
Both digikey and mouser have ways to save BOMs, but it is tied to their web site of course.
I have domoticz and on a rpi with 3 serial gateways. It used to destroy SD cards pretty regularly.
I went with this power supply from Adafruit (It is actually 5.25V) and a UPS.
https://www.adafruit.com/product/1994
Also, I use log2ram.
That has finally made my rpi domoticz setup reliable. I have been running about a year without problems. I still back up often. : )
It's s WS2812B LED strip driver using STM32 blue pill and RFM69HCW.
I have made a few revisions previously, but this one fits an off-the-shelf enclosure and uses the pcb and enclosure lid for strain relief on the LED strip connector wires.
I like the concept of using the enclosure slots to hold the pcb. Maybe a slightly smaller enclosure next time.
I tried with MY_DEBUG_VERBOSE_NRF5_ESB, and it woke from sleep. I have it seeping for one minute.
I posted my code to my github in case you want to take a look:
https://github.com/spike314/BT8_SI_Sketch
I have the nrf5 routines and some battery routines in separate files for convenience, but I think we are using the same code otherwise.
I'm stumped so far.
I have a very similar board, bt832 + SI7021, with a very similar sketch, which seems to work OK.
I don't see anything out of place in your sketch.
@NeverDie
There is an article on hackaday about this type of clamp that even has a KiCAD footprint. I bought one of the clips, but haven't tried it out yet.
https://hackaday.io/project/165917-soicbite-programmingdebug-connector-footprint
I also tried this one from Adafruit;
https://www.adafruit.com/product/4048
small, jlink-mini compatible, and polarized.
So far, my preferrred solution is a 6 pin jst-sh connector.
small. 3v3, gnd, swdio, swclk, tx, rx
and polarized.
My old eyes get tired of confirming I have the pins on in the right direction. Polarization is really nice.
I use the RA-01 with MySensors RFM95 drivers. Works just fine.
I have not tried to change the frequency though. I have only used 433Mhz.
Something like this might work if you just want a noise level, but don't actually need a calibrated readout.
@Omemanti Looks really professional. Are these a commercial style of switch? Wonder if I could get something like that in the US.
@mfalkvidd Neat! It's so obvious once you see it. This is something I need. I have a box full of dupont cables, but it always seems I can't find the right length gender combination.
I also have a wide variety of USB cables hanging on hooks. Something like this with wider slots would be a better solution.
Gonna have to get that 3d printer on day.
Just saw this in my Hackaday Feed:
https://hackaday.com/2020/01/08/commercial-circuit-simulator-goes-free/
I'm not sure it fits the "beginner" category, but cost is no longer a barrier to entry.
Does anyone use software to help manage hobbyist projects?
I usually have 3 or 4 future projects in early stages, a couple that I am building and programming, and one or two old ones that need a refresh. These are simple things like MySensors nodes.
Between arduino sketches, Domoticz scripts, KiCAD files, BOMs, data sheets, and notes, I end up with a lot of files connected to each project. I just use spreadsheets, Git, and file folders to keep track, but whatever system I come up with devolves into a chaos of files and folders after a while.
At work we use a derivative of PTC Windchill, which would be crazy for home use. Seems like there should be something similar, but simple for hobbyist projects.
Is anyone using a lightweight program to track inventory, BOMs, and organize small projects better. I didn't really find anything on Google
@halo6 I use Domoticz instead of Vera, but the general idea should work.
Add another child sensor to your parking sensor that is a binary switch. Maybe S_DOOR, V_TRIPPED or S_BINARY, V_STATUS. That switch gets presented to your controller. Then have the parking sensor listen for a message to that child ID and work normally if on or do nothing (but listen for messages) when off.
In Vera, write a small script that turns on the new parking sensor switch when the garage door is open, and turns it back off again when the garage door is closed.
I've had surprisingly good luck buying cheap parts from Ali-express, but not this time. I bought an NRF52832 iBeacon that supposedly had an SHT30 temperature sensor and KX022 accelerometer. When the parts arrived, neither of those parts were populated. All the beacon has is a push button.
I was able to program it to work with MySensors, however. With only SWIO and SWCLK (no txt out), I took @scalz advice (in another topic) and used a J-Link EDU Mini so I could use the RTT app to get printf style debugging. That worked nicely and I learned a new tool.
Perhaps I can use the iBeacon button for a remote.
@idanronen said in Wireless remote door lock - HW choices:
Hacking - Like i said, it will be operated from home assistant, and I'm not worried about that being hacked. The device can be hacked directly by someone sending random messages with a compatible NRF24 or other device somewhere nearby. I'm not really sure how to handle that one, as this sort of communication is broadcast and a verified message would have to change content every time to be secure, sort of like a rolling code.
So . .. . above, I said that ProMini with batteries was the simplest, but you may want to move to a 32 bit controller for this one.
MySensors provides a security framework to address the hacking aspect above. Using signing on a complicated node, I started running out of memory on the ProMini. I have moved to the NRF5 series, mostly to get more memory. There is a lot of additional features and power also, but it is a harder learning curve to get the tool chain working.