Mine won't go to sleep if I am doing some processing. It also will not go to sleep if Toast (5.2.3) has a disk ready, click eject box open.
Are you running anything out of the ordinary either as a Mac app or in terminal?
The shutdown on schedule thing is wierder though. Is there any sign of a shutdown trying to happen?