Sep 2, 2014 09:20 AM
(This post was last modified: Aug 3, 2015 02:28 PM by Mad76e.)
[img]http://imageshack.us/a/img90/6030/bannermo.gif
[/img]
[/img]
Cantenna, the cheapest antenna for the wireless hacker
This is one of my projects i decided to translate and rewrite for you guys. The original is an Svedish text you will find here http://www.cantennabygge.n.nu/ . In this tut, I will go over some very basic theory, and how to build it. I cant go in normal mode here cos the math will bring most of you to your knees. for those who wishes to see an example here is a link to a PDF containing the math of hollow waveguides. Its monstrous.. However you will come a long way by not going in depth and rely on a couple of simple rules. The idea is to build the antenna, and then test it in a LOS (line of sight), and i will test it for you guys in different distances and reveal some performance.
First we have to decide what an Cantenna really is.. You can hear it by the name, "Cantenna" comes from the word "Can antenna" which is a good explanation of what we are doing. We are building a wifi antenna from a can!
In an ordinary antenna construction, it is important to get the right feed with the correct impedance! (usually 50 or 100ohm) but we will not have this problem with this model of antenna. Imagine a bottle and you blowing in it to get a tone. It is like a church organ. With the right distance away from the bottom and the right length of the dipole you will get your tone
There are many different types of waveguide antennas out there, the problem with most of them is that you need a welding-machine, and more equipment but the best part is that those are way stronger than the cantenna. Im talking about the "slotted waveguide antennas" Here are one site covering this Estimated performance is aprox 16-18dBi. We must also mention the Bi-Quad antenna aswell. I might cover the BI-quad antenna in a different tut in the future. You can use it with a satelite dish as you see on the site, but it work well just as it is. Effect without the sat disk 12-16dBi. All of these antennas are easy to build, and easy to understand, however i believe that the cantenna are the most easiest to build.
So i have used the cantenna for many years. I have used it in my wardriving days and you know, things happens and you buy stronger, better and more reliable antennas and things as this just take up unessesury place in my brain. so i decided to collect all i could about this and write you a decent tutorial
![[Image: EWo0HPH.gif]](https://i.imgur.com/EWo0HPH.gif)
It was not long before the track led me into a closet that should remain closed. I realized pretty quickly that this type of antennas are highly prized in the hacker circles, but that does not sit equally well by the FCC (Federal Communications Commission), and the Swedish equivalent PTS (Post and Tele Styrelsen) It is not illegal to own or use a Cantenna (in Sweden) but they don't like you to use em, and if you use it to take you into someone's network without permission from the owner, and you get caught you're going to get fines for using the antenna in addition to your other charges, if they can prove that your antenna interferes with other licensed frequencies
The purpose of this tut is to show how to build an antenna and how powerful they are, the purpose is not to discuss hacking or similar (Not today anyway). I had intended from the beginning just build an antenna, but it gets two. I want to check and compare a pringelscan against another more professional, that i built entirely of aluminum. The Pringelscan/tin can is most common in hacking spheres, and I want to compare how much difference there is between these to.
So one canntenna is built by a pringelscan, the other of a thicker aluminum tubing. Why I chose a pringelscan is to the inside of this is covered with a thin aluminum foil, cheap to buy and the bottom is made of aluminum. The thin aluminum foil in the cardboard tube is enough for it to be used as an antenna. The phenomenon is called the "skin effect" and is the current that the electromagnetic oscillation we call radio waves generates, which is gaining more superficial in a metal the higher the frequency is. It is therefore important that the surface leads good and is not corroded or full of dust etc. Depending on the material that leads, best had been the gold of course, after silver copper and aluminum but tin and plate works aswell.
![[Image: EWo0HPH.gif]](https://i.imgur.com/EWo0HPH.gif)
Is it worth the cost to build a professional Cantenna by yourself that I do in this case is doubtful, as there actually are a lot of wifi antennas with decent gain out there for $30-$40, but the greedy who is satisfied with a "pringelscan / a can of brown beans" will to realize that the price of manufacturing such does not exceeds $10. The reason I chose to manufacture two cantennas is partly to compare performance. There are a lot of fantasy figures who claims 5km, 10km and 15km or more. These figures seem taken out of the air and do not have anything to do with reality
My goal will be to see if I can connect from my laptop via my mobile that I made into a wireless access point (tethering). The cons are that I can use max 1MB to download and 0.5 Mbps for data transfer via my prepaid simcard, and the the phones Wifi antenna on the phone isn't that good aswell, perhaps 2dBi or something. So every millimeter I'm right in this build will increase the chances of success. Personally, I hope that this experiment will work. It sounds a bit like a fairy tale to get any speed from 1,000 meters with such a weak signal as 2dBi, but then I never tried so do not know the result either (EDIT: But i do know)
While you are careful with millimeters, you should know that an ordinary tin can will do fine for a cantennabuid. Just check the length of the can, it must exceeds 3/4 of a wavelength. However, you should know that there are both advantages and disadvantages of a long Cantenna, more on this later. So where going to go in depth on this, and to understand anything of this you have to be good in math and in physics. Its more to this than you can imagine, however i will try to not be boring about this, and if im doing this right, this is going to be an interesting read.
Well then. back to the building .
What we need is the following ..
- 1 tin (Pringelscan, aluminum tin or similar metal) or even weld a pipe ..
- N connector female chassis connector ..
- 4 M3x10mm long screws (or longer .. type M3X20MM depending on tube)
- 4 M3 nuts
- 1 x 35mm long 2mm thick copper cable
- tiny bit of solde
And we may need this tools
- a drilling machine
- 1 x 4mm and 1x 11mm drill
- a center punch
- hammer
- soldering iron
- ruler
- marker.
Before we put our teeth in manufacturing, it is a lot of math and theory, we have to go through. There is a lot of thinking and planning. Without these three key dimensions of the antenna will not work or perform well. We will go through it one by one.
- The inside diameter of the can
- The length of the dipole (or half dipole)
- And the length from the bottom to the dipole
So we start with the diameter of the can.
the inner diameter of the can is important, it is along this that the radio waves will "bounce". Too small diameter or large diameter reduces the effectiveness. The picture below shows theoretically how the radio waves will behave inside our Cantenna.
You can also see that the dipole (quartz dipole) mounted 1/4 wavelength from the bottom. The diameter of the tube/can affects this cos when you choosing a smaller tube, it require a longer distance to travel to get a 3/4 wavelength, and a longer distance from the center of the dipole to the bottom of the can. I will explain more in detail later. If the distance is right obtained a reinforcement of the signal (wave) will occur cos the wave that goes in or out are stored on top of each other and added each time it is reflected in the tube. so theoretical a very long tube will get you a stronger antenna.. but more about that later.
![[Image: CvsUmpZ.jpg]](https://i.imgur.com/CvsUmpZ.jpg)
The optimum diameter for the 2400 band (wifi) is 85mm, and my advice is to stick somewhere between 75-95mm Over 95 and under 75mm works of course, but the effect may be reduced. There is of course an upper and a lower limit where the diameter is either too big or too small. Upper limit is approximately 95mm and lower limit is approximately 75mm This is because each waveguide has an upper and a lower "cut-off frequency" where it starts to function much worse. This is called the "Cut-Off Freq. for TE11 Mode" and "Cut-Off Freq. for TM01 Mode"
However the the Wifi signal in free air is 12,5 cm so a cylinder greater than 125mm wont work any good at all..
This means that our dear pringelscan with diameter 73mm is not at all optimal, but works. I expect pretty weak performance of the pringelscan
The length of the dipole
This part that we leads and fix our copper thread in our N-connector. This copper wire which should be between 1.8 - 2.5 mm thick and shall be solded to the center pin. It it should not under any circumstances be any contact between the center pin and the rest of the contact. Make the dipole a bit too long (35mm), then we can easily correct this after it is solded . The copper thread will be our "Whistle"
[img]http://images.staticjw.com/can/9574/image011.jpg[/img]
[img]http://images.staticjw.com/can/2282/image013.jpg[/img]
What determines the length of our dipole is the wave propagation speed in the thread, called Velocity Factor. It depends on the dielectric constant of the medium surrounding the wire. A naked wire in air with nothing except air as insulation, so when we calculate this we must not assume the speed of light 300k in vacuum, we must count speed of light in air from 299.7k when you count the length of a conductor surrounded by air. The wavelength therefore 299.7 divided by frequency and then divided by four if you should have a quarter wave (299.7 = speed of light in air / 2,4gigahertz speed of WiFi / 4 for a quarter wave) = 31,2mm. This is the theoretical length. But then things like channel counts.. so we end up somewhere between 29-31 mm. 30mm is a good start.
Another way to figure out the same thing is this. The length of the dipole should be 299.7 / x frequency conduction velocity in the material (about 0.95 for copper) divided by 4 for a quarter wave. At 2450 MHz the dipole will be 29,65mm
The length from the bottom of the can to the center of the N-connector
The length is supposed to be a quarter of a full wavelength inside our can. Radio waves tend to do some strange things when they are in contact with the metal, first off they bounce, but they will also change the ratio of the wave depends on the diameter of the pipe, as you can see below, so in a way theoretical it moves faster than light, but im sure some professor can shed a light on that one moa he he he he, i know there must be an explanation, but that part i haven't figured out yet.
So if we change the dimension on our tube, our wave become longer or shorter depending on the dimension, so the smaller tubes used, ie, the wave becomes longer. As a wavelength of a pringelscan becomes 8,58cm x 4 = 34.2cm while the wavelength in a can with a 10cm in diameter is 4.44 x 4 = 17,66cm!!
Below you have the diameter of the tube and where you will find ¼ wavelength. D= Inner Diameter
Code
D=73mm 85,8mm (pringelscan)
D=80mm 70.1mm
D=81mm 67.5mm
D=82mm 64.5mm
D=82.5mm 63.3mm
D=83 mm 62.1mm
D=84mm 59.9mm
D=85mm 58.1mm
D=90mm 51.4mm
D=95mm 47.2mm
D=100mm 44.4mm![[Image: EWo0HPH.gif]](https://i.imgur.com/EWo0HPH.gif)
The length of the can!
The only important measurement here is that the can MUST be at least 3/4 wavelength. After that its just to experiment by adding 1/4 wavelength until you're happy. If the distance is right obtained a reinforcement of the signal (wave) will occur cos the wave that goes in or out are stored on top of each other and added each time it is reflected in the tube. While the effect is strengthened by its length, the worse the beamwidth will be. Imagine the difference between a 3degrees Beamwidth and 25degrees. The further away you pointing your antenna on, the worse its going to be. Example 200 yards away and moving the cantenna 1mm you will not notice anything with an cantenna that have a 25degrees beamwidth. but the one that has a smaller beamwidth you will lose connection. you need a tripod and windless day, and some pure luck to use.
It is true that the longer your antenna is the more profit you will get. however, It reduces the gain slightly after 6 or 7 wavelengths and it is not important to have a longer antenna than that. The disadvantage is that it becomes a total nightmare to target anything, its going to be like a damn laser beam, we have to go half way. Here are an bad example, a wavelength on a pipe with inner diameter of 84mm is about 24cm, which means that we would have an antenna that is 6 wavelengths, which is 144cm! You understand that it would be completely impossible to use it against anything,
So use a length that feels comfortable to work with. Minimum recommended length of a fully functional Cantenna corresponds to a wavelength of 3/4 but I think that its somewhat weak. A wavelength should be used. But please do not be longer than 50cm how tempting it may be. For each dm it gets longer, it becomes increasingly difficult to target. If you are compelled to want a really long antenna so I suggest that you mount any kind of laser pointer on the pipe, and arms you with a pair of binoculars if you plan to use it at long range.
Most canned foods that you buy today may be a little short (for 3/4 wavelength), and to solve this "little" problem, we buy just two cans that we either plumbs together with a little tin or welds, depending on matreal in the can. The poor man's solution "tape" together two cans work, but should not be used. If you still want to use this method, ensure that the two cans in contact with each other, it can easily happen that they end up losing touch with each other, and you will lose performance
If you choose I Aluminum tubes so there are a number of companies that sell aluminum tubing Email them as they sell both pipes per meter and after the customer's wishes
Please note that it is the interior dimensions of the tube that is of interest to us (Aluminum tube 90mm. Thickness 3 mm = 90-3-3 = 84mm)
3/4 of a wavelength of a minimum length required for the antenna to operate. D= Inner Diameter
Code
D=73mm are 3/4 wavelength 257,5 mm (pringelscan)
D=80mm are 3/4 wavelength 210,3 mm
D=81mm are 3/4 wavelength 202,5 mm
D=82mm are 3/4 wavelength 193,5 mm
D=82,5mm are 3/4 wavelength 189,9 mm
D=83mm are 3/4 wavelength 186,3 mm
D=84mm are 3/4 wavelength 179,7 mm
D=85mm are 3/4 wavelength 174,3 mm
D=90mm are 3/4 wavelength 154,2 mm
D=95mm are 3/4 wavelength 141,6 mm
D=100mm are 3/4 wavelength 133,2 mmLadies and gentlemen ... Let me introduce David and Goliath .. I ordered 420mm but accidentally got 500mm! I'm not complaining .. :) Since I do not have a precision saw, I get to make it a bit longer than I originally thought :)
[img]http://images.staticjw.com/can/7968/image015.jpg[/img]
Theoretically im hoping to get a directional antenna that has between 10-12dBi, it all depends how thoroughly I'm with the tenths on my millimeters. The pringelscan (extended version) has slightly lower performance, perhaps 5-9 dB partly because the diameter is not optimal, partly because it goes into more wavelengths in the aluminum cantenna. The more wavelengths you get in, the stronger it becomes.



![[Image: nsvidqU.jpg]](https://i.imgur.com/nsvidqU.jpg)