On collision
Here is a easy fix
With Script
Nav mesh agents basics
Set up a fixed IP for your raspberry pi
A complete guide with pictures and code