Device driver conflict
Unplug your scanner / D40
Use USB device view click here to uninstall (removes from registry which normal uninstalling in device manager does not do) ALL devices that are shown as NOT connected
Reboot the PC
reconnect the device and windows will find and install new hardware, your devices should now be recognised ok.