Skip to main content
4 of 7
added 428 characters in body

C (gcc), 252 bytes 242 bytes 269 bytes 262 bytes 241 bytes

I was on stack overflow for sockets in python, when this popped up, said why not? first code golf, so i'm not entirely sure if I followed the rules 100% (and if not and someone wants to steal my proverbial cookie and fix it, so be it). With 'o' and ' ', 255 245 272 265 262 244 bytes. replace +48 with *79+32. had to reorder some bits to get 4 and 5 to work (oops)

#define Q(P,R)(R>>P&1)+48
char a[12];i=0;f(char*c){char b=c[0];a[3]=a[7]=a[11]='\n';a[5]=Q(0,b);a[1]=a[9]=Q(3,b);a[2]=a[8]=Q(2,b)|a[1];a[0]=Q(1,b);a[4]=a[6]=a[1]|(a[2]&a[0]);a[0]=a[10]=a[2]|a[0];printf(a);if(i++<1){printf("---\n");f(c+1);}}

Try it online!

How it works:
I use a bit shift and bitwise and to find if a spot should be clear or a pip, then offset the 0 or 1 to the correct ASCII value. it messes up on 4 and 5, so they needed some fixing. actually added a few bytes. was able to remove several bytes by removing a mask and just using 1 (doh)

Special thanks to Mr. Xcoder for the 7 less bytes by removing an excess #define latest update: removed memset, it was never used. this is addicting.