1
0
Fork 0
Commit graph

785 commits

Author SHA1 Message Date
Lars Toenning
fc0a8b1c60 [swift] Fix message node 2020-03-10 14:08:28 +00:00
Lars Toenning
0423472f74 [swift] Sending ground elevation 2020-03-10 14:08:28 +00:00
Lars Toenning
cab6581d3d [swift] Pointers to nodes for get/set data
Calling fgSetXY/fgGetXY takes to long (especially when calling the often needed properties a few times per second in main loop).
Switching to pointers for these nodes, initialized within service-class constructor.
2020-03-10 14:08:28 +00:00
James Turner
be628b36b7 Allow add/remove of IO channels at runtime
Commands:

	add-io-channel
	remove-io-channel
2019-12-19 00:00:41 +00:00
James Turner
c48c1a06e8 Look for protocols in aircraft paths
Modified from patch by Slawek Mikula
2019-12-17 22:34:19 +00:00
James Turner
30b8bdc081 Fix warnings from newer Clang 2019-09-18 23:42:39 +01:00
Edward d'Auvergne
34a6cb3c74 SGSubsystem classes: Registration of all subsystems. 2019-07-01 14:51:32 +02:00
Edward d'Auvergne
d259c70560 SGSubsystem classes: Addition of staticSubsystemClassId() to all subsystems. 2019-07-01 14:51:32 +02:00
Edward d'Auvergne
fb5c36fc82 SGSubsystem classes: Renaming of the subsystem ID variables and functions. 2019-07-01 14:27:30 +02:00
Edward d'Auvergne
7a6e63ddb9 SGSubsystem classes: Subsystem and subsystem group API declaration standardisation.
This is a cleanup commit.
2019-07-01 14:27:30 +02:00
Edward d'Auvergne
60a2444766 SGSubsystem classes: Whitespace standardisation of the declarations.
This is a clean up commit prior to the subsystem API standardisation to simplify
the diffs.  It includes all SGSubsystem and SGSubsystemGroup derived classes.
2019-07-01 14:27:28 +02:00
Scott Giese
efcbdcfec2 [security] Prevent buffer overrun. 2019-06-15 21:30:54 -05:00
James Turner
3c56e74d07 Httpd: Avoid console spam by WS ping/pong frames 2019-06-05 17:41:07 +01:00
James Turner
4ed410dc09 Adjust code for some older GCC versions
Implicit conversion from raw-pointer to std::unique_ptr<T> was failing,
use a stub replacement for std::make_unqiue to wrap this up cleanly.
2019-05-27 11:38:37 +01:00
Lars Toenning
ff7db27cd1 swift: Add version number check 2019-04-30 10:35:30 +02:00
Lars Toenning
cea342a064 swift: Getting pressure altitude 2019-04-30 08:16:38 +02:00
Lars Toenning
aaa753d169 swift: Fixed wrong startup message 2019-04-26 09:37:37 +02:00
Lars Toenning
21124e7b7e swift: CMake adjustment 2019-04-26 09:37:17 +02:00
Lars Toenning
85acefab95 Swift: initial support 2019-04-11 11:36:22 +01:00
Richard Harrison
f014e8825d FGComm: added listener for comm volume
Without this listen volume only changed on comm retune / PTT release
2019-03-27 00:28:20 +01:00
Richard Harrison
8db784bf17 FGcomm: PTT usage and volume
- PTT will now use whatever channel is selected; non zero simply means PTT active.
- The volume as set in the comm[]/radio will now be used as a factor on the FGComm volume
2019-03-21 17:56:59 +01:00
Richard Harrison
b9dc64ab87 FGComm; logic change to disconnect comm when selected channel set to 0.
It will be reconnected if PTT is set; and not disconnected until selected channel is again set to 0.
2019-03-20 15:13:11 +01:00
Richard Harrison
b42969ae91 Add support for FGCom multiple radio support
PTT now uses an int channel number (0 means not pressed, 1 = comm radio 1 (index [0]),etc...)

/comm-radio-selected is the default comm channel to use. This should usually be the same as will be set by PTT into /controls/radios/comm-ptt

However PTT will switch the FG comm inbound and outbound frequency to whichever radio was PTT'd.

New properties also set in multi-player to indicate the transmission frequency and normalised power (currently just set to 1.0)

13001(int)        : sim/multiplay/comm-transmit-frequency-hz
13002(short-norm) : sim/multiplay/comm-transmit-power-norm
2019-03-19 21:20:17 +01:00
James Turner
dee1998979 Less Boost. 2019-02-06 17:36:36 +00:00
James Turner
a9a49bc2e6 Unboosting files
Use simgear::strutils replacements in places, C++11 features in others
2019-02-04 15:20:22 +00:00
James Turner
c3cd7b3978 Remove public use of sglog()::would_log() 2018-12-14 15:41:53 +00:00
James Turner
5215e6fcfc Fix an unused var warning 2018-12-10 16:09:53 +00:00
James Turner
6d68e36523 Simple argument parsing for Props protocol
Maps foo=bar arguments to the top-level arguments dictionary of the
command, as strings only. (We could add CMake style foo:type=bar in
the future if needed). Very basic but this enables a bunch of useful
cases, since SGPropertyNode will do value conversion from string on 
access.
2018-11-30 13:59:05 +00:00
James Turner
8510776c1f Switch next to use trunk aircraft catalog 2018-10-23 12:08:28 +01:00
James Turner
ae4fe62d5b Crashfix: props protocol invoking Nasal commands
The protocol was sending command args using a stack local SGPropertyNode,
which doesn’t work since FGNasalSys holds a reference
2018-10-12 22:25:34 +01:00
James Turner
c8ed3f02fe Close & delete telnet (props) channels on close 2018-10-01 13:52:01 +01:00
James Turner
9723f26f23 MirrorPropWebSocket: improve node recycling
Adjust logic for node recycling so common patterns observed with
remote canvas work correctly (remove + add of same nodes).
2018-09-30 10:16:31 +01:00
James Turner
28629b65f2 Property mirror: handle request for missing nodes 2018-09-27 22:39:39 +01:00
James Turner
f54cba9586 Fix a warning, remove unused 2018-08-20 02:58:12 +01:00
James Turner
d534a5ba36 Move build-ID variables to their own header
This is to reduce rebuilding by changing version.h needlessly, since
only a few places use the build ID info.
2018-08-12 11:18:50 -07:00
James Turner
7d84a03dea WebSocket property-mirror: optimise JSON building
Work around some awful cJSON performance when building large arrays,
greatly speeding up remote-canvas updating
2018-06-24 23:22:30 +01:00
James Turner
be3e927d4e Property-mirror protocol C++11 tweaks 2018-06-24 14:32:35 +01:00
Richard Harrison
ff302a307d Canvas Screen image provider:
Change delay to 15 seconds; and alert that there is a delay.

The 15 second delay should be sufficient to allow the compressor to finish processing; and in anycase this is running in a thread and therefore shouldn't freeze the whole sim for the delay period.
2018-06-01 00:45:40 +02:00
Geoff McLane
5d19a88446 Use SGTimeStamp::sleepForMSec(55) to replace sleep/Sleep 2018-05-30 11:59:25 +02:00
ThomasS
2cbd660dc9 Feature for requesting canvas images per HTTP as described in http://wiki.flightgear.org/Read_canvas_image_by_HTTP 2018-05-03 10:25:34 +02:00
James Turner
f760b8cd8f Launcher: fixes for invalid catalog handling 2018-02-28 17:56:40 +00:00
James Turner
a05cdce793 Telent protocol Nasal command 2018-02-11 21:15:45 +00:00
James Turner
b96d4bf315 Limit props/telnet subscription send rate
Prevent FDM-derived properties being sent at full speed (120Hz) which
overloads telnet connections. Instead track dirty properties and
send them at the protocol’s update rate (which is presumably what
the user expects)
2018-02-04 17:07:21 +00:00
ThorstenB
147ff104cd Adds support for NMEA messages for traffic reporting (flarm). Also extends the NMEA base class to handle bidirectional communication. Allows FlightGear to feed position and traffic data (for multi-player and AI aircraft) to NAV/moving-map clients, like xcsoar, skydemon, skymap etc. Some basic flarm configuration commands are also emulated, to properly persuade the clients. By default, all moving aircraft are reported (traffic information). Actual threat-alerts are also supported, but require the installation of the "TCAS instrument". 2017-11-24 22:54:32 +01:00
ThorstenB
ad866afd81 Revised nmea and Garmin protocol classes.
The Garmin protocol implementation really is an NMEA protocol with a few
extra messages. Instead of duplicating the code, introduce the NMEA protocol
as a base class, which is reused for the Garmin class. The input/output
has not changed at all (and it maintains the FG-specific quirks, like our
NMEA class using LF-only linefeeds, while the Garmin protocol uses
CR-LF linefeeds.
2017-11-19 17:33:27 +01:00
ThorstenB
cae4523d97 Completely removed obsolete debug code
as suggested by James.
2017-11-14 20:39:27 +01:00
ThorstenB
6077ef8cdd Remove unused copy&pasted nmea code from other protocol's source. 2017-11-13 20:40:41 +01:00
ThorstenB
f6ce434241 Disabled forgotten debug output. 2017-11-13 20:40:36 +01:00
Florent Rougon
2bf5a96aec Add two missing includes for <algorithm> 2017-11-13 15:58:08 +01:00
Richard Harrison
2c8aad12ba Model relative property tree root binding.
Change fgcommand to take an optional property tree root element.

This fixes the animation bindings to use the defined property tree root - to support multiplayer (or other) model that can bind to the correct part of the property tree.

Requires a corresponding fix in sg to allow the command methods to take an optional root parameter.

What this means is that when inside someone else's multiplayer model (e.g. backseat, or co-pilot), the multipalyer (AI) model will correctly modify properties inside the correct part of the property tree inside (/ai), rather than modifying the properties inside the same part of the tree as the non-ai model.

This means that a properly setup model will operate within it's own space in the property tree; and permit more generic multiplayer code to be written.

This is probably responsible for some of the pollution of the root property tree with MP aircraft properties.
2017-07-05 11:37:17 +02:00
James Turner
29fe9316af Generic protocol fix for integer-factors.
Read all values as floating point before applying a factor, then
convert to the target type (int, byte or short). Suggested and
implemented by Oliver Kroth.
2017-03-16 15:54:38 +00:00
Szymon Acedański
f71c20600a Fixed erroreous reference to array instead of its element
net->master_{bat,alt} are arrays, but were mistakenly used as
values.

This correctly generated a compilation warning.
2017-02-25 15:05:09 +01:00
James Turner
8472f8c6d0 Fix positional ordering of remote-canvas elements.
The mirror protocol now sends the position for internal as well as
leaf nodes, and the group uses this data to sort when no explicit
Z-indices exist. This gets the extra-500 much closer to working!
2017-01-26 23:14:48 +00:00
James Turner
c9f922ce1b Expose node position over property-mirror protocol. 2017-01-26 20:36:07 +00:00
martymac
ffc7ad6cdf Fix build with Clang 4.0.0.
Those patches fix errors related to ordered comparisons between pointers and
integers, such as the ones related here on FreeBSD :

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=216203
2017-01-21 21:32:50 +00:00
James Turner
95e09de1ff Remove a log message. 2016-12-28 22:01:29 +01:00
James Turner
eba1f3221f Fix a bug starting the property-tree mirror. 2016-12-21 10:26:31 +00:00
Torsten Dreyer
c472788ad8 Httpd: fix slow websocket init 2016-12-20 11:46:02 +01:00
James Turner
4fb5bc8512 Property-Mirror websocket: fix removing props.
Special case handling when recently removed properties are re-added;
when this happens simply send a value change since it's much cheaper
over the wire and for the receiver. Poorly designed Canvas code does
this frequently (eg, every update)
2016-12-10 22:01:25 +00:00
James Turner
b767a33f84 MirrorPropertyTree websocket fixes
- deal with ‘NONE’ properties correctly
- use a better method to send the initial tree on connection.
2016-12-05 21:27:38 +00:00
Torsten Dreyer
c3c0d25fe7 Fix Linux build 2016-12-03 22:46:31 +01:00
James Turner
47042b03f4 Expose an entire property tree via WebSockets.
Use a recursive listener to expose a property tree via a WebSocket.
Currently using a JSON-based encoding, will likely change to binary so
please don’t write code using this interface until the encoding
is stable and documented!
2016-12-03 14:23:48 +00:00
Torsten Dreyer
c4ea89dc97 Revert "temporarily add some noisy debug messages"
This reverts commit f538a6e1a1.
2016-11-20 11:39:46 +01:00
Torsten Dreyer
f538a6e1a1 temporarily add some noisy debug messages 2016-11-19 18:26:06 +01:00
Torsten Dreyer
b652758330 Merge branch 'topics/mpdiscovery-via-dns' into next 2016-11-17 14:45:40 +01:00
Torsten Dreyer
994ea1674b replace many auto_ptr by unique_ptr 2016-11-14 22:20:46 +01:00
Torsten Dreyer
09949ff3e3 Some logging cleanup and ignore SRV records with port #0 2016-11-14 21:57:50 +01:00
Torsten Dreyer
979010de4d Initial commit of mpserver discovery via DNS 2016-11-10 11:14:49 +01:00
Torsten Dreyer
65b51b8d91 Limit the update rate of the property change websocket
Of fast systems with 60fps sending many properties to web clients
may overrun the rendering capabilities of the browser. At some point
the web socket client halts the simulation by throtteling the network
connection.

Update rate is settable at startup setting to a double value
/sim/http/property-websocket/update-interval-secs
(default: 0.05 aka 20Hz)
2016-10-26 11:02:24 +02:00
Curtis L. Olson
7da08db463 Update default aircraft hangar catalog.xml url. 2016-09-07 11:39:37 -05:00
James Turner
9cffcf63ae Further SGPath encoding fixes. 2016-07-01 04:54:29 -05:00
James Turner
6d0c2070fd Use future-proof SGPath APIs.
Remove uses of .str(), .c_str() and some other methods of SGPath.
Pass SGPath directly where possible, or explicitly convert to the
appropriate 8-bit encoding.
2016-06-28 10:08:38 +01:00
James Turner
5d624b4882 Fallback URL when official catalog is not found.
Tolerate the case where a URL matching the exact FG version is
not found; lookup a generic URL, in the hope it supports our
version (additional changes will make this more likely)
2016-05-26 17:37:26 +01:00
James Turner
733e3b3f0c HTTP subsystem has a default name.
Switch to using type-safe accessors now.
2016-03-24 15:08:38 +00:00
James Turner
bb9fd9defe Fix a bug with updating packages.
- always refresh the catalogs each launch, so we don’t get mismatches
  between the cached copy the and package zips.
2016-01-26 16:46:58 +00:00
Torsten Dreyer
6f09b9e31e httpd: expose /fg-home and /fg-root 2016-01-13 13:25:16 +01:00
James Turner
e5fa1a5ab1 Merge /u/userid-1550991/flightgear/ branch next into next
http://sourceforge.net/p/flightgear/flightgear/merge-requests/31/
2015-12-14 14:57:18 +00:00
www2
2da5541901 Add feedback if prompt mode is use 2015-12-13 15:57:53 +01:00
www2
95e3d00a17 Add new commands to telnet protocall
New comands:
setb set a Boolean value
setd set a Floaring point value
seti set a integer value
del delete a node
2015-12-12 15:43:00 +01:00
James Turner
8877b442f8 ATC/Traffic doesn’t crash reset.
- remove some global headers from AI headers, to avoid pollution
- change how ATC owns the ‘player’ FGAIAircraft so reset works
- ensure AIAircraft controllers are cleared on unbind for reset
2015-12-11 12:11:59 -06:00
James Turner
be1291f689 Change handling of default hangar / catalog.
- no longer re-add it on startup, add an explicit button in the UI

(will add a more obvious item to the aircraft list in a follow-up
commit)
2015-11-23 22:58:00 +00:00
James Turner
5f0e347c60 Keep in sync with SimGear Package API 2015-09-27 19:44:39 -05:00
James Turner
18a898f5f9 Lots of work on aircraft package support 2015-09-20 19:46:35 -05:00
Torsten Dreyer
36113bf69d Cleanup: remove unused code and includes
no functional change
jpg-httpd functionality was moved into httpd with 3.4
cmd-line option still spits out a warning
2015-07-08 17:24:13 +02:00
Torsten Dreyer
cd0f0b9856 Fix some warnings 2015-06-12 11:51:11 +02:00
Torsten Dreyer
93f03f5f2e property browser: group radio-button elements
This allows to better render bool properties
2015-04-15 10:41:31 +02:00
Torsten Dreyer
8f9df6940f httpd: extend the NavDbUriHandler
- add more details for airports
- add "q=airports" query to get the airport list
- add "q=airport&id=abcd" query to get airport details
2015-03-28 00:34:28 +01:00
James Turner
f2d6b76b13 Portability: Fix compile errors on MSVC (cmath)
From Scott (xDraconian)
2015-03-24 11:11:42 -05:00
Torsten Dreyer
3ee36a7143 PropertyChangeWebsocket: sanitize property names 2015-03-17 09:27:03 +01:00
Torsten Dreyer
f5f82c461f RunUriHandler: add some INFO logging for the requests 2015-03-11 22:28:23 +01:00
Torsten Dreyer
f7d476c856 extract RemoteXMLRequest to make it reusable 2015-03-11 18:50:11 +01:00
James Turner
11c2623dec Start wiring package manager into the launcher. 2015-03-11 17:09:59 +00:00
James Turner
68efa84b3a Remove obsolete #ifdef check 2015-03-11 17:09:59 +00:00
Torsten Dreyer
f32f1fba59 Fix recently introduced bug in json-to-prop conversion 2015-03-11 16:59:58 +01:00
Torsten Dreyer
fced50f480 JSON Properties: encode NaN as null
JSON doesn't know about NaN, probably null matches best
2015-03-09 16:17:20 +01:00
Torsten Dreyer
8b141025cd httpd: expose if airport has metar in navdb uri handler 2015-03-09 14:53:40 +01:00
James Turner
bfeb41858d Cmake always generates version.h
- simplify some code as a result
2015-03-08 00:42:39 +00:00
Torsten Dreyer
0f72564140 Use the pagedPathForHistory in the FlightHistoryUriHandler 2015-03-03 17:10:16 +01:00
Torsten Dreyer
2e5db3ce85 httpd: fix misplaced warning message 2015-03-02 20:39:23 +01:00
Torsten Dreyer
0fcfbe9221 wrap the json flight history as a feature
this allows to attach properties later
2015-02-27 15:54:28 +01:00
Torsten Dreyer
146efcafa4 JsonUriHandler: allow POST updates without child
updates to properties used to be
POST /json/some/property/path
{
  name: 'somechild',
  value: 'somevalue'
}

which required some ugly path hacking when directly updating a node.
now, this works too (and in a probably more intuitive way)
POST /json/some/property/path/somechild
{
  value: 'somevalue'
}
2015-02-27 11:07:25 +01:00
Torsten Dreyer
4b5dec2cae HTML Property Browser: use radiobuttons for bools 2015-02-26 18:14:09 +01:00
Torsten Dreyer
0034d6b59a flighthistory service: use GeoJSON instead of own invention
Track now comes as a LineString object
{
  "type":"LineString",
  "coordinates": [ [lon,lat,alt], [lon,lat,alt], ... ]
}

ref: http://geojson.org/geojson-spec.html#linestring
2015-02-25 10:38:22 +01:00
Torsten Dreyer
cc6178a9f3 Expose FlightHistory as a http service
usage:
GET http://localhost:8080/flighthistory/track.json
retrieves track as JSON data
{
  flightHistory: [
    {
      latitude: (number),
      longitude: (number),
      altitude: (number)
    }
  ]
}

GET http://localhost:8080/flighthistory/track.kml
retrieves track as KML path
optional request parameter:
LineColor=(hex encoded rgba color)
LineWidth=(line width in pixel)
PolyColor=(hex encoded rgba color)
interval=(number of seconds to auto-refresh)
2015-02-23 16:33:58 +01:00
Torsten Dreyer
6ecbca9e01 package system: de-hardcode default catalog id and url
make default catalog id and url configurable through properties
on startup. Provide defaults to preserve current functionality.

/sim/package-system/default-catalog/id
/sim/package-system/default-catalog/url
2015-02-17 12:41:18 +01:00
Torsten Dreyer
828f14c4f7 Ooops... 2015-02-17 12:09:22 +01:00
Torsten Dreyer
ae91b9cede Initial work for a PKG http service 2015-02-17 12:06:50 +01:00
Torsten Dreyer
6e3486349b PropertyBrowser: Add a JSON link and the path 2015-02-13 11:42:45 +01:00
Torsten Dreyer
6970ea69a8 httpd/json: send as correct typ for bools and numbers 2015-02-11 11:34:16 +01:00
Rebecca N. Palmer
fe0015bda0 Fix typo, thanks to Markus Wanner 2015-01-18 22:23:49 +00:00
Torsten Dreyer
4b4f5c9e9a httpd: some code cleanup for JsonUriHandler.
no functional change
2014-11-11 08:59:41 +01:00
Torsten Dreyer
aeb1eedba8 Allow property set on the /json/ uri handler 2014-11-10 14:23:12 +01:00
Torsten Dreyer
d46aa5114f httpd: upgrade to latest mongoose 5.5 2014-11-06 22:21:22 +01:00
Torsten Dreyer
0376ab3f28 Fix #1579: Handle special characters in html property browser 2014-11-04 22:21:44 +01:00
Torsten Dreyer
e786b1a54e httpd: expose airport id to geojson properties 2014-10-16 13:09:43 +02:00
Torsten Dreyer
cc526174c1 httpd: fix mjpeg encoding 2014-10-02 11:13:12 +02:00
Torsten Dreyer
c0c82f4f7b Fix (1st try) absolute paths for httpd url_rewrites
Thanks to Alan Teeder for guiding me into the right direction
2014-09-24 20:50:10 +02:00
Torsten Dreyer
2859400336 Some debug stuff for the mongoose httpd
- add a config-dump on log-level=info
- add an access-log option
  use --prop:string:/sim/http/options/access-log-file="/path/to/access.log"
2014-09-24 17:40:04 +02:00
Torsten Dreyer
996a46536d httpd: fix log message typos
no functional change
2014-09-21 22:29:10 +02:00
Torsten Dreyer
e8d851d236 Allow user defined mime types for the internal httpd 2014-09-20 01:48:32 +02:00
Torsten Dreyer
c9d159e71f httpd: downgrade log message 2014-09-15 10:54:00 +02:00
Torsten Dreyer
512ec61e8e Expose the running-state of the internal webserver 2014-09-12 22:58:30 +02:00
Torsten Dreyer
b50b1a778b httpd: expose the aircraft dir to the web server
add a (currently) hard coded url rewrite to access the
currently used aircraft by
http://localhost:8080/aircraft-dir/
2014-09-10 22:43:06 +02:00
Thomas Geymayer
486ef5b06c pkg: retrieve existing install (or register callback). 2014-06-30 18:15:31 +02:00
James Turner
7e8d713b28 Pkg: initial support for Variants
- aircraft init code can deal with a variant ID
- Nasal API can return a hash with variant IDs and names
2014-06-15 20:10:24 +02:00
Thomas Geymayer
33d23026c4 pkg: allow 'installed' as filter criterion. 2014-06-15 16:36:02 +02:00
Thomas Geymayer
e1eb9e4418 Enable package system API 2014-06-13 16:08:26 +02:00
James Turner
8f754a1673 Type-correct decoding of JSON to props. 2014-06-12 19:58:13 +01:00
James Turner
d1a477324e Websocket get/set props and exec commands. 2014-06-12 17:57:25 +01:00
James Turner
ee627b8652 Expose package file size to Nasal. 2014-06-12 17:51:19 +01:00
James Turner
7a5b729052 Pkg: nicer Nasal syntax for tags in queries. 2014-06-12 08:17:05 +01:00
Thomas Geymayer
53c0454931 Package: warn for unknown filter term and use Hash::iterator. 2014-06-11 18:19:13 +02:00
Thomas Geymayer
0e286717a6 pkg: Expose install callbacks to Nasal. 2014-06-10 23:53:57 +02:00
James Turner
afa45240b0 Packages: search from Nasal
- also allow direct uninstallation.
2014-06-10 22:12:27 +01:00
Thomas Geymayer
1af3ad2525 Nasal: extend pkg API. 2014-06-04 17:50:25 +02:00
James Turner
d1fd5756f6 Initial package-system integration.
- disabled by default
- incomplete, adding so Thomas can see the API
2014-05-31 18:04:56 +01:00
Torsten Dreyer
2e76a2c72a Update of the httpd implementation
- Add a screenshot uri handler
- Enable persistent http connections
- Simple CORS implementatation for the
  JSON property uri handler

many changes for the httpd
2014-05-22 10:28:54 +02:00
Torsten Dreyer
390f6dd32d fix wrong computation of delta-t in jpg-httpd
this lead to a screenshot taken on each frame instead of
the defined interval
2014-03-29 11:22:34 +01:00
Torsten Dreyer
75f9d7e66e add nChildren to json properties 2014-03-26 15:06:24 +01:00
Torsten Dreyer
0dcc8aa34d Add a timestamp to JSON properties
add special attribute 'ts' to a JSON property reflecting
/sim/time/elapsed-sec

always add timestamp for listener properties
add timestamp for json requests if req param t=y is set
2014-03-26 08:51:15 +01:00
Torsten Dreyer
f68ae55068 Don't return invalid JSON if node not found 2014-03-25 21:43:08 +01:00
Torsten Dreyer
e7dec994b8 httpd: provide more airport information in geojson
- provide runways as polygon geometry
- provide longest runway lenght, heading and surface type
- some code cleanup
2014-03-23 21:19:04 +01:00
Torsten Dreyer
527eb9d444 httpd navdb: report ils/loc as geojson multilinestring 2014-03-21 13:00:59 +01:00
Torsten Dreyer
3d33aff7bc Add a http handler to access the nav database
see the browsermap for an example
2014-03-19 17:23:53 +01:00
Torsten Dreyer
efcc89480d httpd: don't spam the console with debug messages 2014-03-17 16:38:53 +01:00
Torsten Dreyer
1867ccb4a8 httpd: better handling of first-time notifications
ensure new listeners get notified on first update loop
also cleanup the PropertyChangeObserver on reset
2014-03-17 16:22:42 +01:00
Torsten Dreyer
a830708252 PropertyChangeWebsocket: fire change after subscribe 2014-03-14 21:36:29 +01:00
Torsten Dreyer
95d4c5898d httpd: handle url-rewrites 2014-03-14 16:39:16 +01:00
Torsten Dreyer
7132947d16 httpd: update mongoose and websockets
* mongoose updated to 5.3
* first stab at implementing websockets, here a property change listener
  websocket. This websocket is at ws://yourhost:yourport/PropertyListener
  see FGDATA/Docs/gui/radio.html for an example
2014-03-12 22:39:37 +01:00
Torsten Dreyer
64c393d022 http property browser: don't crash on invalid nodes
Don't expect users to always pass valid node names
or paths
2014-03-10 23:40:42 +01:00