Shutdown doesn't reboot


I need a software mechanism to shutdown my system and a tried the shutdown utility, but it kill all applications and daemons but neither switches off nor reboot the system.

My target is an x86 controller.

Has any one an idea?

Quique has posted the source before.

Thanks for your code,

I tried it and it kill application and daemons but when it goes to rebbot it tells me an error, and doesn’t power off. I don’t have the AMP BIOS then I’m looking at yor code and contacting my manufacturer to try to adapt the code to my target.

I’ll inform you about my progress, thanks again.