You are running the 4.4.38 kernel, so your Raspbian OS is up to date, which is good.
Your '/boot/cmdline.txt' file looks good.
Your '/boot/config.txt' contains one instance of "enable_uart=1", which is also good.
Your '/boot/config.txt' file also contains the entry "dtoverlay=pi3-miniuart-bt". Do you really need this? It is not necessary to get a Serial Port working on a Pi 3B!
Unless you really really need to use the '/dev/ttyAMA0' UART instead of the '/dev/ttyS0' UART, I would recommend that you remove this line from '/boot/config.txt', reboot your Pi, and try again.
sachin221199 wrote:from systemctl stopped S0 and disabled S0;
and from systemctl enabled AMA0 as well;
I do not know what commands you issued to do this, but it is not necessary to issue any Systemd commands to get the Serial Port working, so I suggest you undo all of these commands. You may also need a reboot after this.
You should refer to your Serial Port as "/dev/serial0", that's serialZero, not serialOh, instead of using the 'ttyAMA0' or 'ttyS0'. By using 'serial0', you will always get connected to the 'users Serial Port' regardless of which UART is being used, and your code and settings should work correctly in future software or hardware upgrades for the RaspberryPi.
If, when you get this working, you plan on connecting the Pi's Serial Port to another device or computer, you should be aware that the Port works at 3.3V. It cannot handle the 5V from a TTL Serial Port, or the full RS232 signal voltages. Anything more then 3.3V on the Pi's Serial Port pins can destroy the Pi. Serial Port Level Converters are available if you need them, and Google should be able to find them for you.
If you really must use "dtoverlay=pi3-miniuart-bt", then you also need to add the line "core_freq=250" to '/boot/config.txt'.
I'm not sure where the log-in message shown in your screen shots is coming from. With your version of '/boot/cmdline.txt' and the Serial Port pins connected together for a loopback test, you should not see this unless you have used Systemd to enable a getty on the Serial Port. You may have done this inadvertently as part of 'enabling AMA0 with Systemd' as per your above quote. If you have, undo it, at least until you get the rest working.