diff --git a/rq_hardware/thd_roboct/__init__.py b/rq_hardware/thd_roboct/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/rq_hardware/thd_roboct/thd_roboct_service.py b/rq_hardware/thd_roboct/thd_roboct_service.py new file mode 100644 index 0000000000000000000000000000000000000000..e864a4d3672c05a75888e54e6b848d69f20a6b18 --- /dev/null +++ b/rq_hardware/thd_roboct/thd_roboct_service.py @@ -0,0 +1,42 @@ + +import artistlib.hardware +from ..base_hardware_service import BaseHardwareInterfaceService, AquireProjection, ReachabilityCheck +from rq_controller.common import PyProjection + + +import ros2_numpy +import numpy as np +from pathlib import Path + +from sensor_msgs.msg import Image + +import rclpy + +class ThdRoboCTHardwareInterface(BaseHardwareInterfaceService): + + def __init__(self, node_name: str = 'rq_hardware_interface_service'): + + super().__init__(node_name) + + def aquire_projection_callback(self, + request: AquireProjection.Request, + response: AquireProjection.Response): + pass + + def check_reachability_callback(self, + request: ReachabilityCheck.Request, + response: ReachabilityCheck.Response): + pass + + +def main(args=None): + rclpy.init(args=args) + + minimal_service = ThdRoboCTHardwareInterface() + + rclpy.spin(minimal_service) + rclpy.shutdown() + + +if __name__ == '__main__': + main() diff --git a/setup.py b/setup.py index 34cf9a7af9a200af487277768fb564d8923e61f9..6d75e4b8e0de8fdd947010a9c288c24d8867dfe4 100644 --- a/setup.py +++ b/setup.py @@ -21,6 +21,7 @@ setup( entry_points={ 'console_scripts': [ 'service_artist = rq_hardware.artist.artist_harware_service:main', + 'service_thd_roboct = rq_hardware.thd_roboct.thd_roboct_service:main', 'client = rq_hardware.hardware_client:main' ], }, diff --git a/temp/projection.json b/temp/projection.json index 3ec8fd60c48ceaabc7d6167d4ca563cad26fa370..077514b6b802cfe2fe0e64c653db77895bd80590 100644 --- a/temp/projection.json +++ b/temp/projection.json @@ -1,7 +1,7 @@ { "focal_spot_position_mm": [ - 0.0, - 100.0, + -1.2246063538223773e-13, + -1000.0, 0.0 ], "focal_spot_orientation_matrix": [ @@ -22,20 +22,20 @@ ] ], "detector_center_position_mm": [ - 0.0, - -100.0, + 1.2246063538223773e-13, + 1000.0, 0.0 ], "detector_center_orientation_matrix": [ [ - 1.0, - 0.0, - 0.0 + -1.0, + -2.7191723402317286e-32, + 1.2246063538223773e-16 ], [ - 0.0, - 2.220446049250313e-16, - -1.0 + 1.2246063538223773e-16, + -2.220446049250313e-16, + 1.0 ], [ 0.0, @@ -44,10 +44,10 @@ ] ], "detector_center_orientation_quat": [ + 4.329637285359677e-17, 0.7071067811865475, - 0.0, - 0.0, - 0.7071067811865477 + 0.7071067811865477, + 4.3296372853596783e-17 ], "detector_count_px": [ 1000, diff --git a/temp/projection.tif b/temp/projection.tif index fa4072fce9863124ceeb02f4332f4441ad9c969c..90e8c45029ae760d7c07855f4f2b7031d5b5aac0 100644 Binary files a/temp/projection.tif and b/temp/projection.tif differ