I want to access Myrio USB port through network published shared variable in My PC.vi. Please guide me through this how can I create shared variables to access this port because I have to make installer of the application and it should in any computer without the need of Labview software.
You've already "decided" on how you are going to accomplish your goal without considering carefully what your goal is. I presume by the term "USB Port" you mean the port that connects the myRIO to a PC for programming (i.e. the port next to the Power connector, not the USB plug where you could connect a Flash drive).
All communication with the myRIO is through TCP/IP, whether through WiFi or through the USB 2.0 port at 172.22.11.2. As one who has used a myRIO as part of a LabVIEW Real-Time program, I would strongly advise against using Network Shared Variables for communication between Host and Target -- they have rarely worked robustly for me. I much prefer using Network Streams, which I use to send "messages" from Host to Target and from Target to Host, as well as having the Target stream data to the Host for display and storage.
I am using adapter for serial communication as I am working on DC motor driver which has RS-485 port so, I have plug USB-to-RS-485 converter and connect that adapter with myrio directly. Now I have to access that port in Localhost programing. before that deploying program in the myrio it works fine means the port is detecting but the question is how can I access that port in the LocalHost?
That’s NOT going to work. The USB port is a generic high speed communication interface. Network Shared variables are a low speed variable interface, It would be synonymous to trying to connect a river (your USB device) to a transport by courier with buckets.Complete impedance mismatch!
What you might be able to do is to make sure VISA server is installed on the myRIO and then configure in your host in NI Max a remote VISA connection to this. That way you should be able to access the VISA resources on the myRIO as remote VISA resources.