Connect android emulator to lan I try, to connect my android emulator (from sdk) to the lan via a network bridge and a tap interface and with the -qemu option. I need it to use multicast addresse in native library code for communication with IoT devices connected to the lan.

But depending the image version an achitecture (x86 or ARM) I have different behaviours.

For ARM image (Android 7.1.1 armeabi-v7a) the bridge work perfectly. Dhcp client work automaticly after boot time. I can ping the lan gateway, google ... and the multicasting work. But the nic add to the emulator is not present via ip link or ifconfig, it is hidden, and default route is not present !! strange thing. The emulator is no pingable from the outside.

For X86 image (Android 7.1.1 google_apis/x86), the bridge work perfectly. Dhcp client work and the guest nic is configured. I can ping the lan gateway, google ..., the multicasting work, and the nic is visible (eth1). But to ping the gateway or other host, I must use ping -I to specify the nic interface, the emulator use slirp network and it is not pingable from the outside.

It is possible to make the emulator pingable from the outside ?

It is possible to use ping in x86 emulator without to use -I option for ping ?

It is possible to see the network nic attach in the ARM emulator ?

thank for your help.
I think  that if you add the IP of the server on you LAN network that will  allow you to access it from the emulator.
So a fight with iptables is required in your case 

useful links https://developer.android.com/studio/run/emulator-networking.html

and there is a hole bunch of documentation of how to redirect network traffic to a new IP address using iptables

Good luck i hope my answer was useful!