Microsoft MakeCode

Mbit fail with Yahboom robot ..reason?

Is there a way to correct this code so that IR works with this bot arm? I asked elsewhere but have no response as yet. Thanks : https://makecode.microbit.org/_JRsHEaDdY6m3