Commit Graph

142 Commits (master)

Author SHA1 Message Date
Matteo Cypriani bce8896b4b Add explicit padding for all the structs
Indicate padding bytes explicitly in all the structures. Some of the
structures could have their size reduced by reordering their fields by
size (especially in owlps.h).
7 years ago
Matteo Cypriani c6e39f7e70 [libowlps] Use labs() for int_fast32_t
int_fast32_t is at least 32-bit wide, like long. Hence, labs() should be
used instead of abs().
7 years ago
Matteo Cypriani 759db45a50 A few old cosmetic changes 7 years ago
Matteo Cypriani bc6ec14fa8 Update COPYRIGHT.t2t URL 7 years ago
Matteo Cypriani c567592167 [lib] owl_close_fd(): handle negative fd 9 years ago
Matteo Cypriani c09ed87f94 [lib] captured_request's alignment in comment
Add position and size of alignment bytes in the _owl_captured_request
structure (in comments).
10 years ago
Matteo Cypriani 4d78da4721 Doc and comments: some typos & small additions 10 years ago
Matteo Cypriani d995cdfc7d [lib] Add macro OWL_IS_REQUEST_TYPE()
This macro allows to check if a given number is a valid request type.
11 years ago
Matteo Cypriani 49066f451b [lib] getaddrinfo() in create_udp_listening_socket() 11 years ago
Matteo Cypriani 25cc1ee67a [lib] getaddrinfo() in create_udp_trx_socket()
Use getaddrinfo() to resolve names in owl_create_udp_trx_socket(). The
client_description parameter has been removed from the function's
synopsis.
11 years ago
Matteo Cypriani efaf4da6ed [doc] Somewhat improve Doxygen-generated man pages
Fix some problems in the Doxygen-generated man pages (C libraries), the
more noticeable being removing the full path of the files from the
header and synopsis.
11 years ago
Matteo Cypriani 763b36807e Increment lib and lib-client version numbers
libowlps and libowlps-client were changed in this development branch so
we increase the version number.
11 years ago
Matteo Cypriani 69cba07122 [lib] Access Point -> Capture Point (API change)
Same work as for Aggregator and Listener to get rid of the old "AP"
terminology.

API change: structures with an ap_mac_addr_bytes field are modified.
11 years ago
Matteo Cypriani 5bf1bcb4d2 Handle aggregation CSV format version
The first field of the Aggregator's CSV output files is now an unsigned
integer that announces the version of the CSV format used. Current
version is 1 and the subsequent fields are not modified, so that an
aggregation file generated with a previous version can still be used by
adding "1;" at the beginning of each line.

The Positioner has been adapted to handle this new format.
11 years ago
Matteo Cypriani d32813376b CMake: pass installation prefix to programs
The file libowlps/owlps-config.h.in was added to allow CMake to pass the
installation prefix variable to the programs. That allows the programs
to look for their configuration file at the right position (i.e. in the
etc/owlps directory under the installation prefix).
11 years ago
Matteo Cypriani 3aa5ae7513 Use Doxygen on lib*
Doxygen comments are now used in libowlps, libowlps-client and
libowlps-resultreader. doc/Doxyfile was added as well as CMake rules to
generate man pages for the libraries' header files.
11 years ago
Matteo Cypriani 410038f38c [lib] Remove unused owl_timestamp_is_null() 11 years ago
Matteo Cypriani abce1f985e [lib] Rework owl_frequency_to_channel() 11 years ago
Matteo Cypriani 80fd5b287b Update and centralise copyright information 11 years ago
Matteo Cypriani 1cb5742ef9 CMake: rework compilation/link flags
- Default compiler and linker flags were added silently. They are now
  set in the cache if no previous values are present.
- Debug flags and regular flags have been merged.
- Position-independent code (doesn't appear in the cache because CMake
  lacks variables like CMAKE_EXE_COMPILE_FLAGS):
  - Shared libraries are compiled with -fPIC.
  - Executables and static libraries are compiled with -fPIE.
  - Executables are linked with -pie -fPIE.
11 years ago
Matteo Cypriani 51cb1ab08a CMake: link libraries to libc and other
Link the libraries to libc explicitely.
Link libowlps to librt on GNU platforms.
11 years ago
Matteo Cypriani c41f6d9547 CMake: add installation targets 11 years ago
Matteo Cypriani 9908ecf905 CMake: handle libraries' sonames
libowlps-client and libowlps-resultreader were never built as shared
libraries, therefore we set their version number to 1.0.

For stable releases, the rule is to increase the minor version number
when changes are made to the library without changing the API, and to
bump the major version number (soname) in case of API change.

In the development branch and for development point releases, the soname
should not be increased, even in case of API break. The minor version
number should be bumped instead.

Following this rule, libowlps' version number is bumped to 3.1, as some
changes were made since version 3.0.
11 years ago
Matteo Cypriani 4467fcd52c Initial CMake setup 11 years ago
Matteo Cypriani 005e5da12e Delete Makefiles 11 years ago
Matteo Cypriani 0614b52219 [lib] Stop defining owl_bool (use stdbool.h)
We don't define our own boolean type in owlps.h any more: bool (from
stdbool.h) is used instead.
11 years ago
Matteo Cypriani 4aed9c1ef0 Radiotap Antenna Signal field is signed
Using int8_t instead of uint8_t which was erroneously used to code the
Antenna Signal radiotap field.
11 years ago
Matteo Cypriani 8df82b9c41 Fix typo "endianness" 11 years ago
Matteo Cypriani cadb64e4c6 [lib] Fix a typo in owlps.h 11 years ago
Matteo Cypriani 8455dd0d74 Add copyright & license information
Add the file COPYRIGHT, the CeCILL license's text, and update the source
files' headers with the copyright and license information.
11 years ago
Matteo Cypriani e278aab032 [lib] Force 9 digits to display nanoseconds
In owl_timestamp_to_string(), the conversion of the nanosecond value is
forced to be on 9 digits.
12 years ago
Matteo Cypriani b594505ea7 [lib] Optimise owl_mac_equals()
MAC addresses are more likely to vary in the right octets than in the
left octets, so we compare them starting from the end rather than from
the beginning.
12 years ago
Matteo Cypriani 316db76861 Makefiles: add common-rules.mk, drop openwrt files
This is the sequel of the work on the Makefiles' unification.
12 years ago
Matteo Cypriani 9ec71b800e [lib*] Merge Makefile and Makefile_atheros_openwrt
In libowlps and libowlps-client (libowlps-resultreader does not have an
Atheros Makefile).
12 years ago
Matteo Cypriani 92485f3f67 Add common.mk
Adapt all the Makefiles to use it.
Rename all the Makefile_atheros_openwrt-10.03 to
Makefile_atheros_openwrt.
12 years ago
Matteo Cypriani dc0e56c0ec [lib] Bump so version to 3.0 12 years ago
Matteo Cypriani 9f8c85d9c7 [lib] timestamp_now(): gettimeofday() if needed
Use gettimeofday() when clock_gettime() is not available.
12 years ago
Matteo Cypriani e98474e678 [Aggregator] Send the capture time to Positioner
The Aggregator now transmits the capture timestamp of each packet to the
positioning server. For now this timestamp is not stored, only displayed
(in verbose mode) when a request is received.
12 years ago
Matteo Cypriani b60d0d380f [Aggregator] Send the mobile's IP to Positioner
For now the positioning server only displays the mobile's IP address (in
verbose mode) and updates it in the stored Mobile.
12 years ago
Matteo Cypriani 5939bdbd04 [lib] Add nb_packet & packet_id to the structures 12 years ago
Matteo Cypriani d5e2c975ae Rename Positioning -> Positioner
To be consistent with the other modules, the positioning server must be
called OwlPS Positioner instead of Positioning, and the executable
owlps-positionerd (even if the daemon mode is not implemented yet).
That's a big commit for a tiny change.
12 years ago
Matteo Cypriani 6b7e5668fa Add/update headers on the top of each source file 12 years ago
Matteo Cypriani 1ebc0c57ed Different port for autocal. orders and hello
Differentiate the port on which the autocalibration hello messages are
sent to the aggregator by the listeners, and the one on which the
autocalibration orders are sent by the aggregator to the listeners.

This will allow to run a listener and an aggregator on the same machine
with autocalibration enabled.

Both in the listener and the aggregator, the option -a (autocalibration
port) has been replaced by the options -O (autocalibration order port)
and -H (autocalibration hello port). In the listener, the option -H was
previously used to set the hello delay; this is now the role of the -T
option.
12 years ago
Matteo Cypriani ee3ab7b383 [Listener] Same port for all requests
The autocalibration requests are now sent on the same port as the
positioning request, by default. There was no real reason to send them
on a different port.
12 years ago
Matteo Cypriani a81b539a05 Remove Makefiles for OpenWrt 8.09 12 years ago
Matteo Cypriani 58e86c304a [lib] Bump so version to 2.0 12 years ago
Matteo Cypriani cf73bf6309 [lib] Avoid struct arguments & return values
Modify the *time*() functions to avoid passing structures in arguments
(using const pointers instead) or returning structures (using result
arguments instead).
12 years ago
Matteo Cypriani 93f316d2c6 [lib] Fix time_elapsed()
The previous implementation was very naive and incorrect.
12 years ago
Matteo Cypriani 58ba4c79ff [lib] Rename start_time -> capture_time
"start_time" was meaningless in the global data structures of owlps.h,
and could lead to errors in the aggregator, since it defines a field
start_time in one of its internal structures.
12 years ago
Matteo Cypriani aa8d11e12b [lib] Rename antenna_signal_dbm -> ss_dbm
Use "ss" instead of "antenna_signal" in the data types declared in
owlps.h. Shorter, and as meaningful.
12 years ago