Austin Schuh
ac751d3224
Fix unused variable warnings in ntcore ( #1416 )
...
This avoids -Wextra warnings.
2018-11-09 20:02:58 -08:00
Thad House
7c9a3c4d77
Update NI Library to 2019.7.1 and OpenCV to 3.4.3-16 ( #1418 )
...
Add def for each to eliminate duplication of version number.
2018-11-09 19:59:06 -08:00
Sam Carlberg
8be693f55d
Fix list layout in shuffleboard example ( #1413 )
2018-11-09 01:14:15 -08:00
Peter Johnson
622ae29dff
CameraServer: Change opencv sources to publish "cv:" type ( #1412 )
...
The LabVIEW dashboard has been fixed to understand this prefix.
2018-11-09 01:13:39 -08:00
Peter Johnson
e7c98feca2
libuv: Use WPI (FPGA) clock on roboRio ( #1409 )
...
This is set to the FPGA clock by HAL_Initialize. Note this change means
that libuv loops should not be started until after HAL_Initialize is called (on the Rio).
Non-Rio functionality is unchanged.
2018-11-07 00:06:18 -08:00
Jaci Brunning
28087424ec
Add deploy directory detection ( #1400 )
...
Add Filesystem class for java and namespace methods for C++ for detecting deploy location.
2018-11-02 13:16:44 -07:00
Peter Johnson
b6830638df
NetworkListener: use Pimpl idiom ( #1405 )
...
This enables different platforms to use very different implementations.
2018-11-02 13:14:06 -07:00
Liam Kinne
fb557f49ea
Add missing driver station documentation ( #1388 )
2018-11-01 23:34:48 -07:00
Peter Johnson
746f950a0b
Remove ifdefs from linux NetworkListener ( #1404 )
2018-11-01 23:27:22 -07:00
Peter Johnson
9a38a3e188
Don't use static for raw_ostream outs/errs ( #1401 )
...
Static destruction order is not well defined, so it was possible for outs()
or errs() return value to be destroyed even while other code was running,
resulting in a crash. Instead dynamically allocate the static so the
destructor never runs. While this technically leaks, valgrind generally
supresses such leaks as the data is still "reachable" from the static pointer.
2018-11-01 10:48:50 -07:00
Thad House
2e3e3a47b9
Use a kill -9 after attemting a safe kill ( #1397 )
...
Should fix some deploy deadlocks.
2018-11-01 01:55:26 -07:00
Peter Johnson
e27d6d7bb8
cscore: Change impl to only one singleton ( #1398 )
...
This avoids a number of shutdown use-after-free races by controlling the
destruction order. It also is a prerequisite to making the internal
interfaces mockable for unit testing.
2018-10-31 20:22:58 -07:00
Thad House
1dec0393a1
Fix static deletion race condition in DS thread ( #1396 )
...
The static condition variable was getting destroyed before the DS thread exited,
resulting in a deadlock on program exit when the DS thread tried to notify it.
This change moves the condition variable into the DS thread to avoid the race.
2018-10-30 11:51:17 -07:00
Peter Johnson
d03b020326
wpiutil: Add WorkerThread ( #1302 )
...
This provides a worker thread that can execute a work function with the result
going into either a future or a uv::Loop functor.
2018-10-29 20:54:42 -07:00
Austin Shalit
71e29b1d91
Remove unused import from rumble example ( #1395 )
...
This fixes a nit in #1394 .
2018-10-29 20:54:15 -07:00
Thad House
f0b0965f9b
Remove large HAL headers from wpilibc headers ( #1386 )
...
Now only includes the types in the wpilib headers.
Should immensely clean up intellisense.
Closes #1383
2018-10-29 12:49:17 -07:00
Austin Shalit
f774e47c80
Add an example showing how to use a hid rumbler ( #1394 )
2018-10-29 12:37:30 -07:00
Nicolas Machado
761933a164
Refactor Java Ultrasonic to use a List container ( #1389 )
2018-10-29 01:15:32 -07:00
Tyler Veness
99e0f08a6f
Move applicable integration tests to native build as unit tests ( #1364 )
2018-10-29 00:12:38 -07:00
Tyler Veness
e89d5eb692
Fix stringop truncation warning from GCC 8.2 ( #1393 )
...
The next line adds a null terminator, but it's cleaner to just do a
std::memcpy() since the code already assumes a null terminator exists in
the source string.
2018-10-29 00:09:53 -07:00
Austin Shalit
2501e11886
Enable HTML5 javadocs ( #1267 )
...
This suppresses a build warning about HTML 4.01 being used.
2018-10-29 00:08:21 -07:00
Thad House
9174f23f36
Remove some usages of windows.h ( #1370 )
...
For HAL and wpilib, we don't need them, especially where they were being used.
2018-10-28 22:33:55 -07:00
Redrield
9f6544fa87
Allow binding commands to POV ( #1378 )
2018-10-28 21:54:06 -07:00
Peter Johnson
9a1af132bf
Unify GetHostname() and use libuv implementation ( #1391 )
2018-10-28 19:01:48 -07:00
Thad House
a8aacd3657
Update build setup for raspbian and debug binaries ( #1384 )
...
- Build both debug and release binaries
- Append "d" to debug libraries in the style of opencv
- Split shared and static classifiers
- Add raspbian support
2018-10-27 00:19:38 -07:00
Peter Johnson
8ff81f5a2a
cscore: Separate platform-specific sources ( #1387 )
2018-10-23 22:59:47 -07:00
Liam Kinne
349e273ecc
AnalogGyro: add "calibrating for n seconds" message ( #1380 )
2018-10-23 00:29:23 -07:00
Tyler Veness
0a2ab4f0d7
Revert change in behavior in HeldButtonScheduler ( #1381 )
...
Originally, the command was restarted every time the scheduler was
executed if the button was pressed. #1340 changed this behavior in a
breaking manner.
2018-10-20 21:25:37 -07:00
Peter Johnson
7c1a7332e1
uv::Async, uv::AsyncFunction: allow calling from within loop
v2019.1.1-beta-1
2018-10-16 09:40:59 -07:00
Peter Johnson
172e438cd6
wpiutil: uv::Async: Keep weak reference to loop
...
Other handles can only be used within the loop itself, but Async is intended
to be used from another thread. This introduces the possibility of a race
condition between the loop being destroyed and the Async being destroyed.
Change Async to keep a weak reference to a loop and check it before performing
libuv operations.
2018-10-16 09:40:59 -07:00
Peter Johnson
1a7a0db1ff
wpiutil: Change uv::AsyncFunction to use promise/future.
...
This allows the called function to pass along the promise to another
asynchronous callback.
To avoid memory allocations, add a home-rolled, simplified, non-allocating
version of std::promise and std::future as wpi::promise and wpi::future.
2018-10-16 09:40:59 -07:00
Thad House
11e5faf469
Use Array Constructor rather then new array to toArray ( #1368 )
...
A bit cleaner to use, and more standard for the current java. Still java 8 compatible.
2018-10-16 01:30:42 -07:00
Peter Johnson
c7118f8ade
wpiutil: Signal: Don't use std::forward when calling ( #1371 )
...
This causes a std::move of objects that are both moveable and copyable.
2018-10-16 00:39:16 -07:00
Peter Johnson
7933d2cbe5
wpiutil: uv: Don't close uninitialized handles ( #1372 )
2018-10-16 00:38:48 -07:00
Dan Katzuv
ce8c71b1f3
Fix link for license ( #1367 )
...
The previous license link referred to `license.txt', but the correct file is `LICENSE.txt`.
2018-10-14 09:58:54 -07:00
Liam Kinne
da9a575526
Rename squaredInputs to squareInputs in DifferentialDrive ( #1361 )
...
Fixes #1360 .
2018-10-13 23:10:16 -07:00
Thad House
7068551a3e
Bump OpenCV and GTest to 2019 dependencies ( #1366 )
2018-10-13 20:46:14 -07:00
Tyler Veness
bd9484a2f4
Make MyRobot compilation test use TimedRobot ( #1363 )
...
IterativeRobot is deprecated.
2018-10-12 23:41:05 -07:00
Thad House
b9fa3a4398
Update to 2019 RoboRIO and 2019 v4 image ( #1352 )
...
Also make updates for Java 11:
* Disable errorprone plugin (currently broken on Java 11)
* Update checkstyle to 8.12
* Update pmd to 6.7.0
2018-10-07 18:11:57 -07:00
Thad House
88b93c220e
Update NativeUtils to not copy NI libraries to jenkins RoboRIO ( #1359 )
...
Allows for compile only shared libraries
2018-10-06 20:51:00 -07:00
Peter Johnson
0a937bb5b9
wpiutil: SafeThread: Ensure thread is released in destructor ( #1358 )
...
The thread must be released with either a detach or a join, otherwise
std::terminate is called.
2018-10-06 18:07:56 -07:00
Peter Johnson
613d5eda0d
wpiutil: SafeThread: join on thread exit ( #1357 )
...
This can be conditionally disabled (for cases like JNI callbacks where the JVM
may block callbacks into it during shutdown).
2018-10-06 15:17:13 -07:00
Peter Johnson
18c8cce6a7
SafeThread: Avoid use-after-free risk in thread shutdown ( #1355 )
...
Use shared_ptr to keep data alive until the thread has terminated.
2018-10-05 16:32:43 -07:00
Peter Johnson
36000ddb36
wpiutil: uv::Loop: Store the thread ID of the loop
2018-10-05 13:32:51 -07:00
Peter Johnson
de6d6c9a5c
wpiutil: EventLoopRunner: Allow getting the loop shared_ptr.
2018-10-05 13:32:51 -07:00
Peter Johnson
6d99c0ac6c
wpiutil: EventLoopRunner: Remove extraneous wpi namespace qualifier
2018-10-05 13:32:51 -07:00
Peter Johnson
164e9a2c7d
wpiutil: uv::Work: Don't connect work and afterWork if they're null
2018-10-05 13:32:51 -07:00
Peter Johnson
f3fb95af70
wpiutil: uv::Tcp: Simplify reuse function
2018-10-05 13:32:51 -07:00
Peter Johnson
40a9fc44ff
wpiutil: uv::Poll: add reuse functionality
2018-10-05 13:32:51 -07:00
Thad House
f0ac048645
Remove pmd and checkstyle publishing from azure ( #1353 )
...
Bug in azure makes out of branch PRs fail
2018-10-05 10:20:20 -07:00