Possible solution 1 the other possible solutions are to try a different usb cable if you have one lying around.
Hp printer usb cable not recognized.
Find the usb device it may have a yellow exclamation mark next to it select update driver software then choose browse my computer for driver software and let me pick from a list of available drivers on.
Try to blow a little to remove dust.
Clean the usb port in both ways.
This is a fairly rare problem but i have seen it occur a few times over my many years doing technical support.
If not just buy a new cheap usb cable from amazon.
Go down the list until you see universal serial bus controller and click the plus icon to expand.
The usb device might not display if it was stopped previously and not disconnected from the usb port.
Refer this article to further troubleshoot printer not found during network driver setup.
If u are not regularly used the printer make sure you place it on clean place to make sure the printer not being a dust factory.
Connect the usb cable to the printer only when the software prompts you to connect while installing the drivers.
Let me know how it goes.
If a plug and play automatic setup screen like the one shown below is displayed when you connect the usb cable click close or cancel to close it.
To resolve this issue disconnect the device wait approximately 20 seconds then reconnect the device to cause the device to display in the safely remove hardware window.
Have a wonderful day ahead.
Make sure that the usb cable you use has the following mark.
A to b a to micro b a to mini b or a to a.
Update the full feature printer software using this link.
Remove dust clean your printer regularly to make sure for long term used.