This M-File convert the classical latitude/longitude coordinates to the maidenhead locator system, mostly used by the ham-radio operator to describe the transmitter location (QTH).
Sorry, I haven't it in English, but the code is very simple.
The section between ======= and ====== at the beginning, is simply a few examples of known locations that i used to check the code, by activating on of them.
The rest of the code is only some simple mathematics and format conversion to get the result.
I have been looking for a simple program to convert LON/LAT to the 6-digit MH square.
Do you have this in English? Thanks!