Is开发者_StackOverflow中文版 it at all possible to somehow include the FTDI driver in a py2exe installer? If not, are there any ways to combine the two together in one easy installer?
Include the FTDI driver folders in your distribution using py2exe's data_files option.
You can run code like this to make the drivers visible to your application even if they aren't installed in system32:
os.environ['PATH'] = '%s;%s' % (os.environ['PATH'], os.path.abspath('./driver/i386'))
os.environ['PATH'] = '%s;%s' % (os.environ['PATH'], os.path.abspath('./driver/amd64'))
Of course, once a device is plugged in, Windows will ask for a driver. At least you can point it to where your app is installed to find it.
 
         
                                         
                                         
                                         
                                        ![Interactive visualization of a graph in python [closed]](https://www.devze.com/res/2023/04-10/09/92d32fe8c0d22fb96bd6f6e8b7d1f457.gif) 
                                         
                                         
                                         
                                         加载中,请稍侯......
 加载中,请稍侯......
      
精彩评论