Added code for IR reverse engineering