'how to set Trap flag (TF=1) in c language or assembly?

I used xinu and i want to use single step Interrupt (01H). I have two questions

  1. does TF flag equal 1 (TF==1) when xinu system initialize ?
  2. if no then how i can set TF (TF=1) in assembly or c language(if possible) ? thanks.


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source