@vflorio94 this error can happen frequently, it happens when the url is available, but the board doesn't accept connections. Or when the board is starting, it might take a few seconds to be able to connect to it. You don't have another connection to the board, right? (And I assume you have tried hard resetting, disconnecting power then trying again)
@manuelc1318 as I wrote, you can transmit data in both directions: write to a characteristic to send data from client to server, and either read from a characteristic or use notifications for data from server to client.
Thank you @jcaron, for the data consumption topic, you're right, I will check the requirements again. For the gateway, can you recommend us some low price, fair range LoraWAN gateways? Doesn't matter if they aren't battery powered. We can start from there.
Have you tried using something other than pymakr? maybe screen or minicom. Also its worth checking if your user has permissions for the serial port. The procedure to do this varies by linux distro but on most you can add your user to the dialout group and when you reboot that user will have permissions to use serial ports
@ahelllycan Using a serial terminal emulator program like picocom, minicom or screen, you can connect as many devices as you have available USB ports. Just open for each device a terminal window and start the serial terminal using the repective interface. The interfaces are called /dev/ttyUSB0, /dev/ttyUSB1, .... Example:
@soren said in Socket having to close and reopen:
You close socket on server side then you must close it also on client side(it is closed already but..)
Question is what problem do you have with the code?
Is it working, if yes, do you ask if there is some better way?
@panos29 It's more about the ADC range, which is about 0.07 - 1.1V for the reading between 0 and 4096. I assume you would always need some kind of pre-amplifier/buffer, at least to protect the esp32 against damage,, and if you do not need to take values at hight speed, you can always use averaging to reduce the noise.
The esp32 chip is told to have a built-in preamplifier, but that is not supported by Micropython, and I do not know whether it works.