Em7455 modem qmi dual stack configuration

On Windows the em7455 modem automatically works for qmi and mbim dual stack.

I couldn't find a solution online for OpenWrt but after lots of trial and error I finally got it working with qmi:

modem: (power cycle the device to hard reset the modem after issuing these commands)

network: (EE UK 4G/5G sim card)
config interface 'wwan'
	option proto 'qmi'
	option device '/dev/cdc-wdm0'
	option apn 'everywhere'
	option auth 'none'
	option profile '2'
	option pdptype 'ipv4v6'
	option dhcp '1'
	option dhcpv6 '1'

firewall: (add 'wwan' to network list)
config zone
	option name 'wan'
	list network 'wan'
	list network 'wan6'
	list network 'wwan'
	option input 'REJECT'
	option output 'ACCEPT'
	option forward 'REJECT'
	option masq '1'
	option mtu_fix '1'

Some of the AT commands are password protected and require unlocking. Default unlock is AT!ENTERCND="A710".

AT!PCOFFEN=2 provides stability by preventing the modem from low power mode cycling.

My modem was USB dongle connected to a PC running a recent version of OpenWrt, snapshot r18795-c391dcdf86.

EDIT: I've just tried using my MC7304 modem and qmi dual stack is working using the above on 21.02.1 but it doesn't require AT!CUSTOM="IPV6ENABLE",1 and AT!UDUSBCOMP=6 switches to qmi mode.