Commit Graph

1543 Commits

Author SHA1 Message Date
Chris Gerth
851f2e4e68 Update Python rawBytes parsing (#1119)
*  data updates to capture multiple rawBytes packets associated with serde updates from late this past month

---------

Co-authored-by: Matt <matthew.morley.ca@gmail.com>
2024-01-06 06:17:06 -06:00
Matt
4068025572 Check all new prop names not just exposure time (#1080)
Fixes v4l renaming prop names and OV9281 exposure min/max being wrong by introducing new UI control
2024-01-05 23:40:06 -05:00
Craig Schardt
f37a0d0300 Add database migrations (fixes #1046) (#1065)
Add database version pragma to SQL database to automatically migrate between versions
2024-01-05 21:02:47 -05:00
Chris Gerth
276fc6178e Apparently we need to get better about longDescription? (#1117)
Maybe make pypi happy(ier)
v2024.1.1-beta-4.2
2024-01-05 18:03:55 -05:00
Chris Gerth
107a0f3a8b code checkout fixups (#1116) v2024.1.1-beta-4.1 2024-01-05 15:07:50 -06:00
Matt
0af5a62d5e Use mrcal for camera-calibration (#1036)
Uses jars built from https://github.com/photonvision/mrcal-java/
See: https://mrcal.secretsauce.net/ and https://docs.photonvision.org/en/latest/docs/calibration/calibration.html#investigating-calibration-data-with-mrcal

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
v2024.1.1-beta-4
2024-01-05 14:26:17 -05:00
Matt
b033f7e585 Publish API docs (#1094)
Redirects I want eventually ( @Bankst )

demo.photonvision.org redirected to https://photonvision.github.io/photonvision/built-client/
javadocs.photonvision.org redirected to https://photonvision.github.io/photonvision/built-docs/javadoc/
cppdocs.photonvision.org redirected to https://photonvision.github.io/photonvision/built-docs/doxygen/html/

For now this runs on all commits to master. Once we confirm it works, let's pull back to only tagged releases


---------

Co-authored-by: Mohammad Durrani <46766905+mdurrani808@users.noreply.github.com>
Co-authored-by: Chris <chrisgerth010592@gmail.com>
2024-01-05 14:14:22 -05:00
Programmers3539
4d9f2284da CSI Camera Timeout & Auto-Recreate (#1102)
Adds logic that will reset the CSI camera in the case that it doesn't receive any new frames from the camera in 3 seconds. This is very helpful for cases where the camera cable was bumped enough to cause a temporary disconnect. Most of the time (if not all the time) the camera needs to be recreated for it to start sending frames again.

Goes with PhotonVision/photon-libcamera-gl-driver#13
2024-01-05 09:27:12 -05:00
Sriman Achanta
d85bafa0eb fix naming (#1089) 2024-01-04 13:20:29 -05:00
Matt
cba70d47ff Use photon-image-modifier for Pi images (#1081)
Upgrades to Debian 12 as the base for our Pi images and adds an orange pi 5 build.

This uses the latest stable libcamera, which has weird AWB bugs with the OV5647/pi camera v1.
2024-01-04 09:57:45 -05:00
Paul Rensing
dcf01f8b9e Enable detecting generic Linux ARM32 in Platform enum (#1110) 2024-01-03 18:25:15 -07:00
Matt
395cafa31a Document out of source repos (#1109) 2024-01-03 19:23:59 -05:00
Matt
4f84f6e4f5 Fix getCalibrationCoeffs args in calibration info card 2024-01-03 15:23:39 -07:00
Matt
7f09f9e4f5 Save calibration data and show preliminary GUI (#1078)
* Serialize all calibration data

* Run lint

* typing nit

* fix code

* move these tables around some

* Add cool formatting

* add request to get snapshots by resolution and camera

* re-enable all resolutions

* add wip so i can change computers (SQUASH ME AND KILL ME AHHHH)

* Get everything working but viewing snapshots

* Update RequestHandler.java

* Update CameraCalibrationInfoCard.vue

* Update CameraCalibrationInfoCard.vue

* add observation viewer

* round

* fix illiegal import

* Swap to PNG and serialize insolution

* move import/export buttons TO THE TOP

* Update WebsocketDataTypes.ts

* Add snapshotname to observation

* Refactor to serialize snapshot image itself

* Run lint

* Use new base64 image data in info card

* Update SettingTypes.ts

* Create calibration json -> mrcal converter script

* Update calibrationUtils.py

* Fix calibrate NPEs in teest

* Run lint

* Always run cornersubpix

* Update CameraCalibrationInfoCard.vue

Update CameraCalibrationInfoCard.vue

* Update OpenCVHelp.java

* Update OpenCVHelp.java

* Replace test mode camera JSONs

* Run wpiformat

* Revert intrinsics but keep other data

* Remove misc comments

* Rename JsonMat->JsonImageMat and add calobject_warp

* Update Server.java

* Rename cameraExtrinsics to distCoeffs

* fix typing issues

* use util methods

* Formatting fixes

* fix styling

* move to devTools

* remove unneeded or unused imports

* Remove fixed-right css

If its really that big of a deal, we can add it back later, kind of a drag to fix rn.

* Create util method

* Remove extra legacy calibration things

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2024-01-03 16:32:04 -05:00
Programmers3539
e685334baa Fix grayscale passthrough (#1083)
Fix grayscale passthrough with libcamera. Additionally fixes issue #1091.

Must go with PhotonVision/photon-libcamera-gl-driver#11.

When grayscale passthrough is used currently the frames that are returned do not have the type grayscale so calculations that need grayscale to not run. With these changes pipelines that need grayscale will now run and properly display fps.
2024-01-02 23:35:24 -05:00
Programmers3539
341954c1eb Libcamera JNI Maven Support (#1105)
Download our libcamera JNI from Maven <3
2024-01-02 11:04:58 -07:00
Sriman Achanta
e4f475a253 Improve UI stability, reliability, and readability (#1104)
closes #1090
closes #1030

Also fixes various styling issues and overflow issues for mobile support
2024-01-02 09:03:16 -07:00
Programmers3539
2a1792e71a Allow 90-deg rotation of USB cameras on Pi (#1103)
UI would say that every camera on a Pi device was a CSI camera basically. It would not let you rotate usb cameras 90 degrees or 270 degrees because it thought that they were CSI cameras. Fixes: #1098
2024-01-02 10:27:09 -05:00
Drew Williams
96de176ba2 Changes sim to use 36h11 tags (#1056)
Fixes #1041

---------

Co-authored-by: Drew Williams <DrewW@iARx.com>
Co-authored-by: Matt <matthew.morley.ca@gmail.com>
2024-01-02 08:09:32 -07:00
Chris Gerth
b9c2d839f4 Update big friendly warning to look better. (#1101)
The driver station supports neither monospace fonts nor unicode, so we can't be as... ummm... artistic... with what we put there.
2024-01-01 17:30:57 -05:00
Tyler Veness
f9437123b4 Remove redundant parts of bfw string declaration (#1100) 2024-01-01 16:31:23 -05:00
Paul Rensing
54840f0420 Fix typo in systemd parameter (#1099) 2024-01-01 12:51:02 -05:00
Programmers3539
a9f1e50a19 Fix Driver Mode Rotation (#1097)
Demoves duplicate image rotation. Frames are rotated from the frame source provided. Then were rotated again in the driver mode pipeline.
2023-12-31 22:07:07 -05:00
Sriman Achanta
2ecd988628 Add protobuf publish setting slider (#1075)
Allows logging software and live data view to see results. Also removes the requirement for AScope to keep up with the packet serde schema and instead just use the Protobuf descriptor.
2023-12-31 00:14:21 -05:00
Chris Gerth
e3eff8731f Version mismatch is harder to miss. (#1088) 2023-12-30 15:34:52 -05:00
Chris Gerth
ef039da728 Uploaded .json settings bug fixups (#1082)
Resolved race condition between saveGlobal and saveOneFile modifying settings on shutdown. Previously, saveGlobal would overwrite the action of saveOneFile on a clean shutdown.
2023-12-28 23:36:15 -05:00
Chris Gerth
ece521c9e1 Status leds round2 (#1076)
Continuation of #802

Support RGB status LED to indicate:

Running/no-running
NT connected
At least one target visible

Configured by manually uploading hardware config JSON
2023-12-28 14:24:28 -05:00
Matt
282e1bb47d Handle angle wrapping (#1061) 2023-12-28 12:40:50 -05:00
Matt
7b8326beb1 Use exposure_time_absolute if present (#1079) 2023-12-28 10:42:52 -05:00
Sriman Achanta
ebac32cba6 Always encode transform (#1074) 2023-12-27 10:38:41 -05:00
Programmers3539
0b98f02731 Enable multi-CSI-camera with libcamera (#1068)
We should continue being paranoid about multi-cam with all these changes


---------

Co-authored-by: Matt <matthew.morley.ca@gmail.com>
2023-12-24 21:05:11 -05:00
Sriman Achanta
5be9b8be2c Add PacketSerde interface and expand PacketUtils for more wpimath classes (#1058)
Follows a similar system to the current Protobuf implementation that helps make code more readable and expandable. Also wraps the NT topic to be more useful. Impl stuff is hidden so it can't be extended. Optimizes AT-specific classes by only serializing data when needed, won't save on size but will on time.

closes #1003
2023-12-24 19:56:08 -05:00
Matt
0356eeeb50 Install script use Java 17 2023-12-19 19:38:55 -05:00
Matt
954ca9a577 Record standard deviations for multi-tag pose (#1019)
* Record standard deviations for multi-tag pose

* Add XYZ translation and angle to stdev uI

* create multitag result buffer in store

allows results to be stored in the background

* simplify logic in targeting tab

also adds a reset button

* Formatting fixes

* convert rad angles to deg

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2023-12-19 15:47:53 -05:00
Craig Schardt
796b8e73d5 Fix Logger - ConfigManager circular reference (#1054) 2023-12-18 12:59:14 -05:00
Craig Schardt
36ba8b5263 JSONAlias on old tag type enum names (#1055)
add aliases for older enum names

* two more aliases for 6.5" 36h11 tags

* added unit test for missing @JsonAlias

* use proper tempfiles

* check proper TargetModel enum
2023-12-18 12:42:43 -05:00
Chris Gerth
f7f304ca7a fix bad implementation of global variables and version check, which prevented python version checks from working (#1050) 2023-12-17 08:27:41 -05:00
Programmers3539
82b82fe2f6 Raspberry Pi 5 Support (#1008)
Deals with new otherpaths on pi 5 CSI cameras and bumps libcamera driver to latest from the pi 5 PR

---------

Co-authored-by: Matt <matthew.morley.ca@gmail.com>
2023-12-16 16:11:55 -05:00
Sriman Achanta
6b8882fe53 Report cpp usage (#1045) 2023-12-16 15:26:00 -05:00
Drew Williams
cba4db0bce Update C++ Simulation to match Java (#1026) 2023-12-16 13:41:27 -05:00
Chris Gerth
47aea29b6b Add photonlibpy (#1040)
* Added a pure-python implementation of photonlib, named photonlibpy and hosted on pypi

---------

Co-authored-by: Matt <matthew.morley.ca@gmail.com>
2023-12-16 12:32:49 -06:00
Sriman Achanta
2e39549771 Bump wpilib to 2024-beta-4 and report resource photon usage ids from 2024v2 image (#1042) 2023-12-16 13:14:52 -05:00
Sriman Achanta
3de878c510 update download all artifacts (#1044)
* Update build.yml

* Update build.yml
2023-12-16 13:00:02 -05:00
Sriman Achanta
d67b665407 Update upload/download artifact action (#1043) 2023-12-16 11:44:16 -05:00
Joseph Farkas
6db5bc5e0c Matching cameras by path ID (#1015)
Allows multiple cameras of the same model to be used while ensuring they stay tied to the physical camera and not the port. Matching occurs when first connecting cameras so swapping the ports while PV is running will swap the virtual cameras until a restart. Currently only tested on Linux.
2023-12-04 11:55:16 -05:00
Programmers3539
469bc0eeae Fix Camera Index Assignment. (#1031)
Fixes a bug where multiple cameras would receive identical stream indexes and would cause at least one camera to not function at all and the other to not display a stream.

One of the reasons the that usbcamerasource equals method used to incorrectly determine equality was because the quirkycamera object didn't have a basename. When a camera that had a quirk was found it would set equal to a predefined quirkycamera without changing the name first. Add unit test that will better test the equality of two usbcamerasources. This required a few changes to allow creating a fake usbcamerasource.
2023-12-01 07:58:38 -05:00
Sriman Achanta
f597d111b3 Update bug issue template with UI specific comment (#1033)
* Update bug_report.md

* Update bug_report.md
2023-11-29 18:32:04 -05:00
Joseph Farkas
7b49570e9d Radians to Degrees for multi-tag pose (#1027)
* Radians to Degrees for multi-tag pose

* fix optional check

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2023-11-27 23:43:57 -05:00
Matt
16f63e4d90 Remove % from ambiguity (#1017)
* Remove % from ambiguity

* Update javadocs

---------

Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com>
2023-11-25 14:06:22 -05:00
Matt
3268e0d689 Add pi5 to pi version enum (#1023)
---------

Co-authored-by: Technologyman00 <collinost@gmail.com>
2023-11-22 20:25:43 -05:00