| 1 | % ------------------------------------------------------------------ |
|---|
| 2 | % |
|---|
| 3 | % TITLE: OSSIE 0.8.3 Installation Guide |
|---|
| 4 | % AUTHORS: Mike Ekoniak, Matt Carrick, Drew Cormier, Christopher Covington, |
|---|
| 5 | % Carl B. Dietrich, Joseph Gaeddert, Benjamin Hilburn, |
|---|
| 6 | % C. Ian Phelps, Shereef Sayed, Jason Snyder, Haris Volos |
|---|
| 7 | % CREATED: |
|---|
| 8 | % REVISED: |
|---|
| 9 | % 23Mar11 IB Minor typo fixes. |
|---|
| 10 | % URL: http://ossie.wireless.vt.edu/ |
|---|
| 11 | % |
|---|
| 12 | % ------------------------------------------------------------------ |
|---|
| 13 | |
|---|
| 14 | \newpage |
|---|
| 15 | \section{Installation} |
|---|
| 16 | \label{section:installation} |
|---|
| 17 | For users that do not have access to a Linux system, or are unfamiliar with Linux, we recommend |
|---|
| 18 | that you use our pre-built VMWare images. These images have OSSIE pre-installed on them, and are |
|---|
| 19 | ready to use out-of-the-box. Using an OSSIE VMware image is described in |
|---|
| 20 | Section~\ref{section:installation:vmware}. |
|---|
| 21 | |
|---|
| 22 | Although we do not yet provide and support binary installation packages for more Linux |
|---|
| 23 | distributions, compiling OSSIE from source on them should be possible. |
|---|
| 24 | |
|---|
| 25 | To install OSSIE from source, follow the below instructions to install the OSSIE dependencies, |
|---|
| 26 | and then compile and install the source code. |
|---|
| 27 | |
|---|
| 28 | \subsection{Installing OSSIE from Source} |
|---|
| 29 | \label{section:installation:source} |
|---|
| 30 | |
|---|
| 31 | This section assumes that the user is familiar with basic |
|---|
| 32 | Linux commands such as {\tt cd} and {\tt ls} and has sudo |
|---|
| 33 | access or root access. |
|---|
| 34 | |
|---|
| 35 | If you have an older version of OSSIE installed, then you will need to delete the contents of {\tt /sdr/}. |
|---|
| 36 | \begin{lstlisting}[] |
|---|
| 37 | $ rm -rf /sdr/* |
|---|
| 38 | \end{lstlisting} |
|---|
| 39 | |
|---|
| 40 | Ubuntu is the main supported operating system for OSSIE and the dependencies |
|---|
| 41 | for Ubuntu 11.10 are listed below. After following the instructions, jump to |
|---|
| 42 | Section~\ref{section:installation:source:dependencies:configomni} to continue the install. |
|---|
| 43 | |
|---|
| 44 | \subsubsection{Installing Dependencies on Ubuntu 11.10} |
|---|
| 45 | \begin{lstlisting}[] |
|---|
| 46 | $ sudo apt-get -y install libtool automake g++ omniorb libomniorb4-dev omniidl \ |
|---|
| 47 | libboost-all-dev libgnuradio-usrp-dev libgnuradio-usrp2-dev libpulse-dev \ |
|---|
| 48 | libsndfile-dev python-omniorb omniidl-python |
|---|
| 49 | \end{lstlisting} |
|---|
| 50 | |
|---|
| 51 | \subsubsection{Configure omniORB} |
|---|
| 52 | \label{section:installation:source:dependencies:configomni} |
|---|
| 53 | All of the dependencies have been installed and one of the dependencies, |
|---|
| 54 | omniORB, needs to be configured. This configuration is done through the |
|---|
| 55 | modification of a file, either {\tt /etc/omniORB.cfg} or |
|---|
| 56 | {\tt /etc/omniORB4.cfg}, depending on the version of the omniORB dependency. |
|---|
| 57 | |
|---|
| 58 | Open the file as root, and search for the following line: |
|---|
| 59 | \begin{lstlisting}[] |
|---|
| 60 | InitRef = NameService=corbaname::my.host.name |
|---|
| 61 | \end{lstlisting} |
|---|
| 62 | Uncomment the line by deleting the pound or hash character `\#' and change |
|---|
| 63 | it to: |
|---|
| 64 | \begin{lstlisting}[] |
|---|
| 65 | InitRef = NameService=corbaname::127.0.0.1 |
|---|
| 66 | \end{lstlisting} |
|---|
| 67 | Before running the framework you will need to start the naming service. If you |
|---|
| 68 | installed omniORB from source, you have to follow the instructions in |
|---|
| 69 | Appendix~\ref{appendix:omninamessh}. When installing from yum |
|---|
| 70 | {\tt omniNames} will automatically start when you restart your machine. Refer |
|---|
| 71 | to Appendix~\ref{appendix:services} for instructions on how to start the |
|---|
| 72 | omniNames service without restarting your machine or set whether the service |
|---|
| 73 | starts automatically at boot. |
|---|
| 74 | \footnote{You may also manually start a source-compiled tarball package of |
|---|
| 75 | omniNames {\tt omniNames} with the script described in |
|---|
| 76 | Appendix~\ref{appendix:omninamessh}} |
|---|
| 77 | |
|---|
| 78 | \label{section:installation:source:dependencies:gnuradio} |
|---|
| 79 | OSSIE uses a small subset of GNU Radio to communicate with and configure the USRP. The |
|---|
| 80 | following steps will walk through configuring portions the USRP and USRP2 drivers: |
|---|
| 81 | |
|---|
| 82 | To setup the proper permissions for the USRP, as root, create a group which will have access |
|---|
| 83 | to the USRP: |
|---|
| 84 | |
|---|
| 85 | \begin{lstlisting}[] |
|---|
| 86 | $ sudo /usr/sbin/groupadd usrp |
|---|
| 87 | \end{lstlisting} |
|---|
| 88 | |
|---|
| 89 | Add users to the group which need access to the USRP: |
|---|
| 90 | |
|---|
| 91 | \begin{lstlisting}[] |
|---|
| 92 | $ sudo /usr/sbin/usermod -G usrp -a USERNAME |
|---|
| 93 | \end{lstlisting} |
|---|
| 94 | |
|---|
| 95 | Now that users will have access to the USRP, read and write access to the device |
|---|
| 96 | must be created. As root, create the file {\tt /etc/udev/rules.d/10-usrp.rules} in |
|---|
| 97 | a text editor: |
|---|
| 98 | |
|---|
| 99 | \begin{lstlisting}[] |
|---|
| 100 | $ sudo gedit /etc/udev/rules.d/10-usrp.rules |
|---|
| 101 | \end{lstlisting} |
|---|
| 102 | |
|---|
| 103 | Add the following text to the file: |
|---|
| 104 | |
|---|
| 105 | \begin{lstlisting}[] |
|---|
| 106 | ACTION=="add", BUS=="usb", SYSFS{idVendor}=="fffe", \ |
|---|
| 107 | SYSFS{idProduct}=="0002", GROUP:="usrp", MODE:="0660" |
|---|
| 108 | \end{lstlisting} |
|---|
| 109 | |
|---|
| 110 | The text above is displayed on two lines due to the contraints on page size, however |
|---|
| 111 | the text must appear on a single line, without the backslash, in the file for the |
|---|
| 112 | access to the USRP to work properly. You may also add the following comment lines to |
|---|
| 113 | the file for future reference: |
|---|
| 114 | |
|---|
| 115 | \begin{lstlisting}[] |
|---|
| 116 | # rule to grant read/write access on USRP to group named usrp. |
|---|
| 117 | # to use, install this file in /etc/udev/rules.d/ as |
|---|
| 118 | # 10-usrp.rules |
|---|
| 119 | \end{lstlisting} |
|---|
| 120 | |
|---|
| 121 | The USRP interface has now been created. As an optional test, connect the USRP |
|---|
| 122 | to the computer and run the following command: |
|---|
| 123 | |
|---|
| 124 | \begin{lstlisting}[] |
|---|
| 125 | $ ls -lR /dev/bus/usb |
|---|
| 126 | \end{lstlisting} |
|---|
| 127 | |
|---|
| 128 | The users root and usrp should now be listed under the user groups. |
|---|
| 129 | |
|---|
| 130 | If you are using the USRP2, it is necessary to have a gigabit ethernet interface and |
|---|
| 131 | intruct the kernel to allow raw socket access to the ethernet port: |
|---|
| 132 | \begin{lstlisting}[] |
|---|
| 133 | $ sudo chmod u+s /usr/local/bin/usrp2_socket_opener |
|---|
| 134 | \end{lstlisting} |
|---|
| 135 | |
|---|
| 136 | This step is necessary every time you reinstall GNU Radio. |
|---|
| 137 | |
|---|
| 138 | \subsubsection{Install OSSIE} |
|---|
| 139 | \label{section:installation:source:ossiecf} |
|---|
| 140 | You are now ready to build and install OSSIE. |
|---|
| 141 | Note that installing by hand requires some knowledge of OSSIE, Linux, and software development. |
|---|
| 142 | |
|---|
| 143 | Download the latest tarball from |
|---|
| 144 | \href{http://ossie.wireless.vt.edu/download/tarballs/\ossieversion/}{http://ossie.wireless.vt.edu/download/tarballs/\ossieversion/} |
|---|
| 145 | \\ and unpack {\tt ossie-\ossieversion.tar.gz}. |
|---|
| 146 | \begin{lstlisting}[] |
|---|
| 147 | $ wget http://ossie.wireless.vt.edu/download/tarballs/0.8.3/ \ |
|---|
| 148 | ossie-0.8.3.tar.gz |
|---|
| 149 | $ tar -xvf ossie-0.8.3.tar.gz |
|---|
| 150 | \end{lstlisting} |
|---|
| 151 | |
|---|
| 152 | By default, the installation directory of the OSSIE platform is {\tt /sdr}. In order to install new |
|---|
| 153 | source code and binaries into this directory without root permissions, you need to create and change |
|---|
| 154 | the ownership of {\tt /sdr}. |
|---|
| 155 | \begin{lstlisting}[] |
|---|
| 156 | $ sudo mkdir /sdr |
|---|
| 157 | $ sudo chown -R username.username /sdr |
|---|
| 158 | \end{lstlisting} |
|---|
| 159 | where {\tt username} is your user name. |
|---|
| 160 | |
|---|
| 161 | \subsubsection{Using Autoconf} |
|---|
| 162 | \label{section:installation:source:ossiecf:autoconf} |
|---|
| 163 | |
|---|
| 164 | \begin{lstlisting}[] |
|---|
| 165 | $ cd ossie-0.8.3 |
|---|
| 166 | $ ./configure --prefix=/sdr --libdir=/usr/local/lib/ \ |
|---|
| 167 | --includedir=/usr/local/include/ --with-boost --with-boost-filesystem |
|---|
| 168 | $ make |
|---|
| 169 | $ sudo make install |
|---|
| 170 | \end{lstlisting} |
|---|
| 171 | |
|---|
| 172 | If successful, the prompt should say: |
|---|
| 173 | \begin{lstlisting}[] |
|---|
| 174 | ********************************************************* |
|---|
| 175 | |
|---|
| 176 | Complete installation of OSSIE 0.8.3 finished! |
|---|
| 177 | |
|---|
| 178 | ********************************************************* |
|---|
| 179 | \end{lstlisting} |
|---|
| 180 | |
|---|
| 181 | If you prefer, or require, a different root directory, then change the |
|---|
| 182 | '--prefix' flag to your appropriate absolute path. If you require the OSSIE |
|---|
| 183 | libraries to be installed to a different location, then change the '--libdir' |
|---|
| 184 | flag to your appropriate absolute path. For further 'configure' options, |
|---|
| 185 | use {\tt configure --help}. |
|---|
| 186 | |
|---|
| 187 | If configure fails, use {\tt aptitude search <dependency name>} to find any missing packages. |
|---|
| 188 | |
|---|
| 189 | \subsubsection{Updating System Libraries} |
|---|
| 190 | \label{section:installation:source:ossiecf:ldconfig} |
|---|
| 191 | Once the OSSIE libraries are installed, they need to be linked. |
|---|
| 192 | As root edit the file {\tt /etc/ld.so.conf}, adding the line |
|---|
| 193 | \begin{lstlisting}[] |
|---|
| 194 | /usr/local/lib |
|---|
| 195 | \end{lstlisting} |
|---|
| 196 | Now run: |
|---|
| 197 | \begin{lstlisting}[] |
|---|
| 198 | $ sudo /sbin/ldconfig |
|---|
| 199 | \end{lstlisting} |
|---|
| 200 | |
|---|
| 201 | OSSIE should now be successfully installed on your system. You can skip to |
|---|
| 202 | Section~\ref{section:runningwaveforms} to learn how to run waveforms. |
|---|
| 203 | |
|---|
| 204 | \subsection{Installation of OSSIE Eclipse Feature} |
|---|
| 205 | \label{section:installation:alloefinstall} |
|---|
| 206 | Installation of the OSSIE Eclipse Feature (OEF) requires the installation of OSSIE, Java, and Eclipse. |
|---|
| 207 | |
|---|
| 208 | \subsubsection{Installing Java} |
|---|
| 209 | \label{section:installation:javainstall} |
|---|
| 210 | Eclipse is written in Java, so you must have it installed to run Eclipse and OEF. |
|---|
| 211 | We recommend using Sun's Java Development Kit. As of this writing, the GNU Compiler |
|---|
| 212 | for Java (GCJ) will not work. |
|---|
| 213 | |
|---|
| 214 | \subsubsection{Installing Java on Ubuntu} |
|---|
| 215 | \label{section:installation:javaubuntu} |
|---|
| 216 | |
|---|
| 217 | Open /etc/apt/sources.list in an editor and add the following lines to the end of the file: |
|---|
| 218 | \begin{lstlisting}[] |
|---|
| 219 | deb http://archive.canonical.com/ubuntu lucid partner |
|---|
| 220 | deb-src http://archive.canonical.com/ubuntu lucid partner |
|---|
| 221 | \end{lstlisting} |
|---|
| 222 | |
|---|
| 223 | In a terminal, enter the following lines: |
|---|
| 224 | \begin{lstlisting}[] |
|---|
| 225 | $ sudo apt-get update |
|---|
| 226 | $ sudo apt-get install sun-java6-jdk |
|---|
| 227 | \end{lstlisting} |
|---|
| 228 | |
|---|
| 229 | \subsubsection{Installing Eclipse} |
|---|
| 230 | \label{section:installation:eclipseinstall} |
|---|
| 231 | Install the Eclipse IDE for Java Developers. Go to |
|---|
| 232 | the \href{http://www.eclipse.org/downloads/}{Eclipse Download Center} |
|---|
| 233 | and download an Eclipse distribution for your platform. |
|---|
| 234 | |
|---|
| 235 | Eclipse is distributed as a tarball archive that you can unpack to location |
|---|
| 236 | of your choice. Pick a location that is appropriate for your platform and |
|---|
| 237 | simply unpack the contents. There is no self-installer, just unpack the distribution. |
|---|
| 238 | Do not install Eclipse in a directory that has spaces anywhere in its full path name. |
|---|
| 239 | |
|---|
| 240 | \subsubsection{Installing OEF} |
|---|
| 241 | \label{section:installation:oefinstall} |
|---|
| 242 | Now that the dependencies have been installed, OEF can be installed. |
|---|
| 243 | |
|---|
| 244 | Move into the unpacked eclipse directory, and start eclipse: |
|---|
| 245 | \begin{lstlisting}[] |
|---|
| 246 | $ cd /path/to/eclipse |
|---|
| 247 | $ ./eclipse |
|---|
| 248 | \end{lstlisting} |
|---|
| 249 | |
|---|
| 250 | After Eclipse starts, on the toolbar select {\tt Help}, {\tt Install New Software}. |
|---|
| 251 | In the new window, select the ``Work with'' textbox and enter the URL: {\tt http://ossie.wireless.vt.edu/eclipse/} |
|---|
| 252 | and select Add. Give a name, e.g., ``OEF''. |
|---|
| 253 | |
|---|
| 254 | The window will then add the URL, OSSIE, OSSIE Waveform Developer |
|---|
| 255 | Feature to the list of available software. Place a check in the box next to OSSIE |
|---|
| 256 | Waveform Developer Feature and click Next. Eclipse will show a window with more details, select Finish to complete the installation process. |
|---|
| 257 | |
|---|
| 258 | %Eclipse will bring up a window which will |
|---|
| 259 | %resolve any dependencies and then start the install guide. |
|---|
| 260 | |
|---|
| 261 | %When the install window opens, make sure OSSIE Waveform Developer Feature is selected and click Next. |
|---|
| 262 | |
|---|
| 263 | %Accept the GNU license agreement and select Next. Eclipse will then begin to download the necessary files, which may take a few minutes. |
|---|
| 264 | Allow Eclipse to restart when it prompts to do so. After it restarts, the OSSIE Eclipse Feature will be installed. |
|---|
| 265 | |
|---|
| 266 | Select the OSSIE perspective within Eclipse. On the toolbar, select {\tt Window}, |
|---|
| 267 | {\tt Open Perspective}, {\tt Other}. In the new window, select OSSIE which will then |
|---|
| 268 | open the OSSIE perspective. On the toolbar, select {\tt File}, {\tt New}, {\tt OSSIE Waveform}, |
|---|
| 269 | or {\tt OSSIE Component} to start developing. |
|---|
| 270 | |
|---|
| 271 | These same instructions used for installing OEF can be used later to update it to newer versions. |
|---|
| 272 | |
|---|
| 273 | \subsection{Using a VMware Image on Any Platform} |
|---|
| 274 | \label{section:installation:vmware} |
|---|
| 275 | A VMware image of OSSIE \ossieversion\ pre-installed on a Linux operating system is available at \\ |
|---|
| 276 | \href{http://ossie.wireless.vt.edu/trac/wiki/Downloads}{http://ossie.wireless.vt.edu/trac/wiki/Downloads}. |
|---|
| 277 | All that is needed to run the virtual image is the VMÂWare Player, available |
|---|
| 278 | for free from \href{http://www.vmware.com/download/player/}{http://www.vmware.com/download/player/}. |
|---|
| 279 | Versions of the player are available for both Windows and Linux. |
|---|
| 280 | |
|---|
| 281 | Install VMware Player on your system, unzip the virtual image and open it. |
|---|
| 282 | For full instructions on installing and using VMware player, please |
|---|
| 283 | consult the VMWare Player User Guide~\cite{vmware:web}. |
|---|
| 284 | |
|---|
| 285 | It is recommended that you keep a copy of the zipped virtual image so that you do |
|---|
| 286 | not need to download the image a second time to start with a fresh copy. Changes |
|---|
| 287 | that you make from within the image will alter it, and in the event of drastic |
|---|
| 288 | unwanted changes, starting afresh is easy if you have an extra copy of the image |
|---|
| 289 | on your hard drive. |
|---|
| 290 | |
|---|
| 291 | % \subsection{Via Ebuild on Gentoo Linux} |
|---|
| 292 | % Support for installation via Gentoo's Portage package management system has not |
|---|
| 293 | % yet been thoroughly tested but ebuilds do exist. |
|---|
| 294 | % |
|---|
| 295 | % To access the ebuilds, install and configure layman if you haven't already: |
|---|
| 296 | % \begin{figure} |
|---|
| 297 | % \begin{lstlisting}[] |
|---|
| 298 | % # emerge layman |
|---|
| 299 | % # echo "source /usr/portage/local/layman/make.conf" >> /etc/make.conf |
|---|
| 300 | % \end{lstlisting} |
|---|
| 301 | % \end{figure} |
|---|
| 302 | % |
|---|
| 303 | % Then, add ossie-overlay to your locally-stored overlays: |
|---|
| 304 | % \begin{figure} |
|---|
| 305 | % \begin{lstlisting}[] |
|---|
| 306 | % # layman -a -o https://ossie.wireless.vt.edu/repos/ossie/experimental/scripts/gentoo/ossie-overlay.xml |
|---|
| 307 | % \end{lstlisting} |
|---|
| 308 | % \end{figure} |
|---|
| 309 | % |
|---|
| 310 | % You can then proceed with installing OSSIE: |
|---|
| 311 | % \begin{figure} |
|---|
| 312 | % \begin{lstlisting}[] |
|---|
| 313 | % # emerge -av ossie |
|---|
| 314 | % \end{lstlisting} |
|---|
| 315 | % \end{figure} |
|---|
| 316 | % |
|---|
| 317 | % After sucessful compiliation of the OSSIE framework and its dependencies, skip |
|---|
| 318 | % to section X. |
|---|
| 319 | |
|---|
| 320 | %\subsection{Embedded Platforms} |
|---|
| 321 | %While installation on embedded platforms is not officially supported in the |
|---|
| 322 | %0.6.2 release, work has been done (MENTION WORK) on porting OSSIE to embedded |
|---|
| 323 | %platforms and we are interested in promoting more work in this area. |
|---|
| 324 | |
|---|
| 325 | |
|---|