IR Medium Scan Code

Just adding the function that returns the distance in millimetres based
on the IR reading.