Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rae files and map TVCalibrationSettings to sockets instead of camera names #50

Merged
merged 18 commits into from
Oct 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions batch/oak_d_lr.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
"imu": true,
"tv_calibration": {
"camera_settings": {
"left": {"isp_scale": [2,3]},
"right": {"isp_scale": [2,3]},
"center": {"isp_scale": [2,3]}
"CAM_B": {"isp_scale": [2,3]},
"CAM_C": {"isp_scale": [2,3]},
"CAM_A": {"isp_scale": [2,3]}
}
}
},
Expand Down
21 changes: 21 additions & 0 deletions batch/rae.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,31 @@
"options": {
"platform": "rvc3",
"bootloader": "poe",
"imu": true,
"environment": {
"flashing": "rvc3_develop",
"testing": "rvc3_develop",
"calibration": "rvc3_develop"
},
"tv_calibration": {
"camera_settings": {
"CAM_C": {
"exposure": [2200, 600]
},
"CAM_B": {
"exposure": [2200, 600]
},
"CAM_A": {
"exposure": [2200, 1000]
},
"CAM_D": {
"exposure": [2200, 1000]
},
"CAM_E":
{
"exposure": [2200, 1000]
}
}
}
},
"variants": [
Expand Down
19 changes: 17 additions & 2 deletions boards/RAE-A-B-C.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"board_config":
{
"name": "TOF-FFC",
"name": "RAE",
"revision": "R0M0E0",
"cameras":{
"CAM_A": {
Expand Down Expand Up @@ -36,10 +36,25 @@
}

},

"stereo_config":{
"left_cam": "CAM_C",
"right_cam": "CAM_B"
},
"imuExtrinsics":
{ "sensorName" : "BNO086",
"extrinsics": {
"to_cam": "CAM_C",
"specTranslation": {
"x": -1.51,
"y": 0,
"z": -7.3
},
"rotation":{
"r": 270,
"p": 180,
"y": 0
}
}
}
}
}
7 changes: 6 additions & 1 deletion boards_reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class CameraSettings(BaseModel):

class TVCalibrationSettings(BaseModel):
camera_settings: Dict[str, CameraSettings] = {}
""" Dictionary with camera names as keys and CameraSettings as values. Used to set
""" Dictionary with camera sockets as keys and CameraSettings as values. Used to set
camera settings (sharpness, exposure, ...) for TV calibration. """

n_charuco_markers_per_row: int = 19
Expand Down Expand Up @@ -115,9 +115,14 @@ class StereoConfig(BaseModel):
left_cam: str
right_cam: str

class ImuExtrinsics(BaseModel):
sensorName: str
extrinsics: Optional[Extrinsics] = None

class BoardConfig(BaseModel):
cameras: Dict[str, CameraInfo]
stereo_config: Optional[StereoConfig] = None
imuExtrinsics: Optional[ImuExtrinsics] = None

class VariantConfig(BaseModel):
id: str
Expand Down