pcap_layer.h
Go to the documentation of this file.
00001 /*------------------------------------------------------------------------
00002  *---------------------           WMPSNIFFER          --------------------
00003  *------------------------------------------------------------------------
00004  *                                                         V7.0B  11/05/10
00005  *
00006  *
00007  *  File: pcap_layer.h
00008  *  Authors: Danilo Tardioli
00009  *  ----------------------------------------------------------------------
00010  *  Copyright (C) 2000-2012, Universidad de Zaragoza, SPAIN
00011  *
00012  *  Contact Addresses: Danilo Tardioli                   dantard@unizar.es
00013  *
00014  *  RT-WMP is free software; you can  redistribute it and/or  modify it
00015  *  under the terms of the GNU General Public License  as published by the
00016  *  Free Software Foundation;  either  version 2, or (at  your option) any
00017  *  later version.
00018  *
00019  *  RT-WMP  is distributed  in the  hope  that  it will be   useful, but
00020  *  WITHOUT  ANY  WARRANTY;     without  even the   implied   warranty  of
00021  *  MERCHANTABILITY  or  FITNESS FOR A  PARTICULAR PURPOSE.    See the GNU
00022  *  General Public License for more details.
00023  *
00024  *  You should have received  a  copy of  the  GNU General Public  License
00025  *  distributed with RT-WMP;  see file COPYING.   If not,  write to the
00026  *  Free Software  Foundation,  59 Temple Place  -  Suite 330,  Boston, MA
00027  *  02111-1307, USA.
00028  *
00029  *  As a  special exception, if you  link this  unit  with other  files to
00030  *  produce an   executable,   this unit  does  not  by  itself cause  the
00031  *  resulting executable to be covered by the  GNU General Public License.
00032  *  This exception does  not however invalidate  any other reasons why the
00033  *  executable file might be covered by the GNU Public License.
00034  *
00035  *----------------------------------------------------------------------*/
00036 
00037 #ifndef _PCAP_LAYER_H
00038 #define _PCAP_LAYER_H
00039 
00040 #include <pcap.h>
00041 #include <stdio.h>
00042 #include "bridge.hh"
00043 #include "basic_io.h"
00044 
00045 struct ieee80211_radiotap_header {
00046         u_int8_t        it_version;     /* set to 0 */
00047         u_int8_t        it_pad;
00048         u_int16_t       it_len;         /* entire length */
00049         u_int32_t       it_present;     /* fields present */
00050 } __attribute__((__packed__));
00051 
00052 
00053 struct  sniff_foreign_t{
00054   char rssi;
00055   char noise;
00056   unsigned long serial;
00057   char type;
00058   unsigned char subtype;
00059   char from;
00060   char to;
00061   char retries;
00062   int rate;
00063 };
00064 
00065 int pcap_init(char * dev, int nn);
00066 int pcap_sniff_packet(char * data, simData_Hdr & sd, unsigned long long & time_us, std::map<int,robo_pose_t> & poses) ;
00067 void pcap_layer_close();
00068 
00069 
00070 #endif  /* _PCAP_LAYER_H */
00071 


ros_rt_wmp_sniffer
Author(s): Danilo Tardioli, dantard@unizar.es
autogenerated on Mon Oct 6 2014 08:27:57