Skip to content

local_ip

Runs in the client Sends nothing to the robot

Return this computer's IP address on the route to the robot. It is the address of the network interface this connection uses, read from the connection itself, so it is right on a computer with several networks. It asks the robot nothing. rti_connect() has the robot send its state packets there when it is given no address. Behind a router that translates addresses (NAT), the robot sees another address.

Syntax

robot.local_ip()

Arguments

None.

Returns

str | None

This computer's IP address, for example "192.168.0.20"; None before connect() and after disconnect().

Examples

robot.local_ip()

See also