One of the pieces of the puzzle which is my greenhouse project is communicating back to my apartment.
Due to me renting and the position of the (kitset 1.8m x 1.8m) greenhouse, running power or PoE is not feasible, so It’s going to rely on solar power … but that’s a different issue.
I am currently setting up an ESP32-CAM (never got the camera working, so ignore the cam) to take readings from several sensors on a regular basis to send back to my Home Assistant setup inside my apartment. While I’m bench testing, it is working great using the built-in wi-fi aerial … but I half expect that the distance from the greenhouse to the laundry could be too much for the tiny built-in aerial.
In the shared laundry (closest to the greenhouse - less than 10m) I have (until it died a few days ago) a TL-WPA4220 powerline wi-fi adaptor which would happily connect to my mobile phone in the greenhouse. I am conscious of the amount of metal appliances in the laundry, that radio signal are absorbed by rain, and that the ESP’s built-in aerial is almost certainly smaller and probably weaker than a mobile phone’s aerial.
So thinks I, the ESP32-CAM has a tiny connector for an external aerial (as do several other of the ESP32 boards), and I could use a directional antenna at the greenhouse end. Assuming i’m on the right track I found Core products:
So I’m asking for a sanity check. Does this sound reasonable, and are these the products I will need ? Is there a preference for the cables or will the cheapest work just as well ?
I have an ESP32 running inside my tin shed with an omni antenna I scavenged from an old wifi router. The shed is about 20m from where I have my wifi repeater setup and it works fine. So you may not need a flat panel directional antenna for your project, the boost in signal strength you get from almost any well made antenna will often do the trick. I’ve even made my own 1/4 and 1/2 wavelength antennas out of a piece of copper wire with ESP boards that have the UFL connector on board and they work well too.
That being said the parts you linked should work fine, I’d just go for the cheap ones myself.
Edit: I just checked how far away the shed is to make sure I wasn’t leading you astray and it’s only 15m from where I have my repeater. The ESP is located about 1m further inside the shed but it’s been working well even with the doors closed.
At that range I’d recommend testing it before getting an antenna. I’ve streamed video from one of my ESP32s a bit further than that in the past without using its antenna. Let us know how you go.
It costs me nothing to start by using the ESP32-CAM as is
I’m sure I can scavenge an antenna from an old wi-fi something, as plan “b”.
And if that proves unsatisfactory then plan “c” can be buying the directional antenna … and all I’m out is the cost of a RP-SMA to U.FL cable at plan b. I can live with that.
Thank you both for easing my mind about that aspect of this project. Now I just have to arrange to replace the powerline + WAP in the laundry. Might not get it in the budget before christmas though
Sometimes just the way you mount the device (ESP32 CAM) in your case can make a difference in regards to range. I’ve never seen an analysis of the radiation pattern emitted from one using the printed antenna built into the board but the design is really a compromise to cram it into a small space, so its output pattern would be far from optimal.
So if you experiment with the orientation of the CAM board (without an external antenna) sometimes you can gain a few metres of range because it can help you match up the polarisation (it’s not really poarisation but that’s a simple way to explain it) of the sending and receiving antennas. The same applies to an omni antenna, you want the antennas both aligned roughly the same way ie have them both in a vertical position or both in a horizontal position and both antennas parallel to each other.
If you have obstacles in the line of sight between the sender and the receiver some weird things can happen to the signal along the way, so the optimal orientation and the antennas can be affected. So in that case the alignment of the antennas might need to be adjusted slightly.
I assumed it is just a matter of using a short cable with U.FL connector at one end, and the appropriate connector (probably SMA or RP-SMA) at the antenna end.
Can you provide a link to more info about this antenna compatibility issue, because my search didn’t find anything obvious.
Hi Donald
You will have to have a close look at this UFL connection or it might be in the documentation.
There might be a solderable link to select internal or external antenna use. If you use an external antenna you will have to make the appropriate connection. I don’t think it would be a good idea to try and use internal and external antennas together. May not work too well.
Study this SMA business as well. There are two flavours, SMA and Reverse SMA. The reverse is where you find a male pin instead of an expected female socket and vice versa. I don’t know of any laid down standards for antennas, there might well be.
Cheers Bob
A fair bit has changed (along with plenty of A-grade procrastinating) and I have now taken my ESP32 greenhouse control module out to the greenhouse and trying to connect via wi-fi …
Since writing the original post I purchased a ESP32-S3-devkitC-1 cheap, and when I found it doing funny things with deep_sleep I replaced it with a ESP32-S3-zero (WS-25081) … which also exhibits the same behaviour.
So, I took this ESP32-S3-mini board with the tiny ceramic antenna out to my greenhouse and reset it. I checked the wi-fi signal at the greenhouse with my phone, and it was marginal I have changed the channel on my WAP in the laundry (line of sight, about 15m), and swapped from “low” to “high” transmit power.
So far, it seems to be OK. I am receiving the ESPHome log (via wi-fi), and Home Assistant is receiving sensor data values. Having the solar panel pointed north on a cloudless day is working so much better than pointing at the late afternoon sky.
The bigger issue will be how it handles rainy days … both because of less sun; but also that water absorbs radio signals, so the wi-fi signal might reduce enough for it to become a problem.
I was thinking to buy a Firebeetle 2 ESP32-C6 with LiPo and solar panel connections direct to the ESP32 board - but found the TinyC6 (ESP32-C6 with u.FL connector) (CE10217) which does all that in a size that fits on a breadboard yet has a good number of pins. Well, that can go on the back burner while I finish off other things … like controlling and monitoring water flow, and using Ethernet cables to connect sensors to my control module.
business opportunity ?
I am still rather surprised at the lack of small but directional antennas. Surely most IoT devices really just need a point-to-point link to the WAP, and the rest of the power coming from their omni-directional antenna signal is just wasted. Microcontroller board manufacturers are placing u.FL connectors on boards, which indicates they recognise a need for better external antennas … but where are they ?
There are plenty of antennas around. The most popular I think would be the “Yagi” type.
Google “WiFi antennas” or “900MHz antennas” or what ever you are after.
Unfortunately these two criteria don’t go together. If you want directivity (and thus gain) the antenna will get progressively bigger depending on what sort of directivity ratio you are after. For instance popular 2.4GHz Yagi with a gain of 13dbi to 16dbi even at 2.4GHz are 50cm long.
I just looked up a 13dbi 900MHz antenna from element 14 and it is 79cm long. There is a bit of confusion here, this might only be 9dbi.
But you get the idea. “Small” is really a relative thing and depends largely on what each individual regards as small. With antennas it is all physics and plumbing and is a situation where “Size” really DOES matter.
Using these antennas certainly will make up for most losses BUT only if your major loss is “path attenuation”. They will only improve losses caused by obstructions, reflective paths etc if the antenna pattern directs the signal away from such obstructions. They will only improve degradation caused by hills and other line of site obstructions by a sheer apparent power increase which may improve your “fade margin”. In other words to achieve maximum improvement you need to have a “line of sight” path in the first place. Anything else will be the subject of experiment.
Incidentally if you stack 2 identical antennas properly with correct spacing, phasing and Z matching you will only get a gain increase of 3db.
Cheers Bob
[quote=“Donald23173, post:10, topic:21257”]
The bigger issue will be how it handles rainy days … both because of less sun; but also that water absorbs radio signals, so the wi-fi signal might reduce enough for it to become a problem.
[/quote].
Actually distilled water is a very good insulator. It is impurities added by accident or design that allow it to conduct.
Usually has to be VERY heavy rain. Most troublesome when the actual rain drops approach a resonant (about 1/2 wavelength) length. 2.4GHz will be less affected than 5GHz.
A practical example. Most large ships carry 2 radars. “10cm” (2 - 3GHz) and “3cm” (9 - 10GHz). The 10cm one will not “see” rain or sea clutter while the 3cm radar will happily “see” rain patches and sea clutter interference but will see targets and shore line with more detail.
Another example closer to home is UHF TV reception. A signal degradation might be observed if the area around the source (TV transmitter) is experiencing bad weather with VERY HEAVY rain. But the rain has to be very heavy indeed.
Cheers Bob
I don’t appear to need a directional antenna for this project, … however I am seeing more microcontrollers with LiPo battery, Solar panel and u.FL external antenna connectors - obviously suited to “remote” IoT projects - and thinking that a small cost effective antenna to focus the signal somewhat (even reducing to 180° would help) could be ideal for many upcoming IoT projects.
Just a thought. Maybe “small” and “directional” really isn’t feasible; but maybe someone with antenna design expertise might consider the possibility and think there is potential.
Hi Donald.
Did not come across that one when I searched. It would be interesting to know what is inside that device or even the physical size would be a clue. It is vertically polarised so I am assuming a couple of vertical elements maybe in which case the direction of radiation might be along the edge. Don’t know for sure without looking at one. A visit to Seeed web site did not yield anything.
I would look at the gain figure of 8dbi. dbi is comparing to an imaginary theoretical figure which is a device that cannot be built. It is a good marketing figure but I always think that dbd is more meaningful as the comparison is against an omnidirectional dipole and is a bit more than 2db less than dbi (I forget the exact number) thus the modified number would be something less that 6dbd or 6db WRT a dipole.
At this gain and beam width (40º) the front to back ratio would not be great but would be better than unity which is progress.
I did say that this is all physics and mechanical. The element lengths are a direct relationship to the wavelength for the frequency in question and this is something that does not change. Whether it be a vertical whip type or a horizontally mounted balanced type. So in reality anything better than a simple 1/4 wave vertical is going to get bigger overall. Believe me when this gets down to HF of a few MHz this can get quite large where you could need an acre or so to accommodate it.
Cheers Bob