It may be defective, especially if it used to work.
Unfortunately, you cannot just pull it and install it in another computer to test it.
Does the BIOS detect the drive? If it does, the drive interface is good, but the mechanics are bad. About all you can do is either replace the drive or pick up an external USB drive.