• Kenny Code for DOS

    From Kerr-Mudd, John@21:1/5 to All on Mon Apr 24 10:04:39 2023
    XPost: comp.lang.asm, alt.lang.asm

    Smallest possible? Kenny code converters
    (m=0, p=1, f=2; so 'A' encodes as 'Mmm')
    e.g.
    "What's up, Doc?"
    encodes as
    "Fppmfpmmmfmp'fmm fmfpfm, Mpmppfmmf?"


    Encoder 73 bytes:

    d 100 l49
    16AB:0100 B4 3F B5 3D-BA 49 01 89-D6 89 C7 CD-21 91 E3 35 .?.=.I......!..5 16AB:0110 57 BB 46 01-AC AA 0C 20-3C 7A 77 1B-2C 61 72 17 W.F.... <zw.,ar. 16AB:0120 BA DF 09 4F-0A 15 98 F6-F6 D7 AA 88-E0 80 EE 06 ...O............ 16AB:0130 77 F4 D7 AA-20 55 FD E2-DB BB 01 00-89 F9 5A 29 w... U........Z) 16AB:0140 D1-B4 40 CD 21-C3 6D 70 66 ..@.!.mpf


    Decoder 78 bytes:

    d 100 l4E
    16AB:0100 B4 3F B5 BF-BA 4E 01 89-D6 BF 52 C0-CD 21 91 E3 .?...N....R..!.. 16AB:0110 39 57 BA 20-0F 31 C0 22-14 80 C2 41-F6 E6 00 C2 9W. .1."...A.... 16AB:0120 AC AA 0C 20-93 BD 04 00-4D 74 13 3A-86 4A 01 75 ... ....Mt.:.J.u 16AB:0130 F7 4D 95 4F-80 EE 06 77-E3 00 D0 AA-49 49 E2 D2 .M.O...w....II.. 16AB:0140 43 89-F9 5A 29 D1-B4 40 CD 21-C3 6D 70 66 C..Z)..@.!.mpf



    Both use DOS Int 21 for redirection; e.g.
    Enken<plaintxt.txt>kencode.txt
    Deken<kencode.txt

    Asm programs assume bx=0,al=0 at start
    Size limit of 15k of plain txt.
    Capitalisation catered for.
    Nonalpha chars 'encoded' asis, and similarly any
    non-kennycode chars in the decode stream left asis.
    But GIGO rules still apply!


    --
    Bah, and indeed Humbug.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Kerr-Mudd, John@21:1/5 to All on Thu Aug 15 10:03:11 2024
    XPost: alt.lang.asm

    Looks as if xposting to clax isn't working, so dropped on this repost.


    Kennycode encodes alphas as 'mfp' triplets -

    info (& online conversion): https://www.geocachingtoolbox.com/index.php?lang=en&page=kennyCode


    DOS version in 125 bytes

    d 100 l7D
    16AD:0100 B4 3F B5 7F-BA 7D 01 CD-21 91 E3 41-89 D6 BF BE .?..}..!..A.... 16AD:0110 80 57 80 3E-83 00 64 74-38 BB 4E 01-AC AA 0C 20 .W.>..dt8.N.... 16AD:0120 3C 7A 77 1B-2C 61 72 17-BA DF 09 4F-0A 15 98 F6 <zw.,ar....O.... 16AD:0130 F6 D7 AA 88-E0 80 EE 06-77 F4 D7 AA-20 55 FD E2 ........w... U.. 16AD:0140 DB BB 01 00-89 F9 5A 29-D1 B4 40 CD-21 C3 6D 70 ......Z)..@.!.mp 16AD:0150 66 BA 03 60-B4 00 22 34-AC AA 0C 20-B3 03 FE CB f..`.."4... .... 16AD:0160 78 17 3A 87-4E 01 75 F6-4F 88 D8 D5-03 88 C4 FE x.:.N.u.O....... 16AD:0170 CA-75 E5 49 49-00 F0 40 AA-E2 D6 EB C4 .u.II..@.....
    q





    Same fileio as morse coder; '-d' to decode, '-e' or no parm to encode.

    Caps on 1st letter of triplet means cap letter on decode & v.v.
    c.32k filesize limit.



    Example usage:


    C:\TEMP>echo "Hi! I'm Kenny!">kenpln.txt

    C:\TEMP>kencode -e<kenpln.txt
    "Mfpmff! Mff'ppm Pmpmppppppppffm!"

    C:\TEMP>kencode -e<kenpln.txt>kencode.txt

    C:\TEMP>kencode -d<kencode.txt
    "Hi! I'm Kenny!"

    C:\TEMP>









    --
    Bah, and indeed Humbug.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)