So the RFC project – surveying community council online presences is all over apart from the shouting publicising it and writing a paper or two for a peer-reviewed journal. Celebrations thereof to be arranged. Continue reading
Author Archives: Bruce Ryan
My MSc dissertation
I need an online home for my dissertation, so here it is:
Celebrating SysAdmins
In a former career track, I was a effectively the (completely self-taught*) SysAdmin for a small publishing company. As well as doing a lot of layout, some illustration, proofreading, print-buying, free-lancer-running and management of small in-house teams, I commissioned, installed and maintained the mostly Mac-based systems and printers.
2014_07_18: breaking the silence (continued)
Following on from last night’s post:
Here’s some results from the CC online presence survey:
- Still only 22% of CCs have up to date presences. The figures for out-of-date, existent but not online and non-existent CCs are also almost completely unchanged.
- Moray and East Renfrewshire have the highest percentages of up to date presences, at 65% and 60% respectively. Clackmannanshire, Edinburgh and Falkirk are in the 50%-59% range. The %ages of up to date presences in LAs looks like this:
Breaking the silence
So I’ve been silent for far too long. Here’s the highlights of the last month or so. Continue reading
Cyclepath questionnaire
Hi folks
A researcher at Napier is investigating attitudes to cycle paths. If you would like to be involved, please print and complete this questionnaire, then send it to James Calvey.
James Calvey BSc AMCIHT
Research Student
School of Engineering & the Built Environment
Edinburgh Napier University
10 Colinton Road
Edinburgh
EH10 5DT
Inevitable disappointment
Away from coding and informatics research, I’m a bit of a cyclopath. I like to use navigation apps and map my rides using cyclemeter on my iPhone. But even with wifi switched off, the iPhone’s battery lasts less than 4 hours. The first solution I tried was a simple external battery. But this isn’t very convenient because for a long time, my iPhone has been in a LifeProof case, and nestled on my bike’s handlebars. The Lifeproof handlebar mount doesn’t allow the case’s charge door to open to allow a charging cable to reach the phone. So I’ve needed to dismount the phone from the handlebars when charging it – not much use for navigation.
Another potential solution is a hub dynamo. Some online research suggested that the best model is the Schmidt Original Nabendynamo (SON). There are many models of SON to suit the large number of combinations of hub types and spoke numbers. (My bike has disk brakes: the disks are fixed to the wheel hubs using 6 holes – an ISO standard.) About a year ago I bought the right type of SON and got my favourite bike shop to fit it into my bike.
But there are still issues: as well as needing to be able to open the charge door, dynamos produce varying AC voltages. iPhones and other USB devices need 1V DC. SO a transformer/regulator is needed between the dynamo and iPhone.
The first transformer/regulator I tried was a USB-werk, which is a special version of the e-werk transformer The e-werk has variable output but the USB-werk supposedly just gives out USB-style power. The first one I received didn’t work at all, while the second one failed after a week. I’m relieved to hear I’m not the only one who has had problems. I’m very grateful to the supplier, Rose Bikes, for taking them back with no quibbles.
Another solution – I forget the name – I tried did give out power, but the iPhone decided this was an unauthorised device and wouldn’t charge from it.
Over the last year I’ve been unable to afford to risk losing more money on failing ‘solutions’. I’ve been aware of the Biologic Reecharge brand for a while. They sell cases for several iPhone models but until recently didn’t sell a case for iPhone 5/5s/5c that attached to bike handle bars. (They do now.) Anyway, if I couldn’t afford kit for things I didn’t have, I certainly couldn’t afford to replace a working phone.
But thanks to being paid last month for writing some code, I’ve recently bought the Biologic kit needed to connect my phone to the handlebars and to the dynamo:
- a case
- a handelbar mount
- a transformer
The case adds a lot of bulk to the phone. A lot of the bulk is an extra battery, so that the case can charge the phone even when it’s not connected to the dynamo:
So today’s tests show that the handlebar mount works, and doesn’t fall apart when cycling over Edinburgh’s rubbish road surfaces. The case will charge my iPhone 4 or another external device, whether or not connected to my mac’s USB port. (Just now the case battery is charging – it’s still flashing an amber LED to say it’s less than 50& charged.) All the cables needed to connect external USB devices and the transformer to the case are present and correct. BUT I still have no idea whether the dynamo will charge the case or a phone within the case because I can’t connect the transformer to the dynamo!
The cables that should connect the transformer to the dynamo have bare wire at their dynamo ends. The manual assumes that my dynamo has Shimano-style connectors into which I can twist these bare ends.

Apparently I should also have ordered two wee connectors to connect the cables to my SON dynamo:
These cost €0·95 each, but shipping will cost €8·95 on top of that! I refuse to pay shipping that’s 4 times the price of the products. I’ve not yet found a UK online source of these connectors so I’ll go and bug some electronics stores in the morning.
For now, time to sleep – and see whether the case battery is fully charged in the morning.
2014_04_06
So what’s happened over the last month?
Community council location finder project
The final community council location finder code has been submitted to the client. There were a few days delay waiting for up-to-date data to arrive at the client.
I look forward to the site going live. Meanwhile, here are screenshots of the final version:
- Initial load
- Instructions
- Hiding CCs, so that users can click-to-zoom on any LA
- Searching for a specific postcode
- Result of click-to-zoom on an LA (CC markers and groups displayed)
- CC marker pop-up
Current project
I’m doing the literature review for the resurvey of Community Council online presences. This will update the summer 2012 report. To create connections with European research, it’s likely that I will examine how open-ness and transparency are supported by these presences.
Presentations
Peter Cruickshank and I have
- presented the community council location finder project at a Community Council Liaison Officers networking event
- submitted evidence to the Scottish Parliament’s Inquiry into the Flexibility and Autonomy of Local Government
I took part in the commission’s panel discussion around digital democracy. Here is the original submission. (Thanks as ever to Peter for making my prose legible.) Here is video of the discussion.
Yesterday, I was a note-taker at From Centre to Community – reclaiming local democracy in Scotland. My personal aim was to learn from others at this event, and this was more than fulfilled. I also met ‘Paddy’ Bort, co-author of The Silent Crisis, and Adam Stewart, secretary to the commission, among many others. Most people I spoke to were very well informed and had a lot to contribute. Others came simply to learn.
Many good points were raised – not just pie-in-the-sky schemes. I’m not optimistic that local democracy will be perfected in my lifetime. In fact, I am certain that nothing in this world can ever be perfect. But I am very optimistic that we can start to improve matters, right here, right now.
2014_03_11: it’s progress Jim, but not as we know it
So I spent most of yesterday trying to find what causes my work to crash Safari under iOS7: turns out it’s the gizmo that clusters the CC markers. Not going to cure that in a hurry!
Then I tried for several hours to add the info features from leaflet’s chloropleth/geoJSON example to my script. I got the LAs to highlight on mouseover, but not to de-highlight on mouseout. Nor could I get the data control to pick out data from the LA geoJSON file.
So I reasoned ‘if I can’t add their stuff to mine, can I add my stuff to theirs?’ That is, could I swap in my LA and CC data sets and use leaflet’s code to colour them and pick out data to be displayed in their external control? This seemed to go OK until I added in the geocoder (the bit for entering an address to zoom to that area of the map. This code failed, so everything that should have been processed after it wasn’t even reached.
I went back to trying to add leaflet’s functions to my otherwise functional code. Still no joy.
I refactored my code so it was in a more logical order:
- preparatory functions,
- drawing basic map
- adding scale, geocoder, reset and help controls to map
- adding LA data layer
- adding CC data layer
- adding layers on/off control
and made the reset control call a URL from a simple configuration file, so that when the client actually puts this work online, they only need to update the configuration file, not hack around in the reset script.
I still couldn’t get the mouseout bit to work. I knew this code was being called: if I replaced it with document.write(“rude word”); then rude words were written.
So this evening I revisited leaflet’s example, determined to get it to work. This example has all the functionality built into a script in the html file, not a separate ‘external’ script. Not really the way I want but I’m running out of time…
I realised that the geocoder was being called but just failing somewhere. I’m not sure how I worked it out but the fail point was that geocoder calls a function in my main external script to limit its searches to Scotland – the same bounds as are applied to my map. (Without this search-area limiting, searching for EH10 postcodes shows Walthamstow.) But this script is never invoked, so the function isn’t callable. So instead of calling that function, I’ve copied it into the geocoder. Now that works! And so do all the other bits. I can make the reset script call the configuration file, so long as they are in the right order in the html header (i.e. configuration before the reset function that depends on it – so perhaps the issue was that the geocoder was calling the main script before it was available.
There was another wrinkle adding in the CC marker code. Something doesn’t like a variable called location. Changing that to ccLocation worked.
So here is the whole lot working – but with the javascript embedded in the HTML.
My task for tomorrow is to get the javascript into a separate file, so that this works, cos right now it doesn’t. Then write some documentation, then write a talk for the OKFN meet-up tomorrow.
2014_03_10
Added reset button
It’s another hack down of the OSMGeocoder control, mostly because I don’t have time to understand how to create a control from scratch. The main fault with it is that it relies on
inner.innerHTML = “<a href=\”http://localhost:8888/realISV22\”><img src = \”css/images/reset.png\”></a>”;
The bold bit will need to be replaced with the real URL for wherever the site will be used.



