@mfalkvidd , I see. That makes sense, thanks.
Posts made by Frank C
-
Depreciated Code
There are some really great dev options here for building sensors
I'm looking at using
mGetCommand
in my sketch to read the command sent to my node. I read thatmGetCommand
is marked as Depreciated in the code, and that this and many other methods are marked as Deprecated, as mentioned in the "Deprecated List":- https://www.mysensors.org/apidocs-beta/deprecated.html
- https://www.mysensors.org/apidocs-beta/group__MyMessagegrp.html#gae2370fc35a3e46b0d83d1efeb9947701
Is there a date when these methods will be obsolete and/or replaced ?
And is there somewhere to find other methods to use that are not being currently deprecated ?
I'm using version 2.3.1 -
RE: Adafruit Feather RFM9X LoRa Radios
I've been busy the last day or so.. and I've now got the radios communicating!
i've used the pin config given by adafruit:
https://learn.adafruit.com/adafruit-feather-m0-radio-with-lora-radio-module/pinoutsi've read about timeouts for these lora boards, so i've upped the values in the both sketches.
https://forum.mysensors.org/topic/8813/any-success-story-on-lora-rfm95-module-and-mysensors#define RFM95_RETRY_TIMEOUT_MS (5000ul) #define MY_TRANSPORT_STATE_TIMEOUT_MS (20*1000ul) #define MY_RFM95_TX_TIMEOUT_MS (10000ul)
I spaced the radios about a 1m apart and they now communicate i'm not sure if distance helped.
Also with the above timeouts they aren't needed at such a short distance. -
RE: Adafruit Feather RFM9X LoRa Radios
hi @mfalkvidd, ah yes.
It doesn't show any connection between the nodes, logs look okay.
GW log:0;255;3;0;9;20830 MCO:BGN:INIT GW,CP=RLNGS---,REL=255,VER=2.3.1 0;255;3;0;9;21071 TSF:LRT:OK 0;255;3;0;9;21081 TSM:INIT 0;255;3;0;9;21151 TSF:WUR:MS=0 0;255;3;0;9;21161 RFM95:INIT 0;255;3;0;9;21177 RFM95:INIT:PIN,CS=8,IQP=3,IQN=3,RST=4 0;255;3;0;9;21197 RFM95:PTX:LEVEL=10 0;255;3;0;9;21208 TSM:INIT:TSP OK 0;255;3;0;9;21218 TSM:INIT:GW MODE 0;255;3;0;9;21228 TSM:READY:ID=0,PAR=0,DIS=0 0;255;3;0;9;21238 MCO:REG:NOT NEEDED 0;255;3;0;14;Gateway startup complete. 0;255;0;0;18;2.3.1 0;255;3;0;9;21249 MCO:BGN:STP 0;255;3;0;9;21259 MCO:BGN:INIT OK,TSP=1 0;255;3;0;9;21270 TSM:READY:NWD REQ 0;255;3;0;9;21280 RFM95:SWR:SEND,TO=255,SEQ=0,RETRY=0 0;255;3;0;9;23430 TSF:MSG:SEND,0-0-255-255,s=255,c=3,t=20,pt=0,l=0,sg=0,ft=0,st=OK:
and the sensor log:
1764594 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 1784606 !TSM:FPAR:FAIL 1784616 TSM:FAIL:CNT=7 1784626 TSM:FAIL:DIS 1784636 TSF:TDI:TSL 1784646 RFM95:RSL 1844657 TSM:FAIL:RE-INIT 1844667 TSM:INIT 1844704 RFM95:INIT 1844719 RFM95:INIT:PIN,CS=8,IQP=3,IQN=3,RST=4 1844740 RFM95:PTX:LEVEL=10 1844750 TSM:INIT:TSP OK 1844760 TSM:FPAR 1844770 RFM95:SWR:SEND,TO=255,SEQ=0,RETRY=0 1846921 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 1866933 !TSM:FPAR:NO REPLY 1866943 TSM:FPAR 1866953 RFM95:SWR:SEND,TO=255,SEQ=1,RETRY=0 1869103 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 1889115 !TSM:FPAR:NO REPLY 1889125 TSM:FPAR 1889135 RFM95:SWR:SEND,TO=255,SEQ=2,RETRY=0 1891285 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 1911297 !TSM:FPAR:NO REPLY 1911307 TSM:FPAR 1911317 RFM95:SWR:SEND,TO=255,SEQ=3,RETRY=0 1913467 TSF:MSG:SEND,255-255-255-255,s=255,c=3,t=7,pt=0,l=0,sg=0,ft=0,st=OK: 1933479 !TSM:FPAR:FAIL 1933489 TSM:FAIL:CNT=7 1933499 TSM:FAIL:DIS 1933509 TSF:TDI:TSL 1933519 RFM95:RSL 1993531 TSM:FAIL:RE-INIT 1993541 TSM:INIT 1993580 RFM95:INIT 1993595 RFM95:INIT:PIN,CS=8,IQP=3,IQN=3,RST=4 1993616 RFM95:PTX:LEVEL=10
-
RE: Adafruit Feather RFM9X LoRa Radios
I got the two feather M0 RFM96 Lora 433Mhz (https://www.adafruit.com/product/3179) units running in MySensors, one as the GW and another using the MockMySensors sketch. They both seem to be running fine, I increased the timeouts as others have instructed. Although they units aren't communicating with each other.
I've got the following setup in my sketches#define MY_RADIO_RFM95 #define MY_DEBUG_VERBOSE_RFM95 #define MY_RFM95_FREQUENCY (RFM95_434MHZ) #define MY_RFM95_MODEM_CONFIGRUATION (RFM95_BW125CR45SF128) #define RFM95_RETRY_TIMEOUT_MS (10000ul) #define MY_TRANSPORT_STATE_TIMEOUT_MS (20*1000ul) #define MY_RFM95_TX_TIMEOUT_MS (10000ul) //Adafruit M0 Feather Lora RFM95 #define MY_RFM95_IRQ_PIN 3 #define MY_RFM95_IRQ_NUM MY_RFM95_IRQ_PIN #define MY_RFM95_CS_PIN 8 #define MY_RFM95_RST_PIN 4
I'm still fairly new to this so I'll keep trying to get them talking. Any ideas or hints appreciated?
-
RE: Adafruit Feather RFM9X LoRa Radios
Yes, this works using the radiohead library and those sketches. I didn't need to connect any extra wires. I'm not looking at connecting to LoRaWAN at the moment, just mysensors.
I read the board is similar to Arduino Zero also, so i will try using that as a base and try fixing forward so the feather M0 with lora can work with mysensors, if nobody has had this working yet? (mysensors with adafruit feather m0 LoRa RFM9*).
Thanks -
RE: Adafruit Feather RFM9X LoRa Radios
@pierrot10 I've got my two new M0 ATSAMD21 boards talking, so the hardware is good :), i used the radioheads library. These definately sound a better chip than the 32u4, although I'll have to see how they go on battery comsumption.
This might sound dumb but I can't compile mysensors scripts (serial gateway) with my boards, I'm using adafruits board defination. Looking at mysensors i can't see this board, except the Sensebender (ATSAMD21), but it has a completely different pin layout. Does that mean I need to map each ping to the correct reference in the code to get this to work with mysensors ? -
RE: Adafruit Feather RFM9X LoRa Radios
Thanks @pierrot10, that is fantastic!
I actually have a dead feather 32u4 now, so will order more, but after reading what you say it sounds like the M0 model with the newer updated chipset is a better option.
Just a question on running the base lora radio (feather M0) to a raspberry pi, i presume it will work okay using the standard serial/USB connection. I haven't tried it, as my radio is dead.
Anyway I better order these new ones and getting making, thanks -
RE: Adafruit Feather RFM9X LoRa Radios
Thanks very much @pierrot10, that is exactly what i was looking for :). I've got 2x Adafruit Feather 32u4 LoRa Radio, which has the the ATmega32u4 chipset. I believe the M0 model has the newer ATSAMD21G18 chipset. I think apart from the libraries, it should work the same.
-
Adafruit Feather RFM9X LoRa Radios
I'm trying to connect a Feather bord using the Lora radio to mysensors and i can't get any reception. I've looked through the forums and documentation but I can't see if it is actually supported by mysensors, any help appreciated in pointing me in the correct direction? or if anyone knows if it is compatiable ? thanks
-
RE: Serial Gateway and MQTT Broker
@jkandasa Thanks for the follow up. I can see MyController is modifying the serial message into a customized MQTT msg (as you have said).
MyController works great with the serial so it would be good to keep that as is, and if we had an independent service to publish to a separate MQTT broker would be very helpful? -
RE: Serial Gateway and MQTT Broker
@FotoFieber MyController is getting the MQTT msg, but doesn't like it's format, i've had continuous error msg like below:
2017-02-16 18:17:34,657 ERROR [Thread-4] [org.mycontroller.standalone.provider.mysensors.MySensorsProviderBridge:60] Unable to process this rawMessage:RawMessage(gatewayId=2, data=2;0;1;0;23;36, subData=mysensors/1/out/, isTxMessage=false, networkType=MY_SENSORS)
org.mycontroller.standalone.message.RawMessageException: Unknown message format, Topic:mysensors/1/out/, PayLoad:2;0;1;0;23;36
at org.mycontroller.standalone.provider.mysensors.MySensorsRawMessage.updateMQTTMessage(MySensorsRawMessage.java:114) ~[mycontroller-dist-standalone-0.0.3.Alpha2-single.jar:0.0.3.Alpha2]MyController is set up with the correct topic, as seen in above Topic:/mysensors/1/out/ (i've also tried without the ending /).
-
RE: Serial Gateway and MQTT Broker
@FotoFieber Thanks for the suggestion, I got that working. I have had to change MyController to read an MQTT gateway. Problem now is MyController can't read the MQTT format of this script. Any suggestions or tips ?
MyController does such a great job with handling MySensors' data, it would be a pity to loose that functionality. -
RE: Serial Gateway and MQTT Broker
@jkandasa As a seperate service is okay, it would be very helpful. Thank you
-
RE: Serial Gateway and MQTT Broker
@jkandasa That would be fantastic if you could ? I think it would be a great feature
-
RE: Serial Gateway and MQTT Broker
@jkandasa is there a future feature to push serial-gateway messages with MyController's build in MQTT? It would a great feature.