Skip to content

Commit

Permalink
Add the camera_info_url parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
civerachb-cpr committed Nov 15, 2024
1 parent 328343f commit a392a9d
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions clearpath_config/sensors/types/cameras.py
Original file line number Diff line number Diff line change
Expand Up @@ -954,6 +954,7 @@ class AxisCamera(BaseCamera):
TF_PREFIX = 'axis'

HOSTNAME = '192.168.10.0'
CAMERA_INFO_URL = ''

DOME_FIXED = 'dome_fixed'
DOME_PTZ = 'dome_ptz'
Expand Down Expand Up @@ -1014,6 +1015,7 @@ class ROS_PARAMETER_KEYS:

HOSTNAME = 'axis_camera.hostname'
HTTP_PORT = 'axis_camera.http_port'
CAMERA_INFO_URL = 'axis_camera.camera_info_url'

USERNAME = 'axis_camera.username'
PASSWORD = 'axis_camera.password'
Expand Down Expand Up @@ -1076,6 +1078,7 @@ def __init__(
username: str = USERNAME,
password: str = PASSWORD,
use_encrypted_password: bool = USE_ENCRYPTED_PASSWORD,
camera_info_url: str = CAMERA_INFO_URL,

camera_num: int = CAMERA_NUM,
width: int = WIDTH,
Expand Down Expand Up @@ -1127,6 +1130,7 @@ def __init__(

self.ROS_PARAMETER_KEYS.HOSTNAME: AxisCamera.hostname,
self.ROS_PARAMETER_KEYS.HTTP_PORT: AxisCamera.http_port,
self.ROS_PARAMETER_KEYS.CAMERA_INFO_URL: AxisCamera.camera_info_url,

self.ROS_PARAMETER_KEYS.USERNAME: AxisCamera.username,
self.ROS_PARAMETER_KEYS.PASSWORD: AxisCamera.password,
Expand Down Expand Up @@ -1193,6 +1197,7 @@ def __init__(
self.username = username
self.password = password
self.use_encrypted_password = use_encrypted_password
self.camera_info_url = camera_info_url

self.camera_num = camera_num
self.width = width
Expand Down Expand Up @@ -1269,6 +1274,14 @@ def http_port(self, port: int) -> None:
)
self._http_port = port

@property
def camera_info_url(self) -> str:
return self._camera_info_url

@camera_info_url.setter
def camera_info_url(self, url: str) -> None:
self._camera_info_url = url

@property
def username(self) -> str:
return self._username
Expand Down

0 comments on commit a392a9d

Please sign in to comment.