Explorar el Código

redis key调整

psto hace 2 años
padre
commit
b1aed9b78d
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      get_opc_data.py

+ 1 - 1
get_opc_data.py

@@ -43,7 +43,7 @@ async def get_opc_data(sys_url, point_arr, ns=2):
                     tag = client.get_node(node)
                     value = await tag.read_value()
                     # redis值
-                    redis_conn.set(str(node), str(value))
+                    redis_conn.set(str(point_arr[i]), str(value))
                     arr_key = node.split("=")
                     result_arr[arr_key[2]] = value
                 finally: