I just tested it on mobu 2020 and looks like my suggestion is wrong :(.
This code is creating device, but it doesn't get values from that config file:
viconStreamDevice = FBCreateObject( 'Browsing/Templates/Devices', 'Vicon Stream Device', 'Vicon Stream Device' )
FBSystem().Scene.Devices.append( viconStreamDevice )
Getting proper settings from file works only when device is dragged from browser.
I don't have experience in using devices by python...
Quick research on internet shows that others also have similar issue and your solution with merging fbx file is working: https://stackoverflow.com/questions/50497136/set-up-vicon-stream-device-via-python
BTW. there was some update of device functions in Mobu 2023, they even added some sample script showing how to setup Vicon Device. But I haven't tested it yet. If you have Mobu 2023 or later, maybe it would work.
https://help.autodesk.com/view/MOBPRO/2024/ENU/?guid=MotionBuilder_SDK_py_ref_classpyfbsdk_1_1_f_b_d...
# This example shows how to create a Vicon Stream Device (a third-party device), initialize it and add it to the scene:
# Create the Vicon Stream Device
viconStreamDevice = FBCreateObject( 'Browsing/Templates/Devices', 'Vicon Stream Device', 'Vicon Stream Device' )
if viconStreamDevice:
# Initialize the device
viconStreamDevice.DeviceOperation( kDeviceOperations.kOpInit )
# Import the device to the current file
FBSystem().Scene.Devices.append( viconStreamDevice )
print( 'Vicon Stream Device initialized and added to the scene' )
else:
print( 'Vicon Stream Device not found' )