Start with 2 colors, then add a color repeatedly in a best way. This is not a question, just
post your own results.
My first attempt:
Also (optionally) say the purpose/bias of your selection. This selection fills most gamut in smaller sizes, if dithering is used. Also, final 16 colors are similar to ZX spectrum, except that here dark colors use 170, there is CGA distinctive brown and duplicate black is replaced by orange. The reason why CMY colors are before RGB is that they seemed more useful in 2~4 color palettes.