occupy (oneself)
To keep oneself busy or distracted (by doing something). A: "It might take a while for this to finish up." B: "Don't worry about me, I can occupy myself." The children like to occupy themselves by reading.
occupy oneself (by something)
to keep busy by doing something. Don't worry. I can occupy myself by knitting or sewing. While waiting, I occupied myself by knitting a scarf.