08-19-2022 07:05 AM
@t.n14 wrote:
We have a testing PC with the same problem, we use ComPortMan, completly worth it.
You can define fixed ports for specific devices and ports for constantly switching devices to be a specific port.
Timo
Holy cow, I think this could solve some issues that I have as well.
08-22-2022 08:50 AM
I found this article that I thought could work, but unfortunately clearing the resources didn't change anything...
08-22-2022 09:03 AM
@nikvl wrote:
I found this article that I thought could work, but unfortunately clearing the resources didn't change anything...
That article is specifically for NI Serial devices (ie serial devices sold be NI). It will not apply to your device in question. Though, you may be able to use something like CCleaner to clear out the registry of unused ports (I have not specifically looks to see if this is done).
08-22-2022 09:15 AM
@crossrulz wrote:
@nikvl wrote:
I found this article that I thought could work, but unfortunately clearing the resources didn't change anything...
That article is specifically for NI Serial devices (ie serial devices sold be NI). It will not apply to your device in question. Though, you may be able to use something like CCleaner to clear out the registry of unused ports (I have not specifically looks to see if this is done).
That's unfortunate. Many of the suggestions require having to change the settings manually on the deployment PC, which is something I'd like to avoid. Honestly I didn't think it would be this complicated and imagined it possible because in another program we communicate with a Bronkhorst instrument to get a digital readout, and using their .exe requires you to set the COM port number first and it would only always initialize using that number and when it detects a different device from a previous time, a message pops up and asks if you want to override, but otherwise the COM port number stays the same.
08-23-2022 12:57 AM
@t.n14 wrote:
We have a testing PC with the same problem, we use ComPortMan, completly worth it.
You can define fixed ports for specific devices and ports for constantly switching devices to be a specific port.
Timo
Do you have set it once and then Windows remember the settings, or do you have to periodically check and and re-run the software? I assume one needs administrator rights to run it, and if it's just a single time during deployment that might be fine, but otherwise it might complicate maintenence.
08-24-2022 08:12 AM
08-24-2022 08:39 AM
Good job!
09-09-2022 08:23 AM
Hello,
Can you please explain your solution in detail and if possible share LabVIEW code or any script involved.
I'm also facing similar situation to yours and want to avoid different COM Port number assignments for devices of same types.
Thanks.
09-09-2022 09:08 AM - edited 09-09-2022 09:10 AM
09-12-2022 03:51 AM
@nikvl wrote:
First of all, a DISCLAIMER: This involves writing into your registry keys and requires administrator rights. If you choose to use this method and mess up, I and/or my employer will NOT be held responsible, so proceed at your own risk. Step 1: Go to your device manager and find the hardware-ID of your USB. If you get something like FTDIBUS\COMPORT&VID_0102&PID_5013, take note of the number eg. 01025013. That's your USB serial number Step 2: Open your notepad and type this script and save the file as a .reg data type: Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\UsbFlags] "IgnoreHWSerNumXXXXXXXX"=hex:01 Replace the "XXXXXXXX" with the number from Hardware-ID. I honestly don't know if the Registry Editor Version number is important or not. Step 3: Double-click your saved .reg data to run it as admin. If that doesn't work, manually open regedit as admin, click on import and choose the file you saved above. Edit: I'm not sure why my reply is a wall of text and not formatted, apologies.
Note that all these steps can be done from LabVIEW.
Depending on how often you need to do it, it might be worth a try.