Instagram filter used: Earlybird
Month: August 2012
-
Pibow; it’s official – normal USB cables don’t fit
I’d noted previously that a standard USB micro-b power plug doesn’t fit into a Pibow. I’ve measured the opening in the case at 10.4 mm. This is what the USB.org spec says for the Micro-B plug:

A conforming cable can be up to 0.2mm larger than would fit into the Pibow. The rather weak excuse given by the designer is:
My Micro-USB cable doesn’t fit!
The Pibow supports a wide range of svelte, stylish micro USB cables, we recommend on [sic] of these. We may be able to slightly widen the aperture to include more cable. We don’t intend to support cables with large sleeves though, they just look naff 🙁
While I had the vernier calipers out, I measured all the USB connectors I could find. Not one was under 11 mm, way out of spec, and completely unlikely to fit in the Pibow.
-
the russian peasants are multiplying!
Via this post, I found out about Russian Peasant Multiplication, a rather clever method of multiplication that only requires, doubling, halving and adding. So I wrote some code to display it:
#!/usr/bin/python # -*- coding: utf-8 -*- import sys results=[] indicator=' ' left=int(sys.argv[1]) right=int(sys.argv[2]) while right >= 1:    indicator='X'    if right % 2:        indicator=' '             # right number is odd,        results.append(left)      # so add left number to results    print (" %s %16d \t %16d %s") % (indicator, left, right, indicator)    left *= 2    right /= 2 print("%s × %s = %s = %d")%(sys.argv[1], sys.argv[2],                            ' + '.join(map(str,results)), sum(results))So to multiply 571 × 293:
$ ./rpmult.py 571 293                571                 293   X            1142                 146 X               2284                  73   X            4568                  36 X  X            9136                  18 X              18272                   9   X           36544                   4 X  X           73088                   2 X             146176                   1  571 × 293 = 571 + 2284 + 18272 + 146176 = 167303
Python’s still got some weirdness compared to Perl; where I’d join the list of sum terms in Perl with
join(' + ', @results), in Python you have to convert the integer values to strings, then call the join method of the separator string:' + '.join(map(str,results)). Still, I’ll give Python props for having a built-in listsum()function, which Perl lacks. -
Times New ROT13 (and Times New Caesar)
If you’re wondering why the lower line has a load of squigglies when it appears identical to the one above, open the linked PDF and copy some of the text. Looks a bit squiffy, no?I’m messing with your head here by splitting the encoding of the characters from the appearance of the glyphs, and using the old rot13 cypher to do it. This will really mess up the new MS Office “Edit PDF as text” schtick. Please note I’m doing this for lulz, not to break accessibility; that would be as the kids today say, a dick move.
Here’s the font: TimesNewROT13.
Since Times is both New and Roman, I thought I’d add some old roman by making a Caesar Cypher version. I don’t think I’ve done this quite right, but it works if you use the following shell command as an encoder:
tr '[A-C][D-Z][a-c][d-z]' '[D-Z][A-C][d-z][a-c]'
Here it is: TimesNewCaesar. I’ll fix it soon enough.
(Note that ROT13 fonts have been done before …)
-
Pibow

… arrived today from the UK. Quick and easy build, though you have to be careful to get the case screws all tightened up just right or the thing will be wobbly. IKEA are totally going to hand Pimoroni their arse over the lookalike instructions, though.
Though there is just one problem: a standard USB micro-b power plug doesn’t fit …





























