Irrigation Controller (up to 16 valves with Shift Registers)
-
I just made the change and tested it. That was definitely the problem. Works perfect now.
Not sure who can change the example code, but all that needs to be added is this:
// //Update valve data when first powered on for (byte i = 1; i <= NUMBER_OF_VALVES; i++) { lcd.clear(); goGetValveTimes(); } lcd.clear(); //Add this line inSetup = false;
-
@dbemowsk
You beat me too it. I added the same line in same location and it works perfect. Every so often I see the raindrop icon to show that it is pulling data to update the valve times.
-
So it is definitely a confirmed bug. I ended up finding some old sample code from when I started this last year and this bit of code was actually in the setup method and not in goGetValveTimes:
lcd.print(F(" Updating ")); lcd.setCursor(0, 1); lcd.print(F(" Valve Data: ")); lcd.print(valveIndex);
So some time in the past year the sample code had been changed.
-
good to see you found it. I haven't looked at the code for two years, and mine is still working. (@petewill 's demo worked well too). there must have been some change that managed its way into the source
maybe look on GitHub and do a pull request if you the problem is there...
-
Hi I just order all the parts that was listed. Do I need to read the 230 post or it's ok just watched the video.
-
@tombstone You shouldn't need to read all the posts. Maybe just search the thread if you run into any snags. What kind of setup are you dropping this into? Do you currently have valves installed? Does your setup have a master valve or pump relay? Is it a standard 24V AC system?
-
Ok I read it all. Just want to start with the basic then change to pH reader soil reader water reader rain detector.
-
It's really hard to work out what's good post over bad post. Lol
-
Its my 1st project and I have learnt alot but have got myself a snag and I am getting this....
Arduino: 1.8.3 (Windows 10), Board: "Arduino Pro or Pro Mini, ATmega328 (5V, 16 MHz)"
C:\Users\HTPC\Documents\Arduino\Irrigation_Controller_1\Irrigation_Controller_1..ino:82:21: fatal error: TimeLib.h: No such file or directory
#include <TimeLib.h>
^
compilation terminated.
exit status 1
Error compiling for board Arduino Pro or Pro Mini.
-
go to library manager and install Time library
-
This post is deleted!
-
This post is deleted!
-
This post is deleted!
-
This post is deleted!
-
ok I almost there but my pro mini has just Analog 1 to 3. I say I have to change the coda were abouts...
I also have not setup up my Vera Controller as I see you have to pay...Is there another one that is eazy as I have try some but can not get it to work. eg HomeGenie is download and on my pc but don't think its not to good. don't know how to find my pro mini. happy to chagaen to someing eazer to get me started thanks guys....
-
Domoticz LOOKS GOOD
BUT new to all this
-
If you are looking for Software, try openhab.
You need to buy Vera, but the software is free.
-
@Black-Cat thanks
-
ok so when adding to Domoticz..
I go to hardware...
I name is..... test...
then choose.. MySensors Gateway with LAN interface....
Data Timeout: .... Disabled.....
Remote Address.... (I have tryed)....IP Address, Subnet Mask, Default Gateway, Primary DNS, Secondary DNS.
(i try everythinbg I can think of and still not work)
Port: ... 5003
My pro min has the red light on and blink blue occassionally.what I get from the Domoticz log is
2017-07-30 18:00:00.627 Error: MySensors: Can not connect to: 61.9.211.33:5003 2017-07-30 18:00:00.627 TCP: Connection problem (Unable to connect to specified IP/Port) 2017-07-30 18:00:00.627 TCP: Reconnecting in 30 seconds... '''
-
What hardware are you using for the gateway? Arduino, Sensebender GW, ESP8266, is it wired or wireless?
Does it get an IP address from your router?
Can you successfully telnet to the above IP address on port 5003? (And what is the output)
Does the gateway send any logs to the serial port? If yes, then post them on the forum.
-
@tbowmo
The hardware I'am using for the gateway is the Arduino pro mini and its wireless from the NRF24L01+ 2.4GHz Wireless TransceiverI don't know if it is getting IP address from my router.
have not use telnet before (I have just youtube it and enabled it... all what i got from youtube was that you can send email lol cool)
Does the gateway send any logs to the serial port? If yes, then post them on the forum. (were do I get them logs the ones from Domoticz and below but not much info to go on)
Thanks
-
How is the promini connected to the device runnning domoticz?
To me it sounds like that you have the promini connected directly to your computer where domoticz is running, then you should add it as a serial gateway, and not ethernet gateway
If you haven't already done this, I suggest that you read about the mysensors network so you have a basic understanding on how mysensors works.
-
@tbowmo
I have it runing both ways but with serial gateway there no errors but when going to setup there is no NODES.2017-07-30 19:20:55.764 TCP: Connection problem (Unable to connect to specified IP/Port) 2017-07-30 19:20:55.766 TCP: Reconnecting in 30 seconds... 2017-07-30 19:21:26.035 TCP: Reconnecting... 2017-07-30 19:21:37.093 MySensors: TCP/IP Worker stopped... 2017-07-30 19:27:03.150 MySensors: Using serial port: COM4
-
//#define MY_NODE_ID 1 // Set this to fix your Radio ID or use Auto
IS there someing I have missed with adding NODES???
-
0 MCO:BGN:INIT NODE,CP=RNNNA--,VER=2.1.1 3 TSM:INIT 4 TSF:WUR:MS=0 11 TSM:INIT:TSP OK 13 TSM:FPAR 15 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 2022 !TSM:FPAR:NO REPLY 2024 TSM:FPAR 2026 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 4034 !TSM:FPAR:NO REPLY 4036 TSM:FPAR 4038 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 6046 !TSM:FPAR:NO REPLY 6048 TSM:FPAR 6050 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 8058 !TSM:FPAR:FAIL 8059 TSM:FAIL:CNT=1 8061 TSM:FAIL:PDT 18065 TSM:FAIL:RE-INIT 18067 TSM:INIT 18074 TSM:INIT:TSP OK 18076 TSM:FPAR 18078 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 20086 !TSM:FPAR:NO REPLY 20088 TSM:FPAR 20090 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 22099 !TSM:FPAR:NO REPLY 22102 TSM:FPAR 22104 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 24112 !TSM:FPAR:NO REPLY 24114 TSM:FPAR 24116 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 26124 !TSM:FPAR:FAIL 26125 TSM:FAIL:CNT=2 26127 TSM:FAIL:PDT 36130 TSM:FAIL:RE-INIT 36132 TSM:INIT 36140 TSM:INIT:TSP OK 36142 TSM:FPAR 36144 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 38152 !TSM:FPAR:NO REPLY 38154 TSM:FPAR 38156 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 40164 !TSM:FPAR:NO REPLY 40166 TSM:FPAR 40168 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 42176 !TSM:FPAR:NO REPLY 42178 TSM:FPAR 42180 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 44188 !TSM:FPAR:FAIL 44189 TSM:FAIL:CNT=3 44191 TSM:FAIL:PDT 54194 TSM:FAIL:RE-INIT 54196 TSM:INIT 54203 TSM:INIT:TSP OK 54205 TSM:FPAR 54207 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 56215 !TSM:FPAR:NO REPLY 56217 TSM:FPAR 56219 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 58227 !TSM:FPAR:NO REPLY 58229 TSM:FPAR 58231 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 60239 !TSM:FPAR:NO REPLY 60241 TSM:FPAR 60243 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 62252 !TSM:FPAR:FAIL 62254 TSM:FAIL:CNT=4 62255 TSM:FAIL:PDT 72258 TSM:FAIL:RE-INIT 72260 TSM:INIT 72267 TSM:INIT:TSP OK 72269 TSM:FPAR 72271 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 74280 !TSM:FPAR:NO REPLY 74283 TSM:FPAR 74285 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 76293 !TSM:FPAR:NO REPLY 76295 TSM:FPAR 76297 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 78305 !TSM:FPAR:NO REPLY 78307 TSM:FPAR 78309 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 80317 !TSM:FPAR:FAIL 80318 TSM:FAIL:CNT=5 80320 TSM:FAIL:PDT 90323 TSM:FAIL:RE-INIT 90326 TSM:INIT 90333 TSM:INIT:TSP OK 90335 TSM:FPAR 90337 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 92345 !TSM:FPAR:NO REPLY 92347 TSM:FPAR 92349 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 94357 !TSM:FPAR:NO REPLY 94359 TSM:FPAR 94361 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 96369 !TSM:FPAR:NO REPLY 96371 TSM:FPAR 96373 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 98381 !TSM:FPAR:FAIL 98383 TSM:FAIL:CNT=6 98384 TSM:FAIL:PDT 108387 TSM:FAIL:RE-INIT 108389 TSM:INIT 108396 TSM:INIT:TSP OK 108398 TSM:FPAR 108401 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 110408 !TSM:FPAR:NO REPLY 110410 TSM:FPAR 110413 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 112420 !TSM:FPAR:NO REPLY 112422 TSM:FPAR 112425 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 114433 !TSM:FPAR:NO REPLY 114435 TSM:FPAR 114438 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 116445 !TSM:FPAR:FAIL 116447 TSM:FAIL:CNT=7 116449 TSM:FAIL:PDT
This is my debug log. will like to know if there some thing I missed as I learning thanks
-
Just to be sure, you have one pro mini with NRF24 working as a gateway, connected to your computer?
And then you have one (or more) pro minis also with NRF24, acting as nodes?
-
@tombstone said in Irrigation Controller (up to 16 valves with Shift Registers):
//#define MY_NODE_ID 1 // Set this to fix your Radio ID or use Auto
IS there someing I have missed with adding NODES???
yuo need to uncomment that line
-
Only if he won't use auto id assignment from domoticz.
-
@tbowmo
I habe one pro mini with NRF24 and, connected to my computer. I have done everything from the video up too 22mins were I got stuck.
-
@tbowmo
Do the debug log. Look normal.. don't know how to read.0 MCO:BGN:INIT NODE,CP=RNNNA--,VER=2.1.1 3 TSM:INIT 4 TSF:WUR:MS=0 11 TSM:INIT:TSP OK 13 TSM:FPAR 15 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 2022 !TSM:FPAR:NO REPLY 2024 TSM:FPAR 2026 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 4034 !TSM:FPAR:NO REPLY 4036 TSM:FPAR 4038 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 6046 !TSM:FPAR:NO REPLY 6048 TSM:FPAR 6050 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 8058 !TSM:FPAR:FAIL 8059 TSM:FAIL:CNT=1 8061 TSM:FAIL:PDT 18065 TSM:FAIL:RE-INIT 18067 TSM:INIT 18074 TSM:INIT:TSP OK 18076 TSM:FPAR 18078 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 20086 !TSM:FPAR:NO REPLY 20088 TSM:FPAR 20090 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 22099 !TSM:FPAR:NO REPLY 22102 TSM:FPAR 22104 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 24112 !TSM:FPAR:NO REPLY 24114 TSM:FPAR 24116 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 26124 !TSM:FPAR:FAIL 26125 TSM:FAIL:CNT=2 26127 TSM:FAIL:PDT 36130 TSM:FAIL:RE-INIT 36132 TSM:INIT 36140 TSM:INIT:TSP OK 36142 TSM:FPAR 36144 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 38152 !TSM:FPAR:NO REPLY 38154 TSM:FPAR 38156 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 40164 !TSM:FPAR:NO REPLY 40166 TSM:FPAR 40168 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 42176 !TSM:FPAR:NO REPLY 42178 TSM:FPAR 42180 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 44188 !TSM:FPAR:FAIL 44189 TSM:FAIL:CNT=3 44191 TSM:FAIL:PDT 54194 TSM:FAIL:RE-INIT 54196 TSM:INIT 54203 TSM:INIT:TSP OK 54205 TSM:FPAR 54207 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 56215 !TSM:FPAR:NO REPLY 56217 TSM:FPAR 56219 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 58227 !TSM:FPAR:NO REPLY 58229 TSM:FPAR 58231 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 60239 !TSM:FPAR:NO REPLY 60241 TSM:FPAR 60243 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 62252 !TSM:FPAR:FAIL 62254 TSM:FAIL:CNT=4 62255 TSM:FAIL:PDT 72258 TSM:FAIL:RE-INIT 72260 TSM:INIT 72267 TSM:INIT:TSP OK 72269 TSM:FPAR 72271 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 74280 !TSM:FPAR:NO REPLY 74283 TSM:FPAR 74285 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 76293 !TSM:FPAR:NO REPLY 76295 TSM:FPAR 76297 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 78305 !TSM:FPAR:NO REPLY 78307 TSM:FPAR 78309 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 80317 !TSM:FPAR:FAIL 80318 TSM:FAIL:CNT=5 80320 TSM:FAIL:PDT 90323 TSM:FAIL:RE-INIT 90326 TSM:INIT 90333 TSM:INIT:TSP OK 90335 TSM:FPAR 90337 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 92345 !TSM:FPAR:NO REPLY 92347 TSM:FPAR 92349 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 94357 !TSM:FPAR:NO REPLY 94359 TSM:FPAR 94361 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 96369 !TSM:FPAR:NO REPLY 96371 TSM:FPAR 96373 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 98381 !TSM:FPAR:FAIL 98383 TSM:FAIL:CNT=6 98384 TSM:FAIL:PDT 108387 TSM:FAIL:RE-INIT 108389 TSM:INIT 108396 TSM:INIT:TSP OK 108398 TSM:FPAR 108401 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 110408 !TSM:FPAR:NO REPLY 110410 TSM:FPAR 110413 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 112420 !TSM:FPAR:NO REPLY 112422 TSM:FPAR 112425 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 114433 !TSM:FPAR:NO REPLY 114435 TSM:FPAR 114438 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 116445 !TSM:FPAR:FAIL 116447 TSM:FAIL:CNT=7 116449 TSM:FAIL:PDT
there alot of failing
-
It seems that you have not read up on how mysensors works.. The purpose of mysensors is to create wireless sensors. To do this, we normally have a gateway connected to a computer running some kind of controller software.
Then we have sensor nodes that transmit (wireless) sensor data to the gateway which sends this to the controller software.
Again, please read up on how mysensors are designed, find more here https://www.mysensors.org/about
-
@tbowmo
can you tell me if I got this wrongThe "brain" is my pro min
"The radio" is nRF24
the brain (promiin) get and sends info to the (Radio)
the controller (my PC that is running Domoticz)" gets and send info to the radio.
That's how I get it after reading
-
But how are the radio connected to your pc then? that needs an arduino as well.
To have a functional mysensors network, you usually have 2 (or more) arduino compatible boards. One of thar m running SerialGateway (or another suitable sketch) with NRF24 connected. This connect to the computer running domoticz
Then you have all the sensor nodes, they are also running on arduino compatible hardware (but separate to the gateway hardware), also with radio connected. THIS is running your sensor sketches, and communicates with the gateway arduino via the NRF24 radios.
When the gateway receives messages on the NRF24, it sends these via UART to the computer at which you are running domoticz (or any other suitable controller software).
-
@tbowmo according to the log nothing is assigning any ID
-
@gohan where do you see that? I can't see anything in the log about id assignment.
-
255-255-255-255 isn't it sent when asking for ID?
-
@gohan yes, but also when asking for parent (as indicated by TSM:FPAR). Id-related messages are indicated by TSM:ID.
-
I feel so stupid thought the first video that Pete made serial gateway was just the wiring your your radio up for the irrigation.
-
@tbowmo said in Irrigation Controller (up to 16 valves with Shift Registers):
It seems that you have not read up on how mysensors works.. The purpose of mysensors is to create wireless sensors. To do this, we normally have a gateway connected to a computer running some kind of controller software.
Then we have sensor nodes that transmit (wireless) sensor data to the gateway which sends this to the controller software.
Again, please read up on how mysensors are designed, find more here https://www.mysensors.org/about
Hi Thomas,
You have hit on a point that I see over and over here, and that I shared with @tombstone for a long time before I was able to get a successful MySensors node working. (And I've worked with electronics and tech much of my life.)
Understanding the key components and how they fit together is essential for newcomers to MySensors, and is not very complex, but the information is widely scattered and completely missing from the the top level of the website. This discourages newcomers and creates endless questions on the forums as it is quite difficult to get anything working without many hours of reading and experimenting.
There is no obvious place on the website that explains the big picture as well as your last message! Newcomers to MySensors do not benefit from a clear simple picture of sensor nodes, gateways, and controllers and how they fit together.
- The Getting Started page does not mention controllers at all. And it's NOT as easy as 1, 2, 3!
- The Controller page does not describe the basic purpose of a controller, or how it connects to gateways and nodes. It's a useful advanced comparison of controller details, not beginner content.
- The Build page mentions some of the key components but again not how they fit together. (Nor is it about 'building'.)
- The Hardware doesn't really talk about the hardware.
(I'm sure there is much of this elsewhere on the website, but its not easy to find from the obvious links.)
It would be hugely helpful if Getting Started was an actual detailed overview of MySensors diagramming examples of complete end-to-end systems.
- sensor->arduino+radio node---->arduino+radio gateway->controller (Domoticz etc).
- sensor->gateware/node software->ESP8266 wifi->controller (no 'radio')
- etc.
Gateways are difficult to understand at the beginning as there are so many different ones and the Gateway names don't help...some are named by a single transport protocol (i.e. MQTT) some for an interface (Serial) some for a hardware platform (ESP8266), etc. I'm sure this seems obvious to lifelong engineers/developers but not so much for regular hobby geeks like many hobbyists.
I'm impressed with the work that has gone into MySensors and am grateful for all the hard work by the many developers and users who have contributed to it. I don't mean my comments to be a complaint. Presenting technical systems to often less technical newcomer/users is a challenging area. Improving the first impression of the big picture to newcomers would be a huge move forward.
Tim
-
@Grubstake
I was think of writing a post or making a video (like Pete) for the beginner's. Just an add-on of his work. Not saying his video are not good just saying I like to make more.... Aftrr I know how everything works. Not off on a good start but I get there.
-
@Grubstake I think you missed the page https://www.mysensors.org/about/network
IMHO mysensors made it "easy" to create a sensors network but it can't teach you the basics of arduino programming, I have already told many newbies that first they need to learn with the tutorials and simple exercises otherwise they would have no idea where to look for problems that they will face. Learning how to debug it's as hard as learning to program and in a complex environment like a sensors network it is very easy to get lost.
-
@Grubstake still may have a pont if there's been overs. Not saying we right or your right. But learning is a difficult thing. So is teaching. That's good that we have lots of open source site and when we get stuck members step ins and give a hand.
-
Thanks guys now I understand, felling stupid but it was like a mind blank as was thinking it worked another way.
Can some one point me to the a link (error sending switch command check device/hardware) this comes up when turning on lights on the irrigation controller.
I find this but it didn't makes sense. https://forum.mysensors.org/topic/2553/error-sending-switch-command-check-device-hardware
-
@tbowmo If I can give an opinion, if we want to reach the newcomers, we must start to think on a integrated solution for burning mcus without programming knowledge. I'm also a software architect and my father caught me on electronics, but this is a public project and will also reach people without knowledge.
NodeManager is a great jump on that direction and now we miss a small utility for computers.
And signing+encryption is a problem here.
-
@Sergio-Rius why is signing and encryption a problem? We have a simplified option that enables both using a single define. It can't be made simpler than that without making it enabled by default and then with a common PSK which is pointless. Although still only available in beta it will soon be released.
If you find that too complex, I am all ears for improvement suggestions.
-
@Anticimex Sorry, but I don't follow the development code on a day basis, I was not aware of this feature.
Anyways, a common psk will be like grease. Any psk would be better than no-one.Let me explain: I was thinking on a small Pc program that you can select options (NodeManager) and then burn the chip by a click of a button. But also crossed my mind the possibility that a user, with a running secure network, wanted to get a sensebender gateway already programmed. It would be no use.
I was thinking on a way of "programming the crypto chip" separately from the cpu program. I don't know if it clearer now or I made it worse.
-
@Sergio-Rius there is also a project to integrate NodeManager with a web page to really mask all the code behind to the user.
-
@Sergio-Rius I am still a bit confused.
A default PSK would be the same for everyone so how is that better than no one?
Also, nrf24 radios have problem with full size payloads so enabling signing by default would give some users radio problems by default as well. It is not a problem with signing, it is a problem with the radio.
-
@Sergio-Rius the crypto chip (I prefer the term authentication chip as it does not do cryptography) is connected to the MCU so you need a program on the MCU to program the chip in one way or another. Lest you program the chip before soldering it to the board. And I think the personalization procedure (improved in beta) is documented and simplified enough so that having a separate pc program and do off board programming of the chip would be a far more complicated procedure for "non programmers".
-
@Anticimex I'd add that encryption and signing are more advanced features and should be dealt once newbies get used to the mysensors framework and after they get used to how to debug, otherwise it would also add too much complexity
-
@gohan it is, but it is documented enough so that it should be available to everyone. Obviously that implies people actually read the documentation
-
Guys if you look I been on here for about a year so yes I been reading alot before I started to build. An been look at YouTube video about code and all this.
I have given up on this one for now and I got an pre build one from a another site he have an set by set with networks and so on. I be back later. After I get openhab and MQTT worked out. As I going to be using esp8266 and the MQTT.
-
Hi
Having some issues with the sketch compiling, I am using the 1.84 arduino and the latest libraries 2.1.1 mysensors. I have not made any changes to the sketch at all. Debug is remarked out.
Any help or guidance would be greatly appreciated .
Arduino: 1.8.4 (Windows 10), Board: "Arduino Pro or Pro Mini, ATmega328P (5V, 16 MHz)"
In file included from C:\Users\Audrey\AppData\Local\Temp\arduino_modified_sketch_110779\IrrigationController.ino:95:0:
C:\Users\Audrey\Documents\Arduino\libraries\MySensors/MySensors.h:328:2: error: #error No forward link or gateway feature activated. This means nowhere to send messages! Pretty pointless.
#error No forward link or gateway feature activated. This means nowhere to send messages! Pretty pointless.
^
C:\Users\Audrey\AppData\Local\Temp\arduino_modified_sketch_110779\IrrigationController.ino:99:31: fatal error: LiquidCrystal_I2C.h: No such file or directory
#include <LiquidCrystal_I2C.h>
^
compilation terminated.
exit status 1
Error compiling for board Arduino Pro or Pro Mini.This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
-
@Newzwaver
First, the "error No forward link or gateway feature activated. This means nowhere to send messages! Pretty pointless."
this means that you most likely don't have a radio or other gateway connection type defined. Basically you need to tell it how it is going to communicate to your controller and/or other devices. You need to remove the // from one of the options./ Enable and select radio type attached //#define MY_RADIO_NRF24 //#define MY_RADIO_RFM69 //#define MY_RS485
Next, do you have the LiquidCrystal library installed? If so, is it the correct one? My guess is that it isn't since it cannot find the LiquidCrystal_I2C.h file. You should get the one from GitHub. Start there and let us know what happens.
-
Hello,
Has anybody succeeded in adapting Irrigation Controller to OpenHAB2?
Although a long time experienced programmer, I am new to domotic and begining to explore the subject. OpenHAB seems to be a nicely architectured software, and well documented. The bindings for MySensors define a number of devices types. Which one would be the best choice in that case? How could the Irrigation Controller sketch be adaptated? Is it possible to add V_VAR1..3 to light thing type?
Thank you for your help.
-
I'm replying to myself. After reading OpenHAB doc, I managed to have all functionnalities working without changing the Irrigation Controller code.
I cannot put the whole howto here, but basically I created .things and .items files listed here. In addition, I installed the MySensor gateway on the same Raspberry Pi as OpenHAB, connected as an Ethernet gateway. I also installed MapDB persistence, as explained in the documentation./etc/openhab2/things/house.things
Bridge mysensors:bridge-eth:gateway [ ipAddress="127.0.0.1", tcpPort=5003, sendDelay=200 ] { light all_zones "Toutes zones" [ nodeId=1, childId=0 ] rgbLight zone1 "Zone 1" [ nodeId=1, childId=1 ] rgbLight zone2 "Zone 2" [ nodeId=1, childId=2 ] rgbLight zone3 "Zone 3" [ nodeId=1, childId=3 ] rgbLight zone4 "Zone 4" [ nodeId=1, childId=4 ] rgbLight zone5 "Zone 5" [ nodeId=1, childId=5 ] rgbLight zone6 "Zone 6" [ nodeId=1, childId=6 ] rgbLight zone7 "Zone 7" [ nodeId=1, childId=7 ] rgbLight zone8 "Zone 8" [ nodeId=1, childId=8 ] }
/etc/openhab2/items/house.items
Group House Group Irrigation <water> (House) Group AllZones <water> (Irrigation) Group Zone1 <water> (Irrigation) Group Zone2 <water> (Irrigation) Group Zone3 <water> (Irrigation) Group Zone4 <water> (Irrigation) Group Zone5 <water> (Irrigation) Group Zone6 <water> (Irrigation) Group Zone7 <water> (Irrigation) Group Zone8 <water> (Irrigation) Switch zone0_s "On/Off" (AllZones) { channel="mysensors:light:gateway:all_zones:status" } Switch zone1_s "On/Off" (Zone1) { channel="mysensors:rgbLight:gateway:zone1:status" } Number zone1_1 "Temps toutes zones [%d mn]" (Zone1) { channel="mysensors:rgbLight:gateway:zone1:var1" } Number zone1_2 "Temps individuel [%d mn]" (Zone1) { channel="mysensors:rgbLight:gateway:zone1:var2" } String zone1_3 "Nom [%s]" (Zone1) { channel="mysensors:rgbLight:gateway:zone1:var3" } Switch zone2_s "On/Off" (Zone2) { channel="mysensors:rgbLight:gateway:zone2:status" } Number zone2_1 "Temps toutes zones [%d mn]" (Zone2) { channel="mysensors:rgbLight:gateway:zone2:var1" } Number zone2_2 "Temps individuel [%d mn]" (Zone2) { channel="mysensors:rgbLight:gateway:zone2:var2" } String zone2_3 "Nom [%s]" (Zone2) { channel="mysensors:rgbLight:gateway:zone2:var3" } Switch zone3_s "On/Off" (Zone3) { channel="mysensors:rgbLight:gateway:zone3:status" } Number zone3_1 "Temps toutes zones [%d mn]" (Zone3) { channel="mysensors:rgbLight:gateway:zone3:var1" } Number zone3_2 "Temps individuel [%d mn]" (Zone3) { channel="mysensors:rgbLight:gateway:zone3:var2" } String zone3_3 "Nom [%s]" (Zone3) { channel="mysensors:rgbLight:gateway:zone3:var3" } Switch zone4_s "On/Off" (Zone4) { channel="mysensors:rgbLight:gateway:zone4:status" } Number zone4_1 "Temps toutes zones [%d mn]" (Zone4) { channel="mysensors:rgbLight:gateway:zone4:var1" } Number zone4_2 "Temps individuel [%d mn]" (Zone4) { channel="mysensors:rgbLight:gateway:zone4:var2" } String zone4_3 "Nom [%s]" (Zone4) { channel="mysensors:rgbLight:gateway:zone4:var3" } Switch zone5_s "On/Off" (Zone5) { channel="mysensors:rgbLight:gateway:zone5:status" } Number zone5_1 "Temps toutes zones [%d mn]" (Zone5) { channel="mysensors:rgbLight:gateway:zone5:var1" } Number zone5_2 "Temps individuel [%d mn]" (Zone5) { channel="mysensors:rgbLight:gateway:zone5:var2" } String zone5_3 "Nom [%s]" (Zone5) { channel="mysensors:rgbLight:gateway:zone5:var3" } Switch zone6_s "On/Off" (Zone6) { channel="mysensors:rgbLight:gateway:zone6:status" } Number zone6_1 "Temps toutes zones [%d mn]" (Zone6) { channel="mysensors:rgbLight:gateway:zone6:var1" } Number zone6_2 "Temps individuel [%d mn]" (Zone6) { channel="mysensors:rgbLight:gateway:zone6:var2" } String zone6_3 "Nom [%s]" (Zone6) { channel="mysensors:rgbLight:gateway:zone6:var3" } Switch zone7_s "On/Off" (Zone7) { channel="mysensors:rgbLight:gateway:zone7:status" } Number zone7_1 "Temps toutes zones [%d mn]" (Zone7) { channel="mysensors:rgbLight:gateway:zone7:var1" } Number zone7_2 "Temps individuel [%d mn]" (Zone7) { channel="mysensors:rgbLight:gateway:zone7:var2" } String zone7_3 "Nom [%s]" (Zone7) { channel="mysensors:rgbLight:gateway:zone7:var3" } Switch zone8_s "On/Off" (Zone8) { channel="mysensors:rgbLight:gateway:zone8:status" } Number zone8_1 "Temps toutes zones [%d mn]" (Zone8) { channel="mysensors:rgbLight:gateway:zone8:var1" } Number zone8_2 "Temps individuel [%d mn]" (Zone8) { channel="mysensors:rgbLight:gateway:zone8:var2" } String zone8_3 "Nom [%s]"
Note the "trick" is to use rgbLight item type instead of light item type, to have Var1..3 available. Look here: https://github.com/tobof/openhab2-addons/blob/MySensors_Binding/addons/binding/org.openhab.binding.mysensors/ESH-INF/thing/thing-types.xml
Now I have a fully fonctionnal Irrigation Controller, all integrated with OpenHAB
-
Hi All,
Does anyone have a schematic/wiring diagram for this (especially the shift register)?
I may be too old, but the Fritzing image on the build page isn't clear to me.
-
@Spanners Which part is confusing you, the wiring to the 74HC595? Does this help at all?
-
@dbemowsk Thanks, that clears it up.
I ended up going with a Mega with LCD Shield and used additional digital pins for the relays. I wanted to enable the IRQ buffering for the NRF radio and some LCDText devices to report back to Vera some status information. Sadly I had to use Strings as I struggled to get char[] arrays to work. Got a bit hard to fit onto the memory of the Pro Mini.
I needed 2 controllers for front and back, one with Master Valve setup. The back reticulation is an extension of front zone - so Vera makes sure the front controller supplies water when the back controller is active.
If there's interest I'll post the code, maybe someone with better skills than me could rewrite the String section - I don't know if I'll have issues with memory fragmentation yet. Only installed them today.
A big thank you to @petewill and @BulldogLowell for sharing their code and design.
-
@Spanners So you are saying that you just used digital IO lines instead of using the shift register? BTW, I like the case, looks expensive. Do you use the 5 keys on the keypad shield for anything?
-
@dbemowsk yep, I left out the shift register and just used additional IO pins.
The case was AU$28 at a local electronics supplier, or AU$10 from ebay. IP66 rated, should keep the Arduino's safe from the elements.
The LCD keypad has a reset button (handy for reloading all valve changes) and a select button which I'm using to do the same thing as the external button in the original design (I still have the exterior button as well). The other buttons could be used for a local menu system or for dialling in a custom manual run time or something, but I haven't pursued it as I don't intend to physically touch them very often.
I've got a problem that'd developed with the front controller - almost like the button/interrupt is triggering whenever the relays are energised/de-energised. It's not consistent though and I'm betting its power related.
The whole unit is powered by a 12VDC adaptor. The relays are powered by a separate DC-DC 5V supply off that 12V, and the Mega takes 12V on VIN and powers the LCD and the radio.
-
Ok, found my issue - hopefully you guys can give me a suggestion on how to fix it.
It basically is the external button being triggered (immediate irrigation halt or starts running all zones after shutdown). And it's caused by the 24VAC power running through the relays.
If I shut down the 24VAC power it works great. If I unplug the external button (brown wire in picture just above the LED), I have no issues either.
I'm not using an external resistor for that switch (PIN 21 to GND) - do you think that would solve the issue with interference from the 24VAC? Or is there another solution to these types of issues?
pinMode(waterButtonPin, INPUT_PULLUP); attachInterrupt(digitalPinToInterrupt(waterButtonPin), PushButton, LOW); //May need to change for your Arduino model
It seems a bit counterintuitive, because how would the 24VAC which is presumably creating a magnetic field and inductive current in brown wire result in it reading LOW?
-
@Spanners Do you in any way have one leg of the 24V supply connected to low voltage side? Possibly the ground?
@Spanners said in Irrigation Controller (up to 16 valves with Shift Registers):
If I shut down the 24VAC power it works great.
When you have the 24V connected, is it under any load? And, What does this brown wire connect?
-
The 24VAC is completely isolated - it connects to the relays to power solenoids only, common wire like @petewill shows in his video. The other connection for the 24VAC is to the common wire on the solenoids. There's no path from the 24VAC to the Arduino.
24VAC is only under load when a relay is active and powering a solenoid. It's when a relay opens or closes that the external button interrupt is triggered (about 80% of the time).
The brown wire is PIN 21 to the external button, the other side of the button is connected to GND. If that wire is disconnected, I don't see the issue - so it's like the start/stop of 24VAC current flow is creating enough magnetic action/induced current or something on the wire and PIN 21 to trigger the interrupt.
-
@Spanners Does the arduino input for the switch (brown wire) have a pull up (or pull down depending on your use case) resistor on it? Something like this:
If the arduino input is left floating when the button is in an unpressed state, I suppose that induction could possibly cause enough fluctuation to cause it to trip that switch input. The arduino inputs are very sensitive and the brown wire may be acting like an antenna and picking up enough induced current from the 24v side to trip the input. The 24 volts used is typically AC which would affect something like that more than a DC voltage would, so when one of the relays turns on, then you have the AC current flowing which could easily be picked up by your brown wire (the antenna). When you disconnect the brown wire, there is no more antenna to sway the input. Read the first response to this guys question. Pull up/down resistors simply bias that input to a given state (high or low) when no expressed input is given (unpressed switch).
-
@dbemowsk - you da man. Thanks for the help.
I was using the internal pull up on the Arduino and it wasn't enough to deal with the interference from the 24VAC. Added a 4.7k resistor to the switch with connection to Vcc as per your diagram and it's now working reliably.
Also needed to add a repeater node as the rear retic controller sits inside a garden feature that is made from 250mm thick limestone blocks. Comms were a little hit and miss.
-
Hi guys, I’m trying 2 days to compile this sketch for Domoticz. Still getting errors ones from library then from code...
Can someone share with me his working code for Domoticz in 2.0 version? Thanks a lot
-
@mikee It helps for us to know what errors you are getting.
-
Hi @dbemowsk , Thanks for your reply. I had to reinstall Arduino IDE and all Libraries from my PC. I was fighting with „'POSITIVE' was not declared in this scope“ error, and installed over 6 Libraries for LCD. I got finally working the sketch for Vera from Mysensors/build, at least .
Unfortunately I’m not able to modify Sketch witch are guys using with Domoticz in this Topic.
Is there a way to get missing variables into Irrigation controller from domoticz or at least to set them manually in sketch? For me is enough one watering time for all valves.
-
@mikee This was actually one of the reasons I switched from Domoticz to a Vera controller a couple years ago. The main issue at the time had to do with the use of V_VAR1 - V_VAR3 which is used to configure the valve names and the valve times. I wanted to have the ability to change the valve times.
For your situation though, you can modify your Zone names in the code by changing this bit:
// Name your Zones here or use Vera to edit them by adding a name in Variable3... String valveNickName[17] = { "All Zones", "Zone 1", "Zone 2", "Zone 3", "Zone 4", "Zone 5", "Zone 6", "Zone 7", "Zone 8", "Zone 9", "Zone 10", "Zone 11", "Zone 12", "Zone 13", "Zone 14", "Zone 15", "Zone 16" };
Depending on the number of zones you have, just change the names in quotes for Zone 1, Zone 2, etc... up to the number of valves that you have.
I have been told recently though that Domoticz now supports V_VAR(x), but I am not sure how to use it just yet.
-
Hi, my module works with 8 relays but when i try to expand to 16 relays i have an issue. The 2nd register heats up and the pro mini keep restarting / re-initializing. I think i have the wrong connections for the 2nd register. Can anyone help / share what the wiring for the 2nd register should be?
-
@mfalkvidd Is this #3 of same question?
-
@zboblamont yes indeed.. If anyone can help @annujbhatia, please post in https://forum.mysensors.org/topic/9434/problem-with-2nd-register-heating instead of here, to keep all information in the same place.
-
Hi @johnecy, know it has been a long time from your post, but I have implemented the script recently and am having the same issue that you mentined. please, how do you solve it?
@johnecy said in Irrigation Controller (up to 16 valves with Shift Registers):
I have the irrigation controller all setup and working. I have one problem though as soon as I power it up with 5 volts for the pro mini sometimes one sometimes all the relays come on. If I am not home the water runs all day is there a programing change or a wire change I need to make to stop this. I was using the old wire diagram without the pull up on pin 13 of the 74hc I changed to the new version and added the lines off code but it still does not help.
-
Hello,
I have build the irrigation controler this weekend and just found out that there are some issues using this with domoticz.
Is there someone willing to share his customized code to get these zone and time variables working ?Thanks in advance,
Edwin
-
@edweather I had a lot of this working in Domoticz years ago. I have since switched to Vera, but here is a link to an old post I had on the subject.
https://forum.mysensors.org/topic/153/irrigation-controller-up-to-16-valves-with-shift-registers/216
-
@dbemowsk Thank you!
Suggested Topics
-
Welcome
Announcements • • hek