Skip to content

Can't connect via TCP #83

@SantaSpeen

Description

@SantaSpeen

Can't connect via TCP
Tested at Linux and MacOS

TCP via meshcore-proxy

Code:

from meshcore import MeshCore, EventType

async def main():
    meshcore = await MeshCore.create_tcp("10.41.0.14", 5000, auto_reconnect=True, debug=True)
    if not meshcore:
        return

Log:

DEBUG:meshcore:connection established
INFO:meshcore:TCP Connection started
DEBUG:meshcore:Connected successfully: 10.41.0.14
DEBUG:meshcore:Sending appstart command
DEBUG:meshcore:Sending raw data: bytearray(b'\x01\x03      mccli')
DEBUG:meshcore:sending pkt : b'<\r\x00\x01\x03      mccli'
DEBUG:meshcore:Dispatching event: EventType.CONNECTED, {'connection_info': '10.41.0.14'}, {}
DEBUG:meshcore:data received
ERROR:meshcore:No response from meshcore node, disconnecting
DEBUG:meshcore:TCP Connection closed
DEBUG:meshcore:TCP server closed the connection

I launch meshcore-proxy via --log-events

(venv) root@rpi:~/mshc# meshcore-proxy --ble ?????? --log-events
INFO:meshcore_proxy.proxy:Starting MeshCore Proxy (BLE: ??????)...
INFO:meshcore_proxy.proxy:TCP server listening on ('0.0.0.0', 5000)
INFO:meshcore_proxy.proxy:Connecting to radio via BLE: ??????
INFO:meshcore:BLE pairing successful
INFO:meshcore:BLE Connection started
INFO:meshcore_proxy.proxy:Connected to radio: ??????
INFO:meshcore_proxy.proxy:Client connected: ('10.41.0.12', 63943)
-> CMD_APPSTART: version=3 | app=mccli
<- SELF_INFO: name=Sint | type=client | public_key=68664f1e3433... | tx_power=22 | freq_mhz=869.08 | bw_khz=62.50 | sf=8 | cr=8 | lat=00.0 | lon=00.0
INFO:meshcore_proxy.proxy:Client disconnected: ('10.41.0.12', 63943)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions