Thanks.
The only connection to the outside world is a mobile broadband router (Huawei E5372). It’s plugged into the Pi and is a DHCP on 192.168.0.1. That has to be set up ‘manually’. The Pi is wired to a wireless access point which connects all other machines in the house on 192.168.1.0 network. They get to the internet through the Pi with some ip route and iptables lines in a start-up script on the Pi. It should have been more elegant to use connman’s tether function but as I said connman doesn’t recognise the wwan interface.
It all works (took some time!) so I don’t need any help with that. I was just trying to get rid of a couple of lines in my start-up script:
#! /bin/bash
# set up Huawei router on usb
if ! lsusb | grep "Modem/Networkcard"; then
# change mode to router
usb_modeswitch -v 12d1 -p 14fe -J
fi
# look for the router
if lsusb | grep "12d1:1506"; then
ip link set wwan0 up
dhclient wwan0
echo 1 > /proc/sys/net/ipv4/ip_forward
iptables -t nat -A POSTROUTING -o wwan0 -j MASQUERADE
# in case these have been created by connman
ip route delete 8.8.8.8
ip route delete 192.168.0.1
ip route change default via 192.168.0.1 dev wwan0
fi