diff --git a/devices/clients/sst_client.py b/devices/clients/sst_client.py index a53c849b26a18d4fcb35d7ee5518c17f365240ae..4692b5d071772dddd4d01849e15a747a4a682f6b 100644 --- a/devices/clients/sst_client.py +++ b/devices/clients/sst_client.py @@ -130,7 +130,7 @@ class UDP_Receiver(Thread): try: packet = [bytearray(self.buffersize)] self.sock.recvmsg_into(packet[0:self.buffersize]) - self.queue.put_nowait(packet) + self.queue.put(packet) except socket.timeout: pass @@ -159,8 +159,6 @@ class SST(Thread): self.streams.debug_stream("starting SST thread") while True: - - packet = self.queue.get() if packet is None: diff --git a/jupyter-notebooks/test_device.ipynb b/jupyter-notebooks/test_device.ipynb index 66d3a5f1057cb9051dce52325fb4fc73fb9d7005..b404b04c7717a607882884c56dfe446adecd7272 100644 --- a/jupyter-notebooks/test_device.ipynb +++ b/jupyter-notebooks/test_device.ipynb @@ -2,7 +2,7 @@ "cells": [ { "cell_type": "code", - "execution_count": 26, + "execution_count": 1, "id": "waiting-chance", "metadata": {}, "outputs": [], @@ -13,17 +13,17 @@ }, { "cell_type": "code", - "execution_count": 2, + "execution_count": 3, "id": "moving-alexandria", "metadata": {}, "outputs": [], "source": [ - "d=DeviceProxy(\"LTS/test_device/1\")" + "d=DeviceProxy(\"LTS/SST/1\")" ] }, { "cell_type": "code", - "execution_count": 27, + "execution_count": 4, "id": "ranking-aluminum", "metadata": {}, "outputs": [ @@ -51,7 +51,7 @@ }, { "cell_type": "code", - "execution_count": 31, + "execution_count": 8, "id": "beneficial-evidence", "metadata": {}, "outputs": [ @@ -59,36 +59,10 @@ "name": "stdout", "output_type": "stream", "text": [ - "bool_scalar_R [False]\n", - "bool_scalar_RW [False]\n", - "int64_spectrum_R [0 0 0 0 0 0 0 0]\n", - "str_spectrum_RW ('', '', '', '', '', '', '', '')\n", - "double_image_R [[0. 0.]\n", - " [0. 0.]\n", - " [0. 0.]\n", - " [0. 0.]\n", - " [0. 0.]\n", - " [0. 0.]\n", - " [0. 0.]\n", - " [0. 0.]]\n", - "double_image_RW [[0. 0. 0. 0. 0. 0. 0. 0.]\n", - " [0. 0. 0. 0. 0. 0. 0. 0.]]\n", - "int32_scalar_R [0]\n", - "uint16_spectrum_RW [0 0 0 0 0 0 0 0]\n", - "float32_image_R [[0. 0. 0. 0. 0. 0. 0. 0.]\n", - " [0. 0. 0. 0. 0. 0. 0. 0.]]\n", - "uint8_image_RW [[0 0]\n", - " [0 0]\n", - " [0 0]\n", - " [0 0]\n", - " [0 0]\n", - " [0 0]\n", - " [0 0]\n", - " [0 0]]\n", - "tr_tod_R [0]\n", - "tr_uptime_R [0]\n", - "State <function __get_command_func.<locals>.f at 0x7f1c88a29e18>\n", - "Status <function __get_command_func.<locals>.f at 0x7f1c88a5abf8>\n" + "packet_count_R [80]\n", + "last_packet_timestamp_R [1623239037]\n", + "State <function __get_command_func.<locals>.f at 0x7fcb20e510d0>\n", + "Status <function __get_command_func.<locals>.f at 0x7fcb20e510d0>\n" ] } ],