Does anybody know if there is a response from the socket that was used to send data to Hologram?
That is, if I do the following, should I expect any response in result = lteSocket.recv(1024)
The reason I am asking is that the code does not run beyond this point and gets stuck on this recv as it waits for response and I wonder if I should expect any response at all… Interestingly enough this code worked with another (environmental) sensor…
Eventually I did set the socket timeout to 5 sec and therefore am now getting timeout exception - that makes me think that Hologram is not responding/acknowledging the sending and therefore I get nothing… (and I do see the data showing up minutes and hours later on Hologram as the result of my sending…) Anyway, I’d appreciate your responses…
message = ECG.GetData()
print("message: {} json string: {}".format(idx+1, message))
data = '{"k": "%s", "d": "%s", "t": "%s"}' % (DEVICE_KEY, message, TOPIC)
print("data: {}".format(data))
lteSocket.send(bytes(data, 'ascii'))
print("==== LTE Socket data sent")
utime.sleep(1)
try:
print('Reading response from socket...')
result = lteSocket.recv(1024) #.decode()
if (len(result) == 0):
print("==== LTE Socket: Received no response...")
else:
print("==== LTE Socket: Received result: {}".format(result))
EDIT:
No response here for couple of days, not the first time…No tech support, no community support, no data visualization and more importantly no socket response from the server…
What can I say? I give up…