dword *SoftStandbyVar = NULL; void SoftStandbyInit() { // Power Off Detection for soft standby short *p = (short*)FindInstructionSequence( "8f99a4d8 9339001c 0019ce00 0c053c50 001927c2 0c0013d9 00000000 3042ffff af828618 0c050bc6 27848827", "ffff0000 ffffffff ffffffff fc000000 ffffffff fc000000 ffffffff ffffffff ffff0000 fc000000 ffff0000", 0x800f0000, 0x80170000, 0, FALSE); InitTAPex(); if(p) SoftStandbyVar = (dword*)(FWgp + p[17]); } int isSoftStandby() { return SoftStandbyVar && *SoftStandbyVar; }