peer_to_peer.py
# Questo lavoro è concesso in licenza MIT.
# Copyright (c) 2013-2023 OpenMV LLC. Tutti i diritti riservati.
# https://github.com/openmv/openmv/blob/master/LICENSE
#
# Esempio Ethernet LAN Peer to Peer.
# Sul PC prova quanto segue:
#
# $> sudo ifconfig eth0 192.168.1.100 up
# $> ping 192.168.1.102
import network
import time
lan = network.LAN()
lan.active(True)
lan.ifconfig(("192.168.1.102", "255.255.255.0", "192.168.1.1", "192.168.1.1"))
while True:
# Nient'altro da fare.
time.sleep(1.0)