How can I find device id and device name?

How can I find device id and device name?

What problem are you trying to solve?