LowPowerLab Forum

Hardware support => MoteinoMEGA => Topic started by: sam_uk on November 23, 2016, 01:31:57 PM

Title: Range & Data rate
Post by: sam_uk on November 23, 2016, 01:31:57 PM
Hi I'm looking for a wireless solution that will

1) Mesh together
2) Carry 16Kbps
3) Have a range of a mile or more
4) Cost less than $50 per node

Is the Moteinomega a platform that can do this?
Title: Re: Range & Data rate
Post by: Felix on November 23, 2016, 02:10:38 PM
I believe all  the points are achievable but:

- depends what radio you use, this will determine a lot of factors
- you will have to invest some time to tweak the out-of-box settings to achieve the range (lowering bitrate to 16k etc)
- meshing is something you might need to do yourself if you use the RFM69 library - RadioHead has this ability (for RFM69, not sure about LoRa) but I don't know how well it works
Title: Re: Range & Data rate
Post by: perky on November 23, 2016, 03:06:48 PM
Forgive me if I'm wrong, but doesn't the Radiohead require all routers (not end devices) to be permanently powered?
Mark.
Title: Re: Range & Data rate
Post by: Felix on November 23, 2016, 04:11:53 PM
Quote from: perky on November 23, 2016, 03:06:48 PM
Forgive me if I'm wrong, but doesn't the Radiohead require all routers (not end devices) to be permanently powered?
Mark.
You mean always in RX (listening) mode? Yes it does.
So that would be a minimum of around 15mA just for the radio, assuming the MCU could sleep.
Title: Re: Range & Data rate
Post by: perky on November 23, 2016, 05:38:24 PM
Yes, sorry that's what I meant. Having sleeping routers or true mesh networks with all nodes sleeping is a hard nut to crack. One day when I have enough money so I don't have to work for a living I'd like to have a go at cracking it for a personal challenge... ;)
Mark.
Title: Re: Range & Data rate
Post by: sam_uk on November 23, 2016, 05:44:55 PM
15mA is no problem for me.

Has anyone tried radiohead on these?

Thanks

Sam
Title: Re: Range & Data rate
Post by: i670 on November 25, 2016, 02:16:48 AM
I use radiohead mesh on four megas with 433mHz LORA.  Two of the nodes are always on and the other two are only active when they are sending.  One of the always on megas is an ethernet bridge to the internet (thingspeak). I originally used reliable_datagram but needed to switch to mesh, as all the radios could not reliably see each other.  I don't recall any real challenges with radiohead but had several with the ethernet code.  The power consumed by the ethernet module is significant and so sleeping it is required.  The key is that a dhcp request must be done every time you wake the ethernet.  Strange but true, it seems.

dave
Title: Re: Range & Data rate
Post by: Felix on November 25, 2016, 08:47:32 AM
@i670684,
I wonder how ethernet nodes are more feasible than something like a RaspberryPi.
It almost sounds like in your case it's because the node has to be low power and needs to sleep?
In that case sleeping it in between ethernet transmissions would still amount to less overall needed power and faster wakup-dhcp-send-sleep cycles than a Pi.
Title: Re: Range & Data rate
Post by: i670 on November 25, 2016, 03:14:42 PM
Felix,

I avoided the RPI due to power usage (my whole setup is solar powered) and to avoid having to maintain a different technology.  It would have allowed for a more powerful gateway but I don't need more throughput than provided by the mega.  I think if I had many more nodes throwing data at the gateway I might need to change it. 

dave
Title: Re: Range & Data rate
Post by: Felix on November 25, 2016, 04:16:03 PM
That makes sense.
How do you solar-power your setup? Ie what solar panel, does it also charge a battery? Do you use some kind of controller for that?
Title: Re: Range & Data rate
Post by: i670 on November 25, 2016, 05:23:50 PM
Felix, for the gateway in my shed, I have a 100w pv panel that provides for a number of uses, including throwing a wifi signal around the area and is just a general source of 12v or 240v.  The "uplink" is wifi directionally beamed to a hilltop with again a solar panel and tiny industrial 3g/4g router.  The other moteino nodes have tiny solar panels and usually a dfrobot solar lipo charger.  It would be terrific if the megas came with a solar lipo charger, but this approach also seems to work ok.  One node is a weather station with anemometer, another measures stock water tank level, one controls a remote water pump (solar-powered) and another monitors river level so that when it is in flood I won't pump silt and sand.  The mega is a great piece of kit!

dave
Title: Re: Range & Data rate
Post by: Felix on November 27, 2016, 10:06:38 PM
Thanks dave,
I may try to put my mind to make a lipo powered Moteino :)
Just not sure if that will be the 328 or 1284. Suggestions for features are welcome.
Title: Re: Range & Data rate
Post by: i670 on November 28, 2016, 02:02:00 AM
Felix, that enhancement would truly make the Moteino unique, I think.  It would be great to include a voltage divider for easy measurement of both input and battery voltages.  Protect the lipo from drain below full-discharge. Everything else is frills, imho. 

I've tried to optimise my code but found the Moteino just doesn't have enough memory for more complex applications and interesting networking stacks (Radiohead Mesh, is out of the question but even ReliableDatagram leaves very little).  I don't need all the i/o that comes with the Mega but that memory is priceless. 

dave
Title: Re: Range & Data rate
Post by: Felix on November 28, 2016, 08:06:23 AM
Dave, all great points., thanks.
There are other lipo power nodes out there, i need to catch up to my competition :)
I chose the atmega1284p just for those aspects which you point out, and the advantage of having a core which just works in arduino, very compatible with the 328p and every sketch just works without monkeying around with library mods and defines. Yes they're both 8bit and don't have floating point etc, but the simplicity is what attracts me and i think many others.
FWIW all my basic IoT nodes are 328p based (regular Moteino) not MEGA since for all the things I needed to automate the 328p is PLENTY (memory, GPIO etc).
I even developed a "mesh" library for RFM69, never released and while it starts to push the memory it still works fine on the 328p.
Title: Re: Range & Data rate
Post by: thepez on December 06, 2016, 12:02:03 PM
Hi Felix, I'm new here but have been reading a lot of posts and playing around with your library.  I am tending to lean towards it more then the Radiohead library because its much easier to work with.  I was hoping you might be able to put some of that "mesh" code you might have up.  :)  The project I am working on will connect about 50 or so RFM69HWs in a forest region (I'm Canadian, lol) to monitor weather patterns in a mesh type setup because I need the range and then collect that sensor data in intervals into an Elastic search database for analysis.  I can write my own Mesh setup but am not too experienced in using hash tables across nodes.  I see above another fellow is doing something similar with solar power and will probably incorporate something similar.  Any advice on the mesh part would be great!  Thanks for writing a great library.  Cheers.
Title: Re: Range & Data rate
Post by: Felix on December 06, 2016, 01:14:59 PM
Hi thepez,
Thanks for the feedback,
I am not ready to release any mesh code right now. It's somewhat older code and would need a fair bit of testing and I don't have the time in the very near future. Also I refrained from releasing that since it might become a support sinkhole - everyone seems to think meshing is the best solution to everything wireless.
I may do it or not, I cannot promise.
Title: Re: Range & Data rate
Post by: i670 on December 07, 2016, 05:49:25 AM
Thepez,

Have you tried Radiohead mesh?  I found it trivial to switch from a basic point to point network to routed to mesh.  Once I had the basic logic working with the basic reliableDatagram protocol, I could play around with the others. 

I have a decent-sized property and found with mesh I didn't need to tune the rf and antenna setup to get from the farthest node to the gateway.  My data requirements are infrequent transmissions of small payloads so LORA 433 mHz and mesh seems to work fine.  I should probably have tried the higher frequency modules first, given the shorter antennas that would have allowed.  Also not sure I needed LORA at all but now I'm invested in 433 LORA so that's that.  I like being able to just throw another node out (monitor a gate, the river level, soon a motionMote I've tweaked to handle the radiohead memory footprint...) and not have to think about about topology.  All data goes to thingspeak.com and some to wunderground.

Maybe a cow-mounted node is next, but they tend to rub up against things and I think the node would be toast soon enough.  Kangaroo-mounted would be cool but I'm not that brave.