This was written in using ME Labs PicBasic pro compiler
The source code is in the Picswr subfolder.
PicBasic Pro first compiles to generate assembler code which is then compiled to machine code (hex) using the MPASM assembler.
The intermediate MPASM code is not particularly easy to modify as is full of Macro calls to MELabs library routines.
I did consider using assembler ... but PICBasic is so much easier.
For example:
To evaluating the square root of (a * b / c) where a, b and c are 16 bit unsigned integers requires a 32bit/16bit division.
The PicBasic code is simply:
dummy = a * b
result = SQR DIV32 c
This calculation is needed in computing SWR. It would be much more complex to write in assembler !!