Skip to content

Commit

Permalink
spelling mistake
Browse files Browse the repository at this point in the history
  • Loading branch information
Ishaan-Datta committed Nov 9, 2024
1 parent 1f1d601 commit ac7ec69
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 8 deletions.
5 changes: 1 addition & 4 deletions tools/utils/serial_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ def display_ports():
for port in ports:
print(port.device)

# /dev/ttyUSB0 for linux?

# /dev/ttyACM0 for vertical port
def connect(port):
ser = serial.Serial(port, 115200, timeout=1) # Adjust USB port as needed
while True:
Expand All @@ -22,7 +21,5 @@ def connect(port):
parser = argparse.ArgumentParser(description='Serial port communication')
parser.add_argument('--port', type=str, required=True, help='Serial port to connect to')
args = parser.parse_args()

display_ports()

connect(args.port)
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import time, os
import cv2
import serial # pip3 install pyserial
import serial
# import pycuda.driver as cuda
# from tracker import *
# depth point cloud here...
Expand Down Expand Up @@ -55,7 +55,7 @@ def __init__(self):
self.model = ModelInference()
self.bridge = CvBridge()
# Open serial port to Arduino
self.ser = serial.Serial('/dev/ttyUSB0', 115200, timeout=1) # Adjust USB port as needed
self.ser = serial.Serial('/dev/ttyACM0', 115200, timeout=1)
self.subscription = self.create_subscription(InferenceOutput, 'inference_out', self.inference_callback, 10)

# Create a timer that calls the listener_callback every second
Expand Down Expand Up @@ -87,7 +87,6 @@ def timer_callback(self):
self.ser.write(serialized_msg.encode())
self.get_logger().info(f'Sent to Arduino: {self.boxes_present}')


def main(args=None):
rclpy.init(args=args)
extermination_node = ExterminationNode()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def __init__(self):
self.declare_parameter('camera_side', 'left') # left, right
self.declare_parameter('shift_constant', 1)
self.declare_parameter('roi_dimensions', [0, 0, 100, 100])
self.declare_paramter('precision', 'fp32')
self.declare_parameter('precision', 'fp32')

self.frame_rate = self.get_parameter('frame_rate').get_parameter_value().integer_value
self.dimensions = tuple(self.get_parameter('model_dimensions').get_parameter_value().integer_array_value)
Expand Down

0 comments on commit ac7ec69

Please sign in to comment.