# Connecting to Your Device

The MeshCore CLI (`meshcore-cli`) supports three connection methods. Choose the one that matches your hardware and situation.

## Serial (USB)

The most reliable method. Connect your device via USB and specify the serial port with `-s`:

```
meshcore-cli -s /dev/ttyUSB0
```

The serial port must be given explicitly with `-s` — it is not auto-detected. Use the port that matches your system:

```
meshcore-cli -s /dev/ttyUSB0   # Linux/macOS
meshcore-cli -s COM3           # Windows
```

If you need to set a non-default baud rate, pass it with `-b` (for example `-b 115200`). MeshCore serial consoles commonly run at **115200**, matching the firmware's default, but set it explicitly with `-b` if your connection fails.

## Bluetooth (BLE)

Connect wirelessly to a nearby device. BLE is the default transport — scan for devices and pick one with `-S`, or target a known device directly with `-a <address>` or `-d <name>`:

```
meshcore-cli -S                # scan and select a BLE device
meshcore-cli -a <ble-address>   # connect to a known device
```

If the device does not appear, ensure it is powered on and not already connected to the MeshCore app. A BLE companion connection is a single GATT link, so generally only one client can connect at a time.

## TCP (Wi-Fi / LAN)

Connect to a device that exposes a TCP interface (useful for remote administration of fixed nodes). Use `-t` for the host and `-p` for the port:

```
meshcore-cli -t 192.168.1.100 -p 5000
```

Replace the IP with the device's actual address. Port **5000** is the meshcore-cli TCP default.

## Verifying Connection

Once connected, run `infos` (shortcut `i`) to confirm the connection and see device details:

```
infos
```

The `infos` output includes the node's public key, node name, TX power, location (lat/lon), and radio configuration (frequency, bandwidth, spreading factor, coding rate). Firmware version is shown by the separate `ver` command, and battery/telemetry by `self_telemetry` (shortcut `t`).