update task wait process.
update idle task code.