{"id":119,"date":"2013-04-08T17:02:37","date_gmt":"2013-04-08T17:02:37","guid":{"rendered":"http:\/\/alpsayin.com\/new\/?page_id=119"},"modified":"2021-03-22T21:22:09","modified_gmt":"2021-03-22T21:22:09","slug":"setting-up-radiotunnel-for-radio-networking","status":"publish","type":"page","link":"https:\/\/alpsayin.com\/blog\/manuals\/setting-up-radiotunnel-for-radio-networking\/","title":{"rendered":"Setting up Radiotunnel for Radio Networking"},"content":{"rendered":"<p>Do you want to be able to develop your own socket applications without dealing with my mess of code? Speed is not an issue for you and you just want to develop or port your applications for radio? No problem! You can use radiotunnel software to use kernel&#8217;s IP stack to use Radiometrix UHX1, Radiometrix Bim2A or other similar devices. Here is how!<\/p>\n<h1>What you need for both sides:<\/h1>\n<ul>\n<li>Any linux machine with a USB port and a Linux based operating system with\u00a0<a title=\"FTDI Chip Drivers\" href=\"http:\/\/www.ftdichip.com\/Drivers\/VCP.htm\" target=\"_blank\" rel=\"noopener\">FTDI USB-Uart driver<\/a>.\u00a0During the development we have used Alix 2d13 from\u00a0<a title=\"Alix\" href=\"http:\/\/pcengines.ch\/alix.htm\" target=\"_blank\" rel=\"noopener\">PcEngines<\/a>. And during development we have installed Voyage-Linux on them. But radiotunnel is also tested on\u00a0<a title=\"Bifrost OS\" href=\"http:\/\/en.wikipedia.org\/wiki\/Bifrost_(operating_system)\" target=\"_blank\" rel=\"noopener\">Bifrost OS<\/a>.<\/li>\n<li><a title=\"Radiometrix Bim2a\" href=\"http:\/\/www.radiometrix.com\/content\/bim2a\" target=\"_blank\" rel=\"noopener\">Radiometrix Bim2A<\/a>, <a title=\"Radiometrix Uhx1\" href=\"http:\/\/www.radiometrix.com\/content\/uhx1\" target=\"_blank\" rel=\"noopener\">Radiometrix UHX1<\/a>\u00a0or similar devices, one for the server one for the client.<\/li>\n<li>Interface card for Bim2A or UHX1. These cards are not sold anywhere but you can build one very easily on your own. The schematics of such cards are below. Since you are only planning to use the card for radiotunnel you don&#8217;t need the audio components (i.e. any component\/wire that is connected to the audio block). You can download a proteus pcb design for Bim2A from\u00a0<a title=\"Bim2A Uart PCB\" href=\"https:\/\/github.com\/alpsayin\/bim2a_uart_pcb\" target=\"_blank\" rel=\"noopener\">my github repository<\/a>\u00a0and you can download proteus pcb design and\/or geda pcb design for Uhx1 from <a title=\"Uhx1 Uart Pcb\" href=\"https:\/\/github.com\/alpsayin\/uhx1_uart_pcb\" target=\"_blank\" rel=\"noopener\">this github repository<\/a>.<\/li>\n<li>A USB TTL UART cable that allows CTS\/RTS signalling with 3.3 V or 5 V signal level. We prefer using\u00a0<a title=\"FTDI TTL USB UART Cable\" href=\"http:\/\/www.ftdichip.com\/Support\/Documents\/DataSheets\/Cables\/DS_TTL-232R_CABLES.pdf\" target=\"_blank\" rel=\"noopener\">FTDI cables<\/a>\u00a0for the purpose.<\/li>\n<li>A matched antenna for 70cm band (433 MHz band). A simple and good antenna is a 70 cm long wire antenna, but you can use a 17.5 cm wire antenna if you want to keep it short. Or a matched antenna for 2m band (144 MHz band). A simple and good antenna is a 2 meter long wire antenna, but you can use a 50 cm wire antenna if you want to keep it short. We have used <a title=\"Yaesu CR8900\" href=\"http:\/\/www.yaesu.com\/indexVS.cfm?cmd=DisplayProducts&amp;ProdCatID=106&amp;encProdID=0C4855ADE6394D514EAABAE148B93F5C&amp;DivisionID=65&amp;isArchived=0\" target=\"_blank\" rel=\"noopener\">CR8900 from Yaesu<\/a>.<\/li>\n<li>And finally you have to clone the\u00a0<a title=\"Radiotunnel Github\" href=\"https:\/\/github.com\/alpsayin\/radiotunnel\" target=\"_blank\" rel=\"noopener\">radiotunnel software from github.<\/a><\/li>\n<\/ul>\n<pre lang=\"bash\" escaped=\"true\">git clone\u00a0https:\/\/github.com\/alpsayin\/radiotunnel.git<\/pre>\n<figure id=\"attachment_7\" aria-describedby=\"caption-attachment-7\" style=\"width: 300px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/alpenian.alpsayin.com\/blog\/wp-content\/uploads\/2013\/04\/bim2a_schematic.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-medium wp-image-7\" src=\"https:\/\/alpenian.alpsayin.com\/blog\/wp-content\/uploads\/2013\/04\/bim2a_schematic-300x211.png\" alt=\"Bim2a UART Interface Card Schematic\" width=\"300\" height=\"211\" \/><\/a><figcaption id=\"caption-attachment-7\" class=\"wp-caption-text\">Bim2a UART Interface Card Schematic<\/figcaption><\/figure>\n<figure id=\"attachment_26\" aria-describedby=\"caption-attachment-26\" style=\"width: 300px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/alpenian.alpsayin.com\/blog\/wp-content\/uploads\/2013\/04\/Uhx1_schematic.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-medium wp-image-26\" src=\"https:\/\/alpenian.alpsayin.com\/blog\/wp-content\/uploads\/2013\/04\/Uhx1_schematic-300x211.png\" alt=\"Uhx1 Uart\/Soundmodem Interface Card\" width=\"300\" height=\"211\" \/><\/a><figcaption id=\"caption-attachment-26\" class=\"wp-caption-text\">Uhx1 Uart\/Soundmodem Interface Card<\/figcaption><\/figure>\n<h1>Setup:<\/h1>\n<ul>\n<li>Connect your interface card to your computer via the USB Uart cable and keep in mind where it is mounted. Mostly it gets a name like \/dev\/ttyUSB0. You can find the name of the USB Uart device by checking dmesg.<\/li>\n<\/ul>\n<pre lang=\"bash\" escaped=\"true\">sudo dmesg | grep \/dev\/ttyUSB<\/pre>\n<ul>\n<li>The command above should display the relevant system message about the cable plugged. For in case we will first set the right permissions for the device.<\/li>\n<\/ul>\n<pre lang=\"bash\" escaped=\"true\">sudo chmod 666 \/dev\/ttyUSB0<\/pre>\n<ul>\n<li><span style=\"line-height: 15px;\">Assuming that you have cloned the radiotunnel software to your home directory, go into the directory and for good practice clean first and then make. And finally make install.<\/span><\/li>\n<\/ul>\n<pre lang=\"bash\" escaped=\"true\">cd ~\/radiotunnel\r\nmake clean &amp;&amp; make\r\nsudo make install<\/pre>\n<ul>\n<li>Now you can invoke radiotunnel from anywhere you like. If you haven&#8217;t modified the source code, it will dump some logs wherever you invoke it. So I prefer creating a folder in my home directory and invoking it there.<\/li>\n<\/ul>\n<pre lang=\"bash\" escaped=\"true\">mkdir -p ~\/radiotunnel_logs\u00a0\r\ncd ~\/radiotunnel_logs<\/pre>\n<ul>\n<li>Type in radiotunnel to get the help message.<\/li>\n<\/ul>\n<pre lang=\"bash\" escaped=\"true\">radiotunnel radiomode[uhf|vhf] interface_name ip\/subnet your_callsign serial_device [ax25_destination]\r\nExample: radiotunnel uhf radio0 10.0.0.1\/24 TA2IAS4 \/dev\/ttyUSB0<\/pre>\n<ul>\n<li>The usage is fairly simple. But there are some key points. You MUST define a non-existent interface_name. You must define unique IP addresses within the same subnet for both (or all) of your stations. You SHOULD define different callsigns for your stations. And you SHOULD define ax25_destination parameter for both stations (station A should have callsign A and destination B, and station B should have callsign B and destination A).<\/li>\n<li>Note that this software&#8217;s parameter reading part is not very advanced, so if you make any mistakes it won&#8217;t work.<\/li>\n<li>After you run the software it will print out every packet in ASCII and HEX and it will also log this output among with other things. If you don&#8217;t want these outputs, I suggest you delete a few lines from the source code. Removing lines <a title=\"L84 in tunclient.c\" href=\"https:\/\/github.com\/alpsayin\/radiotunnel\/blob\/master\/tunclient.c#L84\" target=\"_blank\" rel=\"noopener\">84<\/a>\u00a0and <a title=\"L93 in tunclient.c\" href=\"https:\/\/github.com\/alpsayin\/radiotunnel\/blob\/master\/tunclient.c#L93\" target=\"_blank\" rel=\"noopener\">93<\/a> in tunclient.c will disable the logging into a file. And removing lines <a title=\"Line 272 in tunclient.c\" href=\"https:\/\/github.com\/alpsayin\/radiotunnel\/blob\/master\/tunclient.c#L272\" target=\"_blank\" rel=\"noopener\">272<\/a>\u00a0and\u00a0<a title=\"Line 332 in tunclient.c\" href=\"https:\/\/github.com\/alpsayin\/radiotunnel\/blob\/master\/tunclient.c#L332\" target=\"_blank\" rel=\"noopener\">332<\/a> will disable the HEX\/ASCII outputting of every transceived data.<\/li>\n<\/ul>\n<pre lang=\"text\" escaped=\"true\">Read 84 bytes from device radio0\r\n0001 0203 0405 0607 0809 0a0b 0c0d 0e0f 0123456789abcdef\r\n____ ____ ____ ____ ____ ____ ____ ____ ________________\r\n4500 0054 0000 4000 4001 26a4 0a00 0001 E..T..@.@.&amp;.....\r\n0a00 0005 0800 6bc6 0e29 0003 765a 6351 ......k..)..vZcQ\r\n0000 0000 de8e 0700 0000 0000 1011 1213 ................\r\n1415 1617 1819 1a1b 1c1d 1e1f 2021 2223 ............ !\"#\r\n2425 2627 2829 2a2b 2c2d 2e2f 3031 3233 $%&amp;'()*+,-.\/0123\r\n3435 3637 4567<\/pre>\n<ul>\n<li>That&#8217;s it! You now know everything there is to know about radiotunnel. Run it on both sides to see how it does. I can tell you that it is going to be super-slow and unreliable due to the slowness (lots and lots of TCP timeouts&#8230;).<\/li>\n<\/ul>\n<h2>Finally; remember that there isn&#8217;t much documentation about this on the internet. So if you have a question, ask it below and I&#8217;ll try to answer. In such way we can build up a knowledge base.<\/h2>\n","protected":false},"excerpt":{"rendered":"<p>Do you want to be able to develop your own socket applications without dealing with my mess of code? Speed is not an issue for you and you just want to develop or port your applications for radio? No problem! You can use radiotunnel software to use kernel&#8217;s IP stack to use Radiometrix UHX1, Radiometrix [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":40,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-119","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/alpsayin.com\/blog\/wp-json\/wp\/v2\/pages\/119","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/alpsayin.com\/blog\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/alpsayin.com\/blog\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/alpsayin.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/alpsayin.com\/blog\/wp-json\/wp\/v2\/comments?post=119"}],"version-history":[{"count":3,"href":"https:\/\/alpsayin.com\/blog\/wp-json\/wp\/v2\/pages\/119\/revisions"}],"predecessor-version":[{"id":329,"href":"https:\/\/alpsayin.com\/blog\/wp-json\/wp\/v2\/pages\/119\/revisions\/329"}],"up":[{"embeddable":true,"href":"https:\/\/alpsayin.com\/blog\/wp-json\/wp\/v2\/pages\/40"}],"wp:attachment":[{"href":"https:\/\/alpsayin.com\/blog\/wp-json\/wp\/v2\/media?parent=119"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}