WRT filenames: "b" (ascii 98) is an acceptable character for flat. Is there an accepted character in place of the not-good-for-most-filesystems sharp "#"?
No, there's no de facto or official equivalent for sharp that compares to the accidental (ha!) equivalence of flat and lower case B. But some filesystems will let you use # or even more esoteric symbols in file names.
Even so, even in 2019, it's safer to encode the key in some kind of metadata instead of in the filename.
Ascii 98 is just letter 'b'.
Unicode would be the way to get a representation of the musical symbol.
Unicode U+266D is a musical flat sign.
Inputting Unicode is another issue. I just cut and paste from a site that displays the Unicode symbol.
In order for a user to actually see the symbol, they need a font with a glyph for the character.
Using such characters in a file name is yet another issue. I'm scarred from the bad old days when various filename systems could not handle much beyond plain ascii. So I would just write out 'sharp' or 'flat' or just give up and use ascii 'b' or '#'. Neither is what we want, but plain old alphabetic ascii shouldn't fail you.