Just before writing halo swap routine for case study