Hi Andy,
I'm the author of the original VBA script.
You should change initial x_min, x_max, y_min, y_max values to 32768 and -32769 (lines 125,126, 142, 143 in cli.py; lines 109, 110, 126, 127 in cli_multithreded.py) because x may change within entire int16 range and y from -16384 to 16383.