Lispbian Pi. A Lambda Delta.

I’m conflicted. Part of me says that ‘us old timers’ shouldn’t assume ‘the way things were when we were kids’ were better but we know the Raspberry Pi was an attempt to recapture the spirit of the BBC Micro Model B and that seems to have gone quite well. I got a Pi 2 and I’ve worked out that it is more powerful than the first computer I worked on, a DEC VAX-11/780 which supported about 16 terminals, most used for teaching college level computing. Having that machine to myself would have been an unimaginable amount of processing power for one developer. Banks ran their financial modelling software on boxes like that. So why does the Pi feel so slow? We wasted our gains on GUI fluff.

When I started computing you learned just enough of the command language to get going. So, that’s bash on a pi. Then an editor. For reasons that should become obvious, let us choose emacs. When I first used the VAX/VMS operating system, it didn’t have command line editing. If you made an error, you typed it all again. Getting the facility to press up-arrow, edit the command and re-execute it was a big advance. We should keep it. Bash has that, using a sub-set of the emacs keys, so that’s a way into emacs.

The next big improvements I remember were X windowing and symbolic debugging. We got debugging first but it became far more powerful with multiple terminal windows. The GUI was OK, I guess but DEC didn’t give us many free toys so the main advantage to a developer was having lots of terminal windows. emacs can do that, without the overhead of X.

When I decided to re-learn coding a while back, I got my shortlist of languages down to Python, Java and JavaScript but picked Python because I was already learning a new language and the Object paradigm, so I didn’t want to have to learn web at the same time. I heard about the modern Lisp dialect Clojure and changed horses mid-stream. I’m convinced by the argument that functions and immutability can save the universe from the parallel dimension.

Last night I deep-dived into emacs and found myself in an editor session with 4 windows. Why do I need more than that to learn about computation and data transformation? This guy seems to have come to a similar conclusion http://hackaday.com/2015/09/23/old-lisp-languaged-used-for-new-raspberry-pi-os/ I’ve also wondered whether a purely functional OS might make Sun’s ‘the network is the computer’ dream a little easier. emacs is written in Lisp.

I think a dedicated Lisp machine may be a step too far back. How would you browse in the world-wide hypertext library when you got stuck? But a Linux with bash, emacs, the Java Virtual Machine and libraries, Clojure via Leiningen and Cider to plug everything together might make a fine Lispbian Pi! Is all this chrome and leather trim completely necessary in the engine compartment?

It is unfortunate that the Raspbian upgrade left Leiningen broken.

A Page Break in Markdown (ReText)

Since I started to use Markdown, I’ve found it helpful to use the ReText editor in ‘Live Preview’ mode (Ctrl-L) so I can write Markdown markup language in the left-hand window and see What I Got in the right-hand window. It’s easy to forget that there is no official standard for Markup, so when you want to do something ‘none standard’, different implementations may have handled your problem their own way. Some answers I found didn’t work.

I wanted to force a page-break when I print out a cheat-sheet I’ve written and intend to update, as I  learn emacs key-bindings. There are several already but things weren’t arranged in an order that was helping me to learn which keys work in the Linux bash shell (another command-line editor option is available but emacs is the default.)

ReText supports something that appears to be based on HTML/CSS. Other interpreters use LaTeX syntax. In ReText, page-break-before style is applied after the text you want to appear at the top of the new page.

"...some text from the previous page

## New Section Title {: style="page-break-before: always" }

Text on new page"

The Unvexing

This post comes to you courtesy of Graham Lee at: http://www.sicpers.info/2016/11/the-vexing-problems-in-programming/ who reminded me about Value. We agilists (people who believe in agile software development) talk about value a lot but haven’t  agreed on a consistent definition of the word. As an illustration of two of the options:

“The value of this car is £9,500.” Is that to a seller or a buyer? Unless there is a difference, no trade will take place. Or is it a market rate? The long acquisition dance between Yahoo! and Google makes an interesting case study. This is: a value. A ‘fact’, right or wrong. It is the kind of thing developers in imperative programming languages put into variables and mutate but pure functional programmers squirrel away for ever, to embarrass themselves at their past Wrongness.

In contrast, “This car cost £9,500 pounds. I think that was quite good value but the model that costs £1,000 more is even better value.”, is a relative benefit:cost calculation, yet the manufacturer may market a ‘value’ model, which is just cheap. This is: a value judgement. An explicit or implicit comparison relative to something else, followed by a decision. It is a computation.

When Graham says, the most vexing problem of software product  developers is their inability to “compare the expected value of their work to the expected cost of the work.”, I think he means  ‘business benefit of their work’, and cost normally equates closely to development time. All the customer really wants to know is: “Is this the best investment I could make now?”

Graham goes on to say that we are very bad at estimating how long something will take. This is true but we are much better at estimating small jobs accurately than large ones.  Uncertainty increases exponentially with length of sequence of actions, to slightly corrupt Shannon’s Information Theory. This is why the Fibonacci sequence is often used as a sizing tool.

Agility accepts this reality. It addresses the list of things the customer currently wants, in highest benefit:cost ratio order (guessed by a business domain expert, based on guesses by an agile develooment team.) It doesn’t yet know whether the ‘whole job’ is worth doing. It decides only whether to risk the next small, cheap step and keeps doing that, as long as the ‘value’ is Good Enough. While value is high and risk is low enough, keep going.

A journey of any length starts with the first step, so why worry about whether or not it is going to be 1000 Miles? The hard part is to make it a journey, rather than simply wandering about, lost.

Then there are: our values. Our personal decisions about what matters most to us. Do we go home to read our children a bedtime story or work late and win that promotion so they have greater financial security in the future? What do we really care about and what are we willing to pay for it? This too is relative. Politics is the art of persuading you to modify your personal values. Currently, cheating is allowed.

We are Very Sorry

We know you don’t understand why we won’t stop moaning and make the best of it. We know you took your country back or took back control or whatever lies you believed, but the people you took it from weren’t a rich elite, it was us. While you think you are on the way to achieving your dream of a better life, for you, your family and your nation, against all the others trying to steal it from you or suck you dry with taxes, we lost our dream of greater equality, fairness for all, an end to prejudice and warfare. We lost a huge slice of human culture in the swamps again; mostly the  good stuff. You chose the sole protection of wolves on a barren island when you burned that bridge to Europe or believed the vague dreams of proven fantasists.

So, right now, bottomless cynicism is all we have. It is the natural response of rational thinkers who believe in evidence before the rhetoric of slime-balls, to the tragedy that has befallen everyone who doesn’t think they are worth more than everyone else in the world and competition with sworn enemies is the only way to make progress. We don’t see any progress, just a slipping back to survival of the fittest. If you were really the fittest, why did you feel like losers on a level playing field?

We must eventually win or we all die, because the planet isn’t safe in your hands. You just made it very much harder. Your thoughtless positivism will be the death of us one day.

Licensing Pain

It’s a very long time since I’ve used any software that requires a licence but I decided to try the patented MPEG2 codec licence for my Raspberry Pi, to decode MPEG2 in hardware. Now I remember why I disliked software licensing so much. This was the process I followed for the Pi’s default Raspbian operating system.

Step 1: Find my Pi’s serial number. At the command line, type:  cat /proc/cpuinfo
The last line, starting Serial: is the unique number of your Pi.

Step 2: Find where to buy it. http://www.raspberrypi.com/license-keys/
Enter the serial numer of the Pi you wish to buy the licence for..
Pay £2-40 and wait for an email. It may take up to 72 hours. I assume this is because a unique(ish) key must be generated.

Step 3: Add the following line to “the config.txt file in the FAT partition of your SD card:

decode_MPG2=0xfdb4a3ac” You may note that this is not the 10 digit hex you were expecting. That doesn’t matter. The first two digits must be implied zeros.

Others told me this meant sudo my chosen editor to add the line to /boot/config.txt then save and reboot.

and “If you want to verify that the codecs are now enabled, the following commands will report their status:

vcgencmd codec_enabled MPG2”

Step 4: Wonder why that didn’t work.

In my case, I was typing:
“vcgencmd codec_enabled mpg2”. It said mpg2 was disabled. In reality, there was no “mpg2”, because it’s “MPG2”. Case matters.

 

Moderately Grouped

One of the rules I try to live my life by is: “Small pieces, loosely joined”

Then this happened.

http://phys.org/news/2015-06-social-networks-group-boundaries-ideas.html

I don’t know who I am any more. I already feared de-selection from the cult of Unix and now this.

Then I realised that although I favour hi-fi separates, I don’t  design my own amplifiers and hand-wire the components. I don’t compile Linux from source every time. I’m not a fanatic.

Tooling-up for agile state-transition

This post started out in life as an answer to a question about ‘backlog tooling’ on the LinkedIn ‘Lean & Agile’ group. Someone had given the culturally acceptable answer that the best solution is simple cards or post-it notes on a board or wall. I normally just let that pass because I don’t have a better solution to offer but this time, THIS happened:

I’m about to be intentionally provocative. We know that we are engaged in transforming a multidimensional network of business functions from one poorly understood and transient state to another, currently ill-defined, future state that we hope will emerge from the mist as we travel in it’s general direction. In organisations of any size, this change process is likely to run in parallel with other change programmes, some of them probably deliberately kept secret by people whose pay grade exceeds their ability to make rational judgements about the basis of who “needs to know”.

Amongst this chaos, the chosen tool of ‘the Agile Community’ is a single, 2-dimensional view of a ‘list of lists’, sometimes known as ‘a tree’ or ‘a star’, all of which are topologically equivalent representations of items’ states in the backlog of each Product development. Our best software tools are little more than a model of cards on a board.

Why do we expect the complex, dynamic agile change process to map any more adequately onto a tree of cards than it does onto a hierarchical management structure? Have we learned nothing from our mistakes of modelling within the limitations of the filing cabinet and the typewriter? Perhaps agilists don’t value tools because our tools aren’t fit for purpose.

If all you have is lists representing vague descriptions of changes between two mental models you hope your whole team all share, perhaps the limited nature of the backlog tool isn’t your biggest problem. The backlog items reference changes to an implicit model of roles and the objects in the business domain of your product. My advice is to make it explicit.