|
Post by papa on Jun 13, 2018 14:37:48 GMT
Moderator Notes:
The one rule in My.rules aims to combine heat AND humidity data so it can display together in one slot on the sitemap. If you are NOT using humidity, just delete My.rules. For the same reason, delete this from My.sitemap: Text item=Node##_Data (## is the ID number of your node)
==================================================
In the User Interface sitemap, "Node Health" is supposed to be a clickable link taking you to a page reporting RSSI & node voltage.
|
|
|
Post by papa on Jun 7, 2018 21:38:39 GMT
Testing the RFM69 Radios
Update, August 21, 2022: Power the node with "Receive" programming (via computer USB port or wall power)
Connect the node with "Send" programming to the Arduino IDE computer & open the serial monitor (SM) & make sure (lower right) it's set to 115200 baud. In the SM's top box you may enter 1, but the point of that is you won't know if the message got through. More importantly, in the SM's top box, enter 2. Sometimes SM will tell us the send was not acknowledged. Other times it should be acknowledged & tell us the Radio Signal Strength (RSSI) in dB. RSSI will be in negative numbers. You might get RSSI of -48, very good. Or the RSSI might be -74 or -94. The closer the RSSI is to zero, the stronger the signal is. Our forum sketches use radio send with retry so communication has some redundancy to help succeed. Strong signal is nice, but the main thing is having strong enough signal for communication to succeed much of the time.
As with WiFi routers, placement can makes a difference on communication success. I get best results by placing my RFM69 Gateway as high & as central as possible.
You can use these sketches to test two RFM radios at a time. One of the test devices is a Bare Bones node that you can further build into a DHT End Node. The other test device has two of the parts you need for an RFM69 Gateway."
While you have the test devices programmed, I recommend that you wire & test at least three or four RFM69 radios.
|
|
|
Post by papa on Jun 7, 2018 21:32:42 GMT
Program the TWO RFM69 Radio Test DevicesEach of the TWO Buono Unos will be programmed with its own sketch that I adapted from Andy Sigler's repository. EZ_Receive.ino (2.01 KB) << With this sketch, (using Arduino IDE) program one of the nodes so it can receive an RFM69 radio message & send an ACK, an acknowledgement reply. Power this node with an AC outlet. EZ_Send.ino (2.51 KB) << With this sketch, program the OTHER node so it can send an RFM69 radio message seeking an ACK OR NOT. (<< updated August 21, 2022)
Next, Testing the RFM69 Radios, Version 1
|
|
|
Post by papa on Jun 7, 2018 21:26:52 GMT
Build TWO RFM69 Radio Test Devices
<< click on pic for larger view
Use this schematic to wire the RFM69s to Arduino compatibles that send only 3.3 volts through their data pins, like D10-D13. Following instructions above, you should have soldered short (color-coded?) wires to the RFM69 holes. On the other end of each wire (except the antenna), you bare a short portion to insert into the proper socket of the Arduino compatible.
Next, Program the TWO RFM69 Radio Test Devices
|
|
|
Post by papa on Jun 7, 2018 21:18:14 GMT
Another Way to Test RFM69 Radios, PreparationTo test that RFM69 radios are sending & receiving, we can use two radios, each installed on an Arduino compatible that sends only 3.3 volts through its data pins (like D10-D13) because more than 3.3 volts will damage the radio. You build two physical devices like my Bare Bones End Node, but both these devices will have different programming. If you are making this forum's RFM69 Gateway & nodes, you may already have the parts needed. Just in case, here's a repeat of that information: A Buono Uno (which switches to 3.3 volt mode) works well for this testing. Have at least TWO Buono Unos. This eBay link shows you some examples. When you get the Buono Unos switch them to 3.3 volt mode. You may need to fiddle with the mode switch to get the Buono's power LED to light. See this post about purchasing RFM69 radios, selecting your frequency, & the length for the antenna. You need at least two RFM69 radios, & I recommend you get three or four so you have a spare.
Next, Build TWO RFM69 Radio Test Devices
|
|
|
Post by papa on Jun 7, 2018 21:16:55 GMT
Are My RFM69 Radios Working? You might wonder. When using a RFM69 Gateway & RFM69 nodes with OpenHAB, a big concern is whether our RFM69 radios are communicating, especially when we are beginners. Using an inexpensive dongle, an RTL SDR (Software Defined Radio) & open source SDR Sharp software, we can detect if an RFM69 radio is transmitting at its defined frequency. See this Lady Ada video around 28 minutes in. You can internet search for SDR and SDR Sharp if you want to pursue this. While interesting (after working out how to use the device & software), I'm not sure that is necessary. Next, Another Way to Test RFM69 Radios
|
|
|
Post by papa on Jun 6, 2018 22:00:55 GMT
What's Next ... now that you should have OpenHAB 2 & Mosquitto installed & running?
You might now use the OpenHAB dashboards to view your OpenHAB configuration. http://localhost:8080/start/index will show you a list of interfaces that was chosen by the addons.cfg file you downloaded from my github repository. In PaperUI, you can see bindings, etc that other downloaded config files selected for you. To change them, you must edit the addons.cfg file. BasicUI & ClassicUI gives you the interface set up by the downloaded My.sitemap, as it is informed by My.items & My.rules.
As I said in the first post above, OH2 can accomplish some things without setting up additional devices. This post tells how to display Date & Time on your OpenHAB User Interface.
|
|
|
Post by papa on Jun 6, 2018 20:46:13 GMT
A Script to Test How Well Your Windows OpenHAB / Mosquitto Is Set up for DIY Home Automation
For any point in the OpenHAB installation & configuration steps, I created a script (.bat file) to test how well your OpenHAB / Mosquitto is set up for DIY Home Automation. At any point, I believe it can show you what you might still need to accomplish. If you choose, the script can generate a report file that you could share on this forum to get help. The report file's name is OHreadiness.txt
This script should pose no risks. It makes no changes to your Windows computer, except if OpenHAB service or Mosquitto service are installed, but not running, the script will start them.
CheckOH26.bat (15.31 KB) << Here is the script to test OpenHAB / Mosquitto.
To download & run the .bat script file, I suggest that you use or create the directory C:\~Scripts & download or move the .bat files there. Then go to that C:\~Scripts folder, select the name of the script, & tap [enter]. OR in in the search box of Windows Start Button or Cortana, enter cmd. In the resulting window, enter cd /d C:\~Scripts then & on the next line enter the name of the .bat file.
Update Jan. 22, 2019: This script assumes that in mqtt.cfg, one should use the setting "mosquitto.retain=true" < Disregard that. Either do NOT change that setting or use "mosquitto.retain=false" The true setting seems to create some problems. I'll update the script when I get a chance.
I hope these posts & tools on installing & configuring Windows OpenHAB 2 & Mosquitto message service are helpful. I'd like to hear how they've been used.
|
|
|
Post by papa on Jun 6, 2018 20:07:25 GMT
A Script for Step 3) Install the OpenHAB add-ons AND Configure the OpenHAB items, rules, & sitemap needed for our forum's Home Automation projectAs said in the last post, I also created a Windows script file, Get_OH_starter_Filesxx.bat, to install the above configuration files where OpenHAB 2 needs them. As the script's opening screen warns ...Caution: For good or ill this script overwrites certain existing configuration files (My.items, My.rules, My.sitemap, addons.cfg, mqtt.cfg), but in each case, will get your permission first.So ... the best time to use this script is just after you have first installed OpenHAB (as shown in steps above) OR you want to make a fresh start on your configuring OpenHAB.
To download & run the .bat script file, I suggest that you use or create the directory C:\~Scripts & download or move the .bat files there. Then go to that C:\~Scripts folder, select the name of the script, & tap [enter]. OR in in the search box of Windows Start Button or Cortana, enter cmd. In the resulting window, enter cd /d C:\~Scripts then & on the next line enter the name of the .bat file.
Next A Script to Test How Well Your Windows OpenHAB / Mosquitto Is Set up for DIY Home Automation
|
|
|
Post by papa on Jun 6, 2018 19:28:38 GMT
Step 3) Install the OpenHAB add-ons AND Configure the OpenHAB items, rules, & sitemap needed for our forum's Home Automation project This step to configure OpenHAB2 is where I disagree with what the official docs seem to prefer, namely starting configuration via graphic dashboards. I appreciate developers' trying to make it easier, but I'm convinced for now that configuration text files work better. In another thread, at this post, I made my case for this. For one thing, in this comparison chart of what each configuration method can do, text files accomplish the most. Configuring items is on the PaperUI list, but as far as I see, some parts of our forum's item configurations get ignored in Paper UI.
If you know what you are doing, you could download & install these files on your own. If you view or edit them, I recommend you avoid using a typical Windows text editor. Instead use Notepad++ a text editor friendly to all computer platforms. See more at this post.
To make things even easier, I also created a Windows script file, Get_OH_starter_Filesxx.bat, to install the above configuration files where OpenHAB 2 needs them. This will be offered in the next post.
Next, A Script for Step 3)
Install the OpenHAB add-ons AND Configure the OpenHAB items, rules, & sitemap needed for our forum's Home Automation project
|
|
|
Post by papa on Jun 6, 2018 18:44:29 GMT
Step 2) Install the OpenHAB platform on a Windows ComputerAgain, items 1a), 1b), & 2) in the OpenHAB 2 (OH2) installation process steps could be done in any order, but if not accomplished, could interfere with results from steps 3a) & 3b).
Update, Jan. 22, 2019: See this post below where I address another OpenHAB2 installation option in the official documentation. As the official documentation suggests, I recommend you install OpenHAB2 in the folder C:\openHAB2\ which you will create unless you installed it before. Using that folder will make it easier to follow the official docs & to use some things that I offer.
Update, Jan. 22, 2019: I encourage you to make copies of the so far two original, unedited files in the C:\OpenHAB2\conf\services folder. Then you will have the original settings to compare to any changes & perhaps revert to. As you progress in configuring OpenHAB2, other files will add in the C:\OpenHAB2\conf\ folders. I encourage you to make copies of them before I have you copy in edited versions.
As the official docs instruct, run the script C:\openHAB2\start.bat & launch OpenHAB2. You should see the Karaf console. At its top, you may see some error messages, but I don't believe that's a concern if Karaf starts after the error messages. Congrats, OpenHAB 2 is running, but unless you set up OpenHAB to run as a service, when the computer reboots, start.bat must be run again.
Next, Step 3) Install the OpenHAB add-ons
AND Configure the OpenHAB items, rules, & sitemap needed for our forum's Home Automation project
|
|
|
Post by papa on Jun 5, 2018 19:25:33 GMT
Some Comments on the Batch Files in the Last Post
I saw a need (making the Windows Mosquitto installation more reliable) & I believe I found ways to address it. The Windows Mosquitto installation program are provided separately from some extra .dll files that Windows Mosquitto needs. For the most part, the extra files are part of the OpenSSL project. OpenSSL is continuously updated to address security problems & older versions are no longer available. That means the .dll files needed by older versions of Windows Mosquitto are no longer available.
So in my github repository, I provide what is currently the latest Windows Mosquitto installation program AND the most recent OpenSSL .dll files that version of Windows Mosquitto needs. I provide ONLY the OpenSSL .dll files that Windows Mosquitto needs so one need not download & do two larger OpenSSL installations. The .dll files are place directly in the Mosquitto program folder so I don't believe they will interfere with other versions that might get placed in the Windows system folders.
By working out the above for the latest versions of Windows Mosquitto & OpenSSL & providing the files on my github, I hope this solution will last a while. I also did the scripts to take care of putting those now current files in place & making sure Windows Mosquitto works.
The script files (.bat) in the last post are among my very first. I'm sure the scripts could have been done differently, even better. Their user interface is primitive, but I've tried to be careful how I present instructions & provide for how users proceed through the process. I also tried to comment what I was doing throughout the .bat. I believe these batch files will work on a variety of Windows computers. Why did I use .bat batch files? Because they are more like previous programming I've done. Why did I include some Powershell programming? Because (with my son's help) that allowed me to accomplish some things (like downloading & copying files into a C:\Programs (x86)\ folder) that .bat files cannot natively do & yet not require the install of other tools. Maybe down the road, I'll move toward more Powershell programming.
I'll be interested to hear if these scripts are helpful.
Next, Step 2) Install the OpenHAB platform on a Windows Computer
|
|
|
Post by papa on Jun 5, 2018 19:04:28 GMT
1b) Install, Start, & Test Windows Mosquitto Message ServiceMosquitto MQTT Message Service is often needed for Home Automation projects (including our forum's). It handles messaging between devices and OpenHAB. My first install of Windows Mosquitto 3 years ago was a nightmare. Installing Mosquitto on Windows can be challenging, matching a good install .exe with the right versions of dependent .dll files where needed. I'm sharing what I tracked down to work for me and might help you succeed ... From my github repository, you can download an installation .exe & extra needed .dll files AND follow the explanation & directions in the README.md file. OR to make it easier ... InstallMosquittoB.bat (12.64 KB) << Download & run this batch file which may do everything for you: download a Mosquitto .exe & extra needed .dll files, run the installer .exe, copy the extra .dll files into the Mosquitto program folder, start the Mosquitto service, & test that Mosquitto is working & ready to be used with OpenHAB. MosquittoTest5.bat (2.38 KB) << You can also download & run this batch file to only test if your Mosquitto is working.To download & run the batches, I suggest that you create a new directory C:\~Scripts & download or move the .bat files there. Then go to that C:\~Scripts folder, select the name of the script, & tap [enter]. OR in in the search box of Windows Start Button or Cortana, enter cmd. In the resulting window, enter cd /d C:\~Scripts & then on the next line enter the name of the .bat file.
Update, Jan. 21, 2019: If the above Mosquitto install does not work, you may not have the Microsoft-Visual-C-Redistributables that you need. In my Microsoft-Visual-C-Redistributables repository, I offered 3 install files that work for me. Download & run the files starting with the 2010 file. If your Windows computer says it already has a Microsoft-Visual-C-Redistributables install, cancel the install & go on to another install file. After you install the missing Microsoft-Visual-C-Redistributables, try the above Windows Mosquitto install again.
PS As of Jan. 21, 2019, I am running Windows 10 Home, Version 10.0.17763 Build 17763.
Next, Some Comments on the Batch Files in the Last Post Then, Step 2) Install the OpenHAB platform on the computer
|
|
|
Post by papa on Jun 4, 2018 15:56:32 GMT
Step 1a) Satisfy the Windows OpenHAB's Java Prerequisite, continuedAfter previously using another Java source, I agree with the official docs recommendation of installing the Zulu Java Platform. Go to this site. Scroll down until you start seeing 8 along the left margin. Look for your 64 bit or 32 bit version with the highest build number in the label 8u[build].
Update, Jan. 22, 2019: See this post below where I address another Java installation option via the official documentation. Within most Zulu 8u[build] possibilities is a .zip file for server & a .msi file for client. This site says "The client system is optimal for applications which need fast startup times or small footprints, the server system is optimal for applications where the overall performance is most important. In general the client system is better suited for interactive applications such as GUIs." I chose client .msi which I believe is fine for our DIY Home Automation purposes. Does anyone have better insight?In the search box of Windows Start Button or Cortana, type environment. Near the top choose, edit the system environment variables. At the bottom of the resulting window, choose [Environment Variables ...]. In the lower part of the resulting window, select an existing JAVA_HOME & [edit] or choose [new]. Setting the JAVA_HOME environmental variable ... Some Java chatter I saw said that maybe this is not necessary, but why take chances.
My JAVA_HOME is C:\Program Files\Zulu\zulu-8 Yours might start C:\Program Files\java\
JAVA_HOME needs to be the Java installation folder, just above the \bin folder that holds java.exe
Apparently, a computer reboot is needed for JAVA_HOME to register in the system.
Next, 1b) Install, Start, & Test Windows Mosquitto Message Service
|
|
|
Post by papa on Jun 4, 2018 15:46:50 GMT
Step 1a) Windows OH2, Satisfy the OpenHAB Prerequisite (Java version 8) Updated, Jan. 20, 2019
See what version of Java (if any) you have on your Windows computer: In the search box of Windows Start Button or Cortana, enter cmd. In the resulting window, enter: java -version. On one windows computer, my current results are "openjdk version 1.8.0_163" ... Zulu" ... Ignore the "1." "8" means Java 8. 163 is the "build." For now, we need a build higher than 161. If your Java is less than Java 8, build 161 ... I recommend you replace it & any other Javas you might have: In the search box of Windows Start Button or Cortana, type programs & at the top select Programs and Features. In the resulting window, scroll to your Java install(s). Right mouse click on each & choose uninstall. After all Javas are uninstalled, reboot your computer. To prepare to install a new Java 8 ... In the search box of Windows Start Button or Cortana, type System & at the top select System Information. In the resulting window, look for x64, meaning you have 64 bit Windows or x86 meaning you have 32 bit Windows. You will choose a Java 8 install based on that. OpenHAB official docs warn NOT to use Java 9 or 10.
Next, Satisfy the Windows OpenHAB's Java Prerequisite, continued
|
|
|
Post by papa on Jun 2, 2018 18:29:04 GMT
Overview of OpenHAB2 / Mosquitto Install on Windows OR Linux I divide the OpenHAB 2 (OH2) installation process steps into
1a) Satisfy the OpenHAB prerequisite (Java version 8)
1b) Install the Mosquitto MQTT message service on the chosen compatible computer
2) Install the OpenHAB platform on the computer
3a) Install the OpenHAB add-ons needed for our forum's Home Automation projects (actions, bindings, persistence methods, transformation, User Interfaces, Misc, Voice) These add to OpenHAB's abilities. 3b) Configure the OpenHAB items, rules, & sitemap needed for our forum's approach to Home Automation.
For after all the above & or at any point, I have a script (.bat file) to test how well your OpenHAB / Mosquitto is set up for DIY Home Automation. At any point, I believe it can show you what you might still need to accomplish. It can generate a report file that you could share on this forum to get help. This post below has that script. Note: Items 1a), 1b), & 2) could be done in any order, but if not accomplished could interfere with results from 3a) & 3b). (Later pieces often depend on actions in earlier steps. Often before a 3b configuration can happen, something else must be done in a 3a install / configuration.) Concerning the above steps, the following posts provide more help for some installation steps than others. I find this official OH2 documentation helpful for me & for this forum's DIY Home Automation project. Again, my main disagreement applies to steps 3a & 3b. I also believe official docs could provide tools to help set up & troubleshoot OH2 & I will offer some for Windows in this thread & I hope for Linux in a later thread. Next, Step 1a) Windows OH2, Satisfy the OpenHAB Prerequisite (Java version 8)
|
|
|
Post by papa on Jun 2, 2018 18:27:14 GMT
IntroductionAnother thread gives my comparison between installing on Windows & Linux & my case for configuring OpenHAB 2 (OH2) with text files instead of PaperUI. For me, Windows & Linux installs each have advantages & kinks. For me, a Windows computer is a decent platform for OH2/Mosquitto & the Arduino IDE. A Windows or Linux laptop's additional advantage is built-in battery backup. OH2 can accomplish some things without setting up additional devices. To take best advantage, one needs to buy or build devices and configure them. Other forum threads give examples. My thread, Building an RFM69 Home Automation Network (Beginners ??), leads you through building a Gateway & Node that use RFM69 radios to communicate with OpenHAB.
While one waits for devices & parts to arrive, one might install OH2/Mosquitto. This thread on a Windows install continues my attempts to help others get started with this DIY Home Automation project by lowering "speed bumps." It's based on a Windows 7 install of OH2 a few months ago & a very recent Windows 10 install of Mosquitto MQTT message service. PS I picked Windows because I'm more confident with it & maybe there are less docs for Windows installs of OH2. In the future, I plan a Linux version of this thread.
Next, Overview of OpenHAB2 / Mosquitto Install on Windows OR Linux
|
|
|
Post by papa on Jun 1, 2018 15:23:02 GMT
flyyboyy, good to hear that you are making progress. flyboyy: "On to adding sensors to the node. Think I'm gonna start with DHT (I have 22s, not 11s), but haven't looked if defines need to be changed, or any other code" papa: When looking for information, I encourage you to use the search box near the upper right (above "Last Post") when you are in a board. This search gave several possibilities including these two threads with DHT22 in their name & conversation about using them: homeautomation.proboards.com/thread/8/dht-sensors-various-mhz-speeds
Near the search box, you can click on the magnifying glass icon to refine your search.
|
|
|
Post by papa on May 31, 2018 13:00:54 GMT
flyyboyy: "Set debug for radio but see nothing on the terminal. Looking at the code, I assume I wont until I have a node sending it stuff (?)" papa: That is correct. ============================= Getting the first reliable communication among mosquitto service, gateway, & node is often maddening & as you say, "hair-pulling," but rewarding when it works.
flyyboyy, you said, you "added the cli() and sei() snippets in the W5100.h library." In this post, did you see this other change to make in the Arduino library files:
"Added 1/1/2017: From what I see, for w5100.h changes to be used, also edit Ethernet.h, at your Windows (or comparable Linux) path of "C:\Program Files (x86)\Arduino\libraries\Ethernet\src
Line 5 of Ethernet.h is //#include "w5100.h" which means do NOT include w5100.h. So delete "//" at the start of line 5 to activate the include. Save the changed Ethernet.h file. P.S. pato found that for some IDE versions, to avoid an error, we may need to edit the Ethernet.h line to this: #include "utility\w5100.h" Changes to the TWO libraries are important to reliable communication between gateway & node. =============================================== Please post here the IP address of the Pi that is running the mosquitto message service. Also post the customization changes you made in the gateway & node sketches. Maybe those will give some clues.
|
|
|
Post by papa on May 31, 2018 2:58:54 GMT
flyyboyy, I'm glad you are keeping a sense of humor about this & that you are making some progress.
flyyboyy: "are mqtt login credentials required from the GW?"
papa: no
|
|
|
Post by papa on May 30, 2018 19:43:19 GMT
Welcome, flyyboyy, to the joys & usual startup frustrations of DIY Home Automation. Using RFM69 radios enables a lot, but getting it going can be a challenge. You did a good description of what you have tried. Let's see where we can go from there. flyyboyy: "I have RPi3B running openHABian 2, with MQTT installed and working."
papa: Sounds like you have the MQTT binding installed in OpenHAB. BUT on the openahabian Pi, did you do the optional setup of Mosquitto, the MQTT broker service? Without Mosquitto service running on the Pi, the Gateway cannot link to the Pi nor to openhab. Question: What 3.3 volt Uno clone did you try? Some have USB chip sets that are challenging to work with. The Buono Uno I recommend (for which I get no compensation) does well with connecting to Windows USB & provides decent power for the current-hungry RFM69HW. Speaking of current-hungry RFM69HW, I don't believe the ProMini necessarily supplies enough 3.3 volt current to keep the RFM69 radio stable. Again I use a Buono Uno switched to 3.3 volts & that's how I adapted the Gateway schematic I posted. Member computourist developed the basic schematic & coding for the Gateway & node. Computourist used the pro Mini, but added a power supply for the RFM69 radio. If you don't have that, the pro mini may be rebooting & preventing the linking. See his schematic of a pro mini gateway with the power supply in the upper left corner. flyyboyy: "Other than having the RFM disconnected (should not need it at this point, right?)" papa: I need to check the Gateway code about that.
|
|
|
Post by papa on May 24, 2018 17:11:09 GMT
As I often say, this project is very challenging, especially at the beginning & especially with the RFM69 radios. So hair pulling is normal. When you talk about #define RFM_SS 8, you must be working with the RFM69 Gateway. If the RFM69 radio used the Arduino pin D10, that would interfere with the Ethernet Shield. I don't understand a lot about using the RFM69 radio, mostly that the way we program & wire the radio for gateway & nodes works for us. Here's a couple of references about chip select or slave select: here & here (especially the data section) My understanding is that the CS/NSS pin is set high to enable communication between the Arduino & the RFM69 radio. When you say "network connection only works with #define RFM_SS 8, but as I mentioned, pin 8 is just permanently pulled high," I believe that is how it is supposed to work.
On the Serial Monitor, a Gateway alone will only show that it connects with Ethernet & MQTT (Mosquitto). To show more (data), it must be communicating with a working node.
PS I assume when you build the Gateway, you follow directions carefully to protect the RFM69 radio from too high voltage (5 volts): that is, you used an Arduino compatible that puts 3.3 volts through its digital pins (like a Buono Uno) AND you disabled the VCC pin in the Arduino's ICSP cluster. Without such protection, the radio can get damaged & become unreliable. Can someone else with better electronics understanding comment on how the CS/NSS connection is supposed to work?
|
|
|
Post by papa on May 24, 2018 15:18:42 GMT
Moderator's Notes:
I originally called this a "Freezer Node." However, with one or both types of temp sensors, it could be used in other locations. Most of the node could be in a secure, dry location while the waterproof DS18x20 sensor(s) could be in an enclosed or potentially liquid location. I'd love to hear how you use this node.
I have deleted several posts that were below because they are no longer relevant to using at least openHAB 2.5.0.M1, MQTT 2.x Binding, & the Embedded MQTT Broker. The posts above have been updated.
|
|
|
Post by papa on May 20, 2018 2:58:38 GMT
Welcome, Kisa/Markus, to the adventure (& sometimes frustration) of DIY Home Automation via RF radios. I've moved your post here & it would have been OK for you to have started a thread. I'm glad you found the tutorial & the Multi-choice node sketch encouraging.
I'm not totally sure I understand your situation & what you are asking, but it sounds like you want to use a temperature sensing node built around ATtiny84 & RF12 radio that would communicate via a gateway (to OpenHAB??) using an RF12 radio. Speaking of RF12 radio, maybe you've already seen this thread at lowpowerlab.com which is from a number of years back. Or how about this post about RF12 radio communicating with RFM69?
Maybe someone else on the forum has experience with the RF12s, but I have enough to maintain helpfulness with Ethernet, RFM69 radios, & ESP82xx devices. Moreover, from what I saw the ATtiny84's 8K flash memory would be very small to work with.
I try to be open that the RFM69 radio project with Arduino compatible gateway & Arduino compatible node using RFM69 radios is NOT easy, but with patience, attention to detail, & offered help here, it is doable. On this forum, I've tried to describe how to build & program it step by step. I'm working on scripts to check how well OpenHAB / Mosquitto aspects are installed on the host computer.
I've found the Buono Uno Arduino compatible plus a prototyping shield is a good platform for gateway & nodes. If with the ATtiny84 you wanted to make something small, the 3.3 volt Anarduino Miniwireless or lowpowerlab.com's Moteino are small compact Arduino compatibles which can be ordered with an RFM69 radio already installed.
Again I don't claim that it will be easy, but if you try the RFM69 approach that we've used on the forum, you will have ready-made build instructions & coding & OpenHAB communication & our experience.
Let us know if you decide to proceed with the RFM69 approach.
|
|
|
Post by papa on May 17, 2018 17:05:06 GMT
We welcome, slider007, who last joined the forum & became member 700. Welcome to all who have joined in recent months. I hope the forum has been informative & encouraging for you to approach DIY Home Automation.
The forum has been quiet in recent weeks. I've been working on a couple things & hope to post them before long. I also hope others of you will share what you are working on.
|
|
|
Post by papa on May 2, 2018 19:18:19 GMT
Massduino Arduino Compatible, ?? Mixed Results for RFM69 Gateways or Nodes Today, ngy reported: one thing I noticed is that the Massduino does not work well as a gateway, nor as an end node. While the Arduino software uploaded the sketch to the Massduino with no problem, the Massduino programmed for an RFM69 Gateway or node does not perform as expected, so I can NOT recommend it.papa: The RFM69 radio (especially the "H" high power version) needs a lot of current for stable operation. The Massduino may not provide enough current for the RFM69 radio.
For RFM69 Gateway & nodes, I continue to recommend a Buono Uno or these devices that have an installed RFM69 radio of your chosen frequency: Anarduino Miniwireless or lowpowerlab.com Moteino.
Thanks, ngy, for reporting your experience with the Massduino.
Update, June 23, 2021: See below for my success with using a Massduino for a DIY Home Automation node. So far the specifications & my experience indicate my recently purchased Massduino has enough current for the RFM69 radio.
|
|
|
Post by papa on May 2, 2018 19:03:48 GMT
Thank you, ngy, for reporting more on the massduino & your willingness to contribute to the forum. I'll add your massduino report to the part's sources thread.
|
|
|
Post by papa on May 2, 2018 13:56:01 GMT
ngy was having problems getting his first RFM69 Gateway, Node, & OpenHAB working together. we had a good analysis of symptoms: "Gateway & node are talking. Gateway is connected to local network & MQTT. Still node data was not getting through the gateway to the OpenHAB User Interface or logs, but the cause did not seem to generate a log error." ngy found the problem or at least a solution. Searching online showed having MQTT Action installed with the MQTT binding has issues: github.com/openhab/openhab1-addons/issues/5038 (by Richard Koshak, a very knowledgeable user) ngy reflashed openhabian, and only installed the MQTT binding, and voila! everything worked like a charm. Lessons learned ??: 1) I remember similar things about the voice command feature interfering with other features. Sometimes in excitement over a new project or in frustration trying to get things to work, we try too much. It's probably best to get the minimum aspects working & then add other things. 2) ngy reflashed openhabian, started a new OpenHAB install, but NOW he was using all his gained experience about correct installation. Perhaps he cleaned out other problems introduced when he was trying everything. Again, it may be best to go back to minimums & gradually add more & watch how well the additions work before moving on to more additions.
|
|
|
Post by papa on May 2, 2018 13:28:41 GMT
ngy: I couldn't uninstall MQTT actions in the PaperUI.
papa: From my experience, if we install a binding etc. via text files (like addons.cfg in the case of bindings), we can see them listed as installed in PaperUI, but we cannot uninstall them in PaperUI. I believe that if we install something in BOTH PaperUI & a text file that the text file entry takes precedent.
ngy: I reflashed openhabian, and only installed the MQTT binding, and voila! everything works like a charm.
papa: I'm thrilled that we got your beginning project working. I recommend that you save an image of this & future working openhabians so if you must reflash this install you need not start from scratch.
ngy: Thanks papa for all your help
papa: You are welcome. I hope you remember how it feels to struggle, but also have someone working with you to make progress. From that I hope you continue to participate here. When you see other beginners struggle on this forum & you have an idea to help, please participate. When you discover a hint that helped you, please share it here. When you find forum info that is incorrect, please help us correct it. When you add new feature or improvement to our DIY Home Automation project, please share it here.
I also hope you watch for when I post my script to check key areas of readiness for our DIY Home Automation project. Please try the script, report your results, & give feedback.
|
|
|
Post by papa on May 2, 2018 13:12:21 GMT
Good research & troubleshooting, ngy. Your experience could be very instructive to all of us:
1) This DIY Home Automation project (especially using RFM69 radios that require a Gateway besides nodes) is doable, BUT has several challenging aspects, especially for beginners.
2) Again working together, we had a good analysis of symptoms: "Gateway & node are talking. Gateway is connected to local network & MQTT. Still node data is not getting through the gateway to the OpenHAB User Interface or logs, but the cause does not seem to generate a log error."
ngy: "Searching online showed having MQTT Action installed with the MQTT binding has issues" Yes, as I raise above, I remember similar things about the voice command feature. Sometimes in excitement over a new project or in frustration trying to get things to work, we try too much. It's probably best to get the minimum aspects working & then add other things gradually & test before moving on.
Perhaps when we see such symptoms again, we can suspect interference between OH features (bindings, etc) & then we try reducing such features to the minimum needed.
3) When you reflashed openhabian & started a new OpenHAB install, you were using all your gained experience about correct installation. Perhaps you cleaned out other problems introduced when you were trying everything. Again, it may be best to go back to minimums & gradually add more & watch how well the additions work before moving on to more additions.
Perhaps when we see such symptoms again, we might save dated copies of our configurations, then try a new openhab install with minimum features & gradually add & test other configurations we desire.
|
|