dexcontrol 0.2.1__py3-none-any.whl → 0.2.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of dexcontrol might be problematic. Click here for more details.

Files changed (81) hide show
  1. dexcontrol/__init__.py +14 -3
  2. dexcontrol/apps/dualsense_teleop_base.py +16 -11
  3. dexcontrol/config/__init__.py +10 -5
  4. dexcontrol/config/core/__init__.py +8 -3
  5. dexcontrol/config/core/arm.py +8 -3
  6. dexcontrol/config/core/chassis.py +10 -5
  7. dexcontrol/config/core/hand.py +14 -9
  8. dexcontrol/config/core/head.py +8 -3
  9. dexcontrol/config/core/misc.py +8 -3
  10. dexcontrol/config/core/torso.py +8 -3
  11. dexcontrol/config/sensors/__init__.py +8 -3
  12. dexcontrol/config/sensors/cameras/__init__.py +9 -4
  13. dexcontrol/config/sensors/cameras/rgb_camera.py +18 -5
  14. dexcontrol/config/sensors/cameras/zed_camera.py +36 -0
  15. dexcontrol/config/sensors/imu/__init__.py +10 -5
  16. dexcontrol/config/sensors/imu/chassis_imu.py +21 -0
  17. dexcontrol/config/sensors/imu/zed_imu.py +21 -0
  18. dexcontrol/config/sensors/lidar/__init__.py +8 -3
  19. dexcontrol/config/sensors/lidar/rplidar.py +9 -3
  20. dexcontrol/config/sensors/ultrasonic/__init__.py +8 -3
  21. dexcontrol/config/sensors/ultrasonic/ultrasonic.py +9 -3
  22. dexcontrol/config/sensors/vega_sensors.py +34 -21
  23. dexcontrol/config/vega.py +14 -6
  24. dexcontrol/core/__init__.py +9 -0
  25. dexcontrol/core/arm.py +21 -6
  26. dexcontrol/core/chassis.py +8 -3
  27. dexcontrol/core/component.py +26 -6
  28. dexcontrol/core/hand.py +8 -3
  29. dexcontrol/core/head.py +18 -3
  30. dexcontrol/core/misc.py +94 -16
  31. dexcontrol/core/torso.py +8 -3
  32. dexcontrol/proto/dexcontrol_msg_pb2.py +17 -15
  33. dexcontrol/proto/dexcontrol_msg_pb2.pyi +24 -0
  34. dexcontrol/robot.py +82 -28
  35. dexcontrol/sensors/__init__.py +13 -8
  36. dexcontrol/sensors/camera/__init__.py +11 -6
  37. dexcontrol/sensors/camera/rgb_camera.py +33 -24
  38. dexcontrol/sensors/camera/zed_camera.py +364 -0
  39. dexcontrol/sensors/imu/__init__.py +13 -8
  40. dexcontrol/sensors/imu/chassis_imu.py +155 -0
  41. dexcontrol/sensors/imu/{nine_axis_imu.py → zed_imu.py} +41 -26
  42. dexcontrol/sensors/lidar/__init__.py +11 -1
  43. dexcontrol/sensors/lidar/rplidar.py +8 -3
  44. dexcontrol/sensors/manager.py +22 -9
  45. dexcontrol/sensors/ultrasonic.py +8 -3
  46. dexcontrol/utils/__init__.py +8 -3
  47. dexcontrol/utils/constants.py +10 -0
  48. dexcontrol/utils/io_utils.py +8 -3
  49. dexcontrol/utils/motion_utils.py +8 -3
  50. dexcontrol/utils/os_utils.py +23 -4
  51. dexcontrol/utils/pb_utils.py +8 -3
  52. dexcontrol/utils/rate_limiter.py +8 -3
  53. dexcontrol/utils/rtc_utils.py +144 -0
  54. dexcontrol/utils/subscribers/__init__.py +11 -3
  55. dexcontrol/utils/subscribers/base.py +26 -5
  56. dexcontrol/utils/subscribers/camera.py +10 -6
  57. dexcontrol/utils/subscribers/decoders.py +8 -3
  58. dexcontrol/utils/subscribers/generic.py +8 -3
  59. dexcontrol/utils/subscribers/imu.py +8 -3
  60. dexcontrol/utils/subscribers/lidar.py +8 -3
  61. dexcontrol/utils/subscribers/protobuf.py +8 -3
  62. dexcontrol/utils/subscribers/rtc.py +315 -0
  63. dexcontrol/utils/timer.py +8 -3
  64. dexcontrol/utils/trajectory_utils.py +8 -3
  65. dexcontrol/utils/viz_utils.py +8 -3
  66. dexcontrol/utils/zenoh_utils.py +83 -0
  67. dexcontrol-0.2.3.dist-info/METADATA +265 -0
  68. dexcontrol-0.2.3.dist-info/RECORD +72 -0
  69. {dexcontrol-0.2.1.dist-info → dexcontrol-0.2.3.dist-info}/WHEEL +1 -2
  70. dexcontrol-0.2.3.dist-info/licenses/LICENSE +184 -0
  71. dexcontrol/config/sensors/cameras/gemini_camera.py +0 -16
  72. dexcontrol/config/sensors/imu/gemini_imu.py +0 -15
  73. dexcontrol/config/sensors/imu/nine_axis_imu.py +0 -15
  74. dexcontrol/sensors/camera/gemini_camera.py +0 -139
  75. dexcontrol/sensors/imu/gemini_imu.py +0 -139
  76. dexcontrol/utils/reset_orbbec_camera_usb.py +0 -98
  77. dexcontrol-0.2.1.dist-info/METADATA +0 -369
  78. dexcontrol-0.2.1.dist-info/RECORD +0 -72
  79. dexcontrol-0.2.1.dist-info/licenses/LICENSE +0 -188
  80. dexcontrol-0.2.1.dist-info/licenses/NOTICE +0 -13
  81. dexcontrol-0.2.1.dist-info/top_level.txt +0 -1
dexcontrol/__init__.py CHANGED
@@ -1,7 +1,13 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
10
+ # See README.md for details
5
11
 
6
12
  """DexControl: Robot Control Interface Library.
7
13
 
@@ -15,6 +21,9 @@ import os
15
21
  from pathlib import Path
16
22
  from typing import Final
17
23
 
24
+ from loguru import logger
25
+ from rich.logging import RichHandler
26
+
18
27
  # DO NOT REMOVE this following import, it is needed for hydra to find the config
19
28
  import dexcontrol.config # pylint: disable=unused-import
20
29
  from dexcontrol.robot import Robot
@@ -24,6 +33,8 @@ from dexcontrol.utils.constants import COMM_CFG_PATH_ENV_VAR
24
33
  LIB_PATH: Final[Path] = Path(__file__).resolve().parent
25
34
  CFG_PATH: Final[Path] = LIB_PATH / "config"
26
35
 
36
+ logger.configure(handlers=[{"sink": RichHandler(markup=True), "format": "{message}"}])
37
+
27
38
 
28
39
  def get_comm_cfg_path() -> Path:
29
40
  default_path = list(
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  """DualSense controller teleoperation base module.
7
12
 
@@ -10,9 +15,9 @@ with safety features, emergency stop handling, and customizable control mappings
10
15
  """
11
16
 
12
17
  import threading
18
+ import time
13
19
  from abc import ABC, abstractmethod
14
20
  from enum import Enum
15
- import time
16
21
 
17
22
  from dualsense_controller import DualSenseController
18
23
  from loguru import logger
@@ -31,10 +36,10 @@ class ControlMode(Enum):
31
36
 
32
37
  class ButtonState:
33
38
  """Class to track button state with debouncing."""
34
-
39
+
35
40
  def __init__(self, debounce_time: float = 0.05):
36
41
  """Initialize button state.
37
-
42
+
38
43
  Args:
39
44
  debounce_time: Time in seconds to wait before considering a state change valid.
40
45
  """
@@ -43,10 +48,10 @@ class ButtonState:
43
48
  self._last_change_time = 0.0
44
49
  self._debounce_time = debounce_time
45
50
  self._lock = threading.Lock()
46
-
51
+
47
52
  def update(self, new_state: bool) -> None:
48
53
  """Update the button state with debouncing.
49
-
54
+
50
55
  Args:
51
56
  new_state: New raw button state.
52
57
  """
@@ -55,11 +60,11 @@ class ButtonState:
55
60
  if new_state != self._raw_state:
56
61
  self._last_change_time = current_time
57
62
  self._raw_state = new_state
58
-
63
+
59
64
  # Only update debounced state if enough time has passed
60
65
  if current_time - self._last_change_time >= self._debounce_time:
61
66
  self._debounced_state = self._raw_state
62
-
67
+
63
68
  @property
64
69
  def state(self) -> bool:
65
70
  """Get the current debounced button state."""
@@ -189,7 +194,7 @@ class DualSenseTeleopBase(ABC):
189
194
 
190
195
  def _update_button_state(self, button: str, state: bool) -> None:
191
196
  """Update the state of a button with debouncing.
192
-
197
+
193
198
  Args:
194
199
  button: Name of the button being updated.
195
200
  state: New raw button state.
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from hydra.core.config_store import ConfigStore
7
12
 
@@ -10,5 +15,5 @@ from .vega import Vega1Config, VegaConfig
10
15
  # Register the configs
11
16
  cs = ConfigStore.instance()
12
17
  cs.store(name="vega", node=VegaConfig)
13
- cs.store(name="vega_rc2", node=VegaConfig)
14
- cs.store(name="vega_1", node=Vega1Config)
18
+ cs.store(name="vega-rc2", node=VegaConfig)
19
+ cs.store(name="vega-1", node=Vega1Config)
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from .arm import ArmConfig
7
12
  from .chassis import ChassisConfig
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from dataclasses import dataclass, field
7
12
 
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from dataclasses import dataclass, field
7
12
 
@@ -15,8 +20,8 @@ class ChassisConfig:
15
20
  center_to_wheel_axis_dist: float = (
16
21
  0.219 # the distance between base center and wheel axis in m
17
22
  )
18
- wheels_dist: float = 0.41 # the distance between two wheels in m (0.41 for vega_rc2, 0.45 for vega_1)
23
+ wheels_dist: float = 0.45 # the distance between two wheels in m (0.41 for vega-rc2, 0.45 for vega-1)
19
24
  joint_name: list[str] = field(
20
25
  default_factory=lambda: ["L_wheel_j1", "L_wheel_j2", "R_wheel_j1", "R_wheel_j2"]
21
26
  )
22
- max_vel: float = 0.6
27
+ max_vel: float = 0.8
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from dataclasses import dataclass, field
7
12
 
@@ -28,15 +33,15 @@ class HandConfig:
28
33
  default_factory=lambda: ["th_j1", "ff_j1", "mf_j1", "rf_j1", "lf_j1", "th_j0"]
29
34
  )
30
35
  joint_pos_open: list[float] = field(
31
- default_factory=lambda: [0.18313, 0.29012, 0.28084, 0.28498, 0.28204, -0.034]
36
+ default_factory=lambda: [0.1834, 0.2891, 0.2801, 0.284, 0.2811, -0.0158]
32
37
  )
33
38
  joint_pos_close: list[float] = field(
34
39
  default_factory=lambda: [
35
- -0.64862,
36
- -1.17584,
37
- -1.16855,
38
- -1.17493,
39
- -1.17277,
40
+ -0.3468,
41
+ -1.0946,
42
+ -1.0844,
43
+ -1.0154,
44
+ -1.0118,
40
45
  1.6,
41
46
  ]
42
47
  )
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from dataclasses import dataclass, field
7
12
 
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  """Miscellaneous robot component configurations."""
7
12
 
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from dataclasses import dataclass, field
7
12
 
@@ -1,4 +1,9 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
- from .gemini_camera import GeminiCameraConfig
7
11
  from .rgb_camera import RGBCameraConfig
12
+ from .zed_camera import ZedCameraConfig
@@ -1,15 +1,28 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
- from dataclasses import dataclass
11
+ from dataclasses import dataclass, field
7
12
 
8
13
 
9
14
  @dataclass
10
15
  class RGBCameraConfig:
11
16
  _target_: str = "dexcontrol.sensors.camera.rgb_camera.RGBCameraSensor"
12
- topic: str = "/camera/rgb"
13
17
  name: str = "rgb_camera"
14
18
  enable_fps_tracking: bool = False
15
19
  fps_log_interval: int = 30
20
+ enable: bool = False
21
+ subscriber_config: dict = field(
22
+ default_factory=lambda: dict(
23
+ rgb=dict(
24
+ enable=True,
25
+ info_key="camera/rgb/info",
26
+ )
27
+ )
28
+ )
@@ -0,0 +1,36 @@
1
+ # Copyright (C) 2025 Dexmate Inc.
2
+ #
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
10
+
11
+ from dataclasses import dataclass, field
12
+
13
+
14
+ @dataclass
15
+ class ZedCameraConfig:
16
+ _target_: str = "dexcontrol.sensors.camera.zed_camera.ZedCameraSensor"
17
+ name: str = "zed_camera"
18
+ enable_fps_tracking: bool = False
19
+ fps_log_interval: int = 30
20
+ enable: bool = False
21
+ subscriber_config: dict = field(
22
+ default_factory=lambda: dict(
23
+ left_rgb=dict(
24
+ enable=True,
25
+ info_key="camera/head/left_rgb/info",
26
+ ),
27
+ right_rgb=dict(
28
+ enable=True,
29
+ info_key="camera/head/right_rgb/info",
30
+ ),
31
+ depth=dict(
32
+ enable=True,
33
+ topic="camera/head/depth",
34
+ ),
35
+ )
36
+ )
@@ -1,6 +1,11 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
5
- from .gemini_imu import GeminiIMUConfig
6
- from .nine_axis_imu import NineAxisIMUConfig
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
10
+ from .chassis_imu import ChassisIMUConfig
11
+ from .zed_imu import ZedIMUConfig
@@ -0,0 +1,21 @@
1
+ # Copyright (C) 2025 Dexmate Inc.
2
+ #
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
10
+
11
+ from dataclasses import dataclass
12
+
13
+
14
+ @dataclass
15
+ class ChassisIMUConfig:
16
+ _target_: str = "dexcontrol.sensors.imu.chassis_imu.ChassisIMUSensor"
17
+ topic: str = "state/chassis_imu"
18
+ name: str = "chassis_imu"
19
+ enable_fps_tracking: bool = False
20
+ fps_log_interval: int = 30
21
+ enable: bool = False
@@ -0,0 +1,21 @@
1
+ # Copyright (C) 2025 Dexmate Inc.
2
+ #
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
10
+
11
+ from dataclasses import dataclass
12
+
13
+
14
+ @dataclass
15
+ class ZedIMUConfig:
16
+ _target_: str = "dexcontrol.sensors.imu.zed_imu.ZedIMUSensor"
17
+ topic: str = "/imu/head_camera"
18
+ name: str = "head_camera_imu"
19
+ enable_fps_tracking: bool = False
20
+ fps_log_interval: int = 30
21
+ enable: bool = False
@@ -1,6 +1,11 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from .rplidar import RPLidarConfig
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from dataclasses import dataclass
7
12
 
@@ -13,3 +18,4 @@ class RPLidarConfig:
13
18
  name: str = "rplidar"
14
19
  enable_fps_tracking: bool = False
15
20
  fps_log_interval: int = 30
21
+ enable: bool = False
@@ -1,6 +1,11 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from .ultrasonic import UltraSonicConfig
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from dataclasses import dataclass
7
12
 
@@ -13,3 +18,4 @@ class UltraSonicConfig:
13
18
  name: str = "ultrasonic"
14
19
  enable_fps_tracking: bool = False
15
20
  fps_log_interval: int = 30
21
+ enable: bool = False
@@ -1,7 +1,12 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  """Configuration dataclass for Vega robot sensors.
7
12
 
@@ -13,24 +18,29 @@ LiDAR and ultrasonic sensors.
13
18
  from collections.abc import Callable
14
19
  from dataclasses import dataclass, field
15
20
 
16
- from .cameras import GeminiCameraConfig, RGBCameraConfig
17
- from .imu import GeminiIMUConfig, NineAxisIMUConfig
21
+ from .cameras import RGBCameraConfig, ZedCameraConfig
22
+ from .imu import ChassisIMUConfig, ZedIMUConfig
18
23
  from .lidar import RPLidarConfig
19
24
  from .ultrasonic import UltraSonicConfig
20
25
 
21
26
 
22
- def _make_rgb_camera(topic: str, name: str) -> Callable[[], RGBCameraConfig]:
27
+ def _make_rgb_camera(name: str) -> Callable[[], RGBCameraConfig]:
23
28
  """Helper function to create RGB camera config factory.
24
29
 
25
30
  Args:
26
- topic: Camera topic name
27
31
  name: Camera instance name
28
32
 
29
33
  Returns:
30
34
  Factory function that creates an RGBCameraConfig
31
35
  """
32
36
  return lambda: RGBCameraConfig(
33
- topic=f"camera/base/{topic}", name=f"base_{name}_camera"
37
+ subscriber_config=dict(
38
+ rgb=dict(
39
+ enable=True,
40
+ info_key=f"camera/base/{name}/rgb/info",
41
+ )
42
+ ),
43
+ name=f"base_{name}_camera",
34
44
  )
35
45
 
36
46
 
@@ -39,27 +49,30 @@ class VegaSensorsConfig:
39
49
  """Configuration for all sensors on the Vega robot.
40
50
 
41
51
  Contains default configurations for:
42
- - Head camera (Gemini)
52
+ - Head camera (Zed)
43
53
  - Base cameras (RGB) - left, right, front, back
44
- - IMUs - base (9-axis) and head (Gemini)
54
+ - IMUs - base and head (Zed)
45
55
  - LiDAR
46
56
  - Ultrasonic sensors
47
57
  """
48
58
 
49
- head_camera: GeminiCameraConfig = field(default_factory=GeminiCameraConfig)
50
- base_left_camera: RGBCameraConfig = field(
51
- default_factory=_make_rgb_camera("left", "left")
52
- )
59
+ head_camera: ZedCameraConfig = field(default_factory=ZedCameraConfig)
60
+ base_left_camera: RGBCameraConfig = field(default_factory=_make_rgb_camera("left"))
53
61
  base_right_camera: RGBCameraConfig = field(
54
- default_factory=_make_rgb_camera("right", "right")
62
+ default_factory=_make_rgb_camera("right")
55
63
  )
56
64
  base_front_camera: RGBCameraConfig = field(
57
- default_factory=_make_rgb_camera("front", "front")
65
+ default_factory=_make_rgb_camera("front")
58
66
  )
59
- base_back_camera: RGBCameraConfig = field(
60
- default_factory=_make_rgb_camera("back", "back")
61
- )
62
- base_imu: NineAxisIMUConfig = field(default_factory=NineAxisIMUConfig)
63
- head_imu: GeminiIMUConfig = field(default_factory=GeminiIMUConfig)
67
+ base_back_camera: RGBCameraConfig = field(default_factory=_make_rgb_camera("back"))
68
+ base_imu: ChassisIMUConfig = field(default_factory=ChassisIMUConfig)
69
+ head_imu: ZedIMUConfig = field(default_factory=ZedIMUConfig)
64
70
  lidar: RPLidarConfig = field(default_factory=RPLidarConfig)
65
71
  ultrasonic: UltraSonicConfig = field(default_factory=UltraSonicConfig)
72
+
73
+ def __post_init__(self) -> None:
74
+ self.head_camera.enable = False
75
+ self.base_left_camera.enable = False
76
+ self.base_right_camera.enable = False
77
+ self.base_front_camera.enable = False
78
+ self.base_back_camera.enable = False
dexcontrol/config/vega.py CHANGED
@@ -1,13 +1,20 @@
1
- # Copyright (c) 2025 Dexmate CORPORATION & AFFILIATES. All rights reserved.
1
+ # Copyright (C) 2025 Dexmate Inc.
2
2
  #
3
- # Licensed under the Apache License, Version 2.0 with Commons Clause License
4
- # Condition v1.0 [see LICENSE for details].
3
+ # This software is dual-licensed:
4
+ #
5
+ # 1. GNU Affero General Public License v3.0 (AGPL-3.0)
6
+ # See LICENSE-AGPL for details
7
+ #
8
+ # 2. Commercial License
9
+ # For commercial licensing terms, contact: contact@dexmate.ai
5
10
 
6
11
  from dataclasses import dataclass, field
7
12
  from typing import ClassVar
8
13
 
9
14
  from omegaconf import OmegaConf
10
15
 
16
+ from dexcontrol.utils.os_utils import get_robot_model
17
+
11
18
  from .core import (
12
19
  ArmConfig,
13
20
  BatteryConfig,
@@ -178,9 +185,10 @@ def get_vega_config(variant: str | None = None) -> VegaConfig:
178
185
  Returns:
179
186
  The configuration for the specified Vega robot variant as an OmegaConf object.
180
187
  """
181
- if variant is None or variant == "base":
182
- config_class = VegaConfig
183
- elif variant in VegaConfig._variants:
188
+ if variant is None:
189
+ variant = get_robot_model()
190
+
191
+ if variant in VegaConfig._variants:
184
192
  config_class = VegaConfig._variants[variant]
185
193
  else:
186
194
  raise ValueError(