Commit Graph

460 Commits

Author SHA1 Message Date
Jason Watkins
00efb7e089 Merge branch 'feature-python' into develop
Resolves #8
2015-05-01 13:52:18 -07:00
Jason Watkins
10d21cc0df Finished implementing unit tests and fixed bugs found. 2015-05-01 13:50:48 -07:00
Jason Watkins
685d121edd Fixed several bugs found by unit tests. 2015-05-01 09:14:35 -07:00
Jason Watkins
31095b716b Updated Python client unit tests. 2015-05-01 09:14:34 -07:00
Jason Watkins
2a874eb514 Refactored Python client to match other clients. 2015-05-01 09:14:33 -07:00
jwatkins42
18aa9fa251 Fixed several bugs based on test results 2015-05-01 09:14:33 -07:00
jwatkins42
9fb2274ae8 Started implementing tests 2015-05-01 09:14:32 -07:00
jwatkins42
4aaca80d3e Added PyTools project files for Python API 2015-05-01 09:14:32 -07:00
jwatkins42
fd63976e4d Finished basic Python impl. 2015-05-01 09:14:31 -07:00
jwatkins42
04897b878e More python! 2015-05-01 09:14:31 -07:00
jwatkins42
b6233ab5d7 Started implementation of Python version of XPC client. 2015-05-01 09:14:30 -07:00
Jason Watkins
69dadea027 Merge branch 'feature-logging' into develop 2015-04-30 16:26:34 -07:00
Jason Watkins
d735e0f3ad Updated plugin logging.
- The plugin now keeps the log file open for the duration of its lifetime.
 - This greatly improves the performace of the logging component, which was previously a significant bottleneck even at low logging verbosity.
 - The log now prints timestamps to the millisecond.
2015-04-30 16:24:18 -07:00
Jason Watkins
aaf25a9933 Updated Log to use C++ headers cstdio and ctime instead of stdio.h and time.h. 2015-04-30 15:11:14 -07:00
Jason Watkins
37eb6b6b03 Added X-Plane version information to the XPC log file. 2015-04-30 13:53:02 -07:00
Jason Watkins
e21006baee Added Release build settings for Windows to plugin.
- Release builds in Visual Studio aggressively optimize the plugin.
 - Results in nearly a 7x reduction in binary size.
2015-04-30 13:47:13 -07:00
Jason Watkins
85e3ce91dd Removed -nodefaultlibs flag on Linux 64 bit builds. 2015-04-30 13:03:55 -07:00
Jason Watkins
8898ff9be9 Added explicit -m64 flag to CMakeLists. 2015-04-30 13:03:54 -07:00
Chris Teubert
2c9982fea0 Remove Todo Comment 2015-04-30 11:16:51 -07:00
Chris Teubert
6ed9c67469 Fixed Typo 2015-04-30 11:16:51 -07:00
Jason Watkins
b243306866 Added namespace qualifiers for memcpy in Message logging. 2015-04-30 11:03:42 -07:00
Jason Watkins
781fc390c2 Fixed bug in array initialization for SIMU command. 2015-04-30 10:03:24 -07:00
Jason Watkins
ed8d065642 Explicitly initialize sock to ~0 if WSAStartup fails. 2015-04-30 09:32:19 -07:00
Jason Watkins
a9aba0e8de Fixed the order of the orientation drefs in POSI tests. 2015-04-30 09:22:44 -07:00
Jason Watkins
57be2704d1 Fixed typo in DataManager validation checks. 2015-04-30 09:17:44 -07:00
Jason Watkins
0533480b8e Updated LOG_VERBOSITY description. 2015-04-30 09:07:11 -07:00
Jason Watkins
902aa006e8 Updated C client socket timeout.
The C client previously set a very short read timeout because it was required
 by the plugin. To compensate for this on the client side, we would try to
read several times in a loop. Since the plugin no longer uses the C client for
networking, we can do away with the loops and set a proper timeout.
2015-04-30 09:04:32 -07:00
Jason Watkins
39c2f58a54 Fixed issues related to overwriting values in POSI commands.
- Added global position drefs for multiplayer aircraft.
 - Added checks for the "don't change" sentinel value to SetPosition, SetOrientation and SetFlaps.
 - Reordered validation checks in SetGear to be consistent with the above methods.
 - Removed some now redundant "don't change" value checks in the MessageHandlers class.
2015-04-30 09:04:31 -07:00
Chris Teubert
cde91d84c9 Mac Binary 2015-04-30 09:04:31 -07:00
Chris Teubert
e512cdd981 Pause should be an array 2015-04-30 09:04:30 -07:00
Chris Teubert
7f9be34d45 Y_AGL->Elevation Fix 2015-04-30 09:04:29 -07:00
Chris Teubert
94db707414 removed sendReadTest-c 2015-04-30 09:04:29 -07:00
Chris Teubert
644dc8c5eb uncommented sendPOSITest 2015-04-30 09:04:28 -07:00
Chris Teubert
93c54e315a Compare 2d array 2015-04-30 09:04:28 -07:00
Chris Teubert
62a7f26289 getDREFS array should be 2d 2015-04-30 09:04:27 -07:00
Chris Teubert
1ae095b365 Y_agl should be elevation! 2015-04-30 09:04:27 -07:00
Chris Teubert
50fd1d7074 Made IP #define in C Tests 2015-04-30 09:04:22 -07:00
Chris Teubert
19e89e9edb Merge branch 'develop' of https://github.com/nasa/XPlaneConnect into develop 2015-04-29 14:23:14 -07:00
Chris Teubert
683257f628 Fixed header file name. 2015-04-29 14:23:00 -07:00
Chris Teubert
cec199410d #define IP address in CTests
For easy modification
2015-04-29 13:58:20 -07:00
Chris Teubert
761ee793ba Updates to use new function names 2015-04-29 13:57:50 -07:00
Jason Watkins
f3e87a8216 Fixed duplicate declaration of socket in sendDREFTest. 2015-04-29 12:46:41 -07:00
Jason Watkins
2d355ebb73 Fixed a bug in Drawing::SetMessage
- The terminating null character of the message string is now written.
 - Along with baef257, this fully resolves #60.
2015-04-29 12:44:20 -07:00
Jason Watkins
54368bb65a C client API tweaks
- Swaped names of openUDP and aopenUDP.
 - openUDP is now the "automatic" version, requiring only the X-Plane IP address.
 - aopenUDP is now the "advanced" version, requiring both the X-Plane port and a client port.
 - Added support for passing NULL to sendTEXT.
2015-04-29 12:44:19 -07:00
Jason Watkins
1765d0a3c4 Updated plugin version number to 1.0.1. 2015-04-29 12:44:19 -07:00
Jason Watkins
955657bb96 Improved DataManager string Get and Set methods.
- The Get method no longer assumes unknown drefs are floats.
 - The Get method now properly accounts for the fact that the dref data type is a bitflag.
 - Binary drefs are now properly read and packed into `values`.
  - This is a rather inefficient process, as it quadruples the number of bytes we have to send out. Should look into better ways to do this in the future.
 - The Set method now handles data types correctly.
 - The Set method now supports binary datarefs.
 - Improved logging of edge cases.
 - Added a check to warn about setting read-only datarefs if verbose logging is enabled.
2015-04-29 12:44:18 -07:00
Jason Watkins
dc4abba73a Fixed several issues in the C client unit tests.
- getDREF and sendDREF tests now work correctly.
 - Removed SendReadTest.
2015-04-29 12:44:02 -07:00
Jason Watkins
3b2e697158 Removed 'p' variants of the sendCTRL and sendPOSI functions from the C client. 2015-04-29 08:14:55 -07:00
Jason Watkins
326bae1dbf Updated C client unit tests.
- openTest now validates that "localhost" resolves to "127.0.0.1".
 - sendTEXTTest now sets and clears text. Note that since there is no way to externally verify the result of a TEXT command, the user must now step through this test using the debugger to fully verify functionality.
 - requestDREFTest renamed to getDREFTest.
 - getDREFTest now gets one dataref of each type except multidimensional arrays.
 - sendDREFTest now sets one dataref of each type except mulidimensional arrays.
 - sendDREFTest now attempts to set a read-only dataref. Need to work out how to test the result of this effectively.
 - psendCTRLTest & sendCTRLTest now test multiple values, default values and sending only some parameters.
 - Added psendPOSITest.
  - psendPOSITest & sendPOSIest now test multiple values, default values and sending only some parameters.
 - sendWYPTTest now clears waypoints before setting them.
2015-04-28 15:28:41 -07:00
Jason Watkins
0836c971f5 Deleted C++ test scripts.
- These tests create a great deal of duplicated work.
 - The only errors caught by these tests would be errors that occur in the C client only when compiled by a C++ compiler.
 - This error case is deemed unlikely enough that it is not worth the extra work to maintain two sets of tests.
2015-04-28 12:19:21 -07:00