What do I need to do to get my Mac to sleep properly?
This is the key to the entire issue:


  The internal HD failed some time ago, since which it's been running
  fine on an external usb hd.


It can't go to sleep when your USB is your boot drive.  If it did put the port to sleep, it would unmount the boot device which would cause OS X to crash.  You can confirm this with the line in your pmset output:

ExternalMedia                  1

(The USB drive is, by definition, "external media")

If you replace your failed drive with a new internal drive or SSD, the problem will go away.

I had a failed drive in my iMac and I can understand why you have not yet changed out your drive.  It's much easier than you think to replace it, it just takes some time.  Even though ifixit rates it as "difficult",  it's not difficult per se; it's time consuming and detail oriented.  You have to do this very carefully.  

Before you undertake this fix, make you you have all the parts you need like the drive and the adhesive strips. (Get quality ones and not generic double sided tape - I have seen people that went cheap here and had displays fall out - quality tape is much cheaper than a replacement display)

Have a look at ifixit.com for step by step instructions