(a) A person is guilty of failure to appear in the first degree when (1) while charged with the commission of a felony and while out on bail or released under other procedure of law, he wilfully fails to appear when legally called according to the terms of his bail bond or promise to appear, or (2) while on probation for conviction of a felony, he wilfully fails to appear when legally called for a violation of probation hearing.

      (b) Failure to appear in the first degree is a class D felony.