About paulcullenphotography

My life revolves around photography; Landscapes, Portraits and other social photography, flowers and macro photography are all areas that interest me. I have had several photographs published I have just become a professional photographer. Website: www.paulcullenphotography.com Flickr: paul2210 Photography Blog: paulcullenphotography.co.uk Wine Blog: uncorkedbottle.uk Twitter: @PaulCullenphoto

More Courses!

Well one anyway!

Those of you who have come across this page before may have read about my Android course with Udacity, my Flutter course with Udemy and the Analogue Electronics course, again with Udemy. Well now I have reached new heights – well it was certainly the longest and most difficult course to date. I have just finished a course in C++ development with Udemy.

I have wanted to complete a “C” based course for some time. I have read several books about the C language and typed along with the examples in the book. My belief was and still is that if I was to learn a “C” based language, it would help me to better understand what is going on under the “hood” since many of the higher level languages are based on C and many of the libraries are written in C or C++. I thought that I would get a better understanding of some of the error messages and so I would gain a “deeper understanding” – I hoped. I found C on it’s own a little limiting so when I found what appeared to be quite a comprehensive C++ course on Udemy, I decided to sign up for it.

I began in early December 2022 and preceeded to plod through it. Christmas happened so I put it to one side for a little while and picked it up in earnest by mid-January. It was 46 hours of lecture videos, which is by far the longest Udemy course that I have signed up for but of course, it takes a lot longer than that when you have coding challenges, quizzes and having to watch the videos several times to be able to grasp the concepts – I am sure that many people have to do that – or perhaps it’s just me but the point is, grasp those concepts I did and I finally completed on the 20th February 2023. I am proud because I feel that I have come a long way. Not only have I gained an understanding of C++ which will come in useful for development of C++ programs. C++ is generally the language of micro-controllers like Arduino, so I’ll be able to have a go at programming them. This course will also come in useful when writing the Java for my Android stuff (The back end is written in Java in my apps ‘cos I’m old school – I was taught Android apps with Java – I might get around to Kotlin at some point) and It will help me if I want to have a serious attempt at learning Python.

All that I have to do now is get some practice writing programs in all of these development languages – I promise that there is method in my madness – I like to think that there is a pattern to my progress.

I haven’t put any C++ programs on my GitHub page but if you are interested in what I have done with Android and Flutter, please follow this link:-

https://github.com/CullenDevelopment

Advertisement

The Illumination Repairs App

I was inspired by the work/volunteering that I had been doing for Illumination Repairs C.I.C. to attempt to create a contact app and I decided to create it in Flutter so that eventually it would work on both Android and iOS without having to write the whole thing twice – there are pros and cons to this approach which I hope to cover in another post.

I opened up Android Studio on my Development Laptop and set to work….

I first of all I discovered how to create three tabs within the AppBar which would enable me to switch between three pages easily. They were “Home”, “Email” and “Website”. I used the artwork from the Illumination Repairs Instagram posts – cheeky I know but I was hoping that the company would benefit from my efforts so it was justified. The colour scheme that they had chosen was black and white so I felt that I had to keep it as it is part of their “brand” – I would have much rather used a more colourful palate.

The “Home Page”

Here you can clearly see the tabs (set on Home). The artwork is the first page of a video presentation which they created to “tell their story”. The next images are some of the “slides” in the video presentation.

It took me a while to work out how to have a mpg4 run in the app but I succeeded. I will leave a link to my GitHub Repo for this app at the end so you can see how I did it rather than explain here.

Next is the “Email” tab which leads to an email based enquiry form which sends an email to a designated address.

Finally, there is the “Website” tab which has a link to email (blank) but again to a designated email address. I later considered this surplus to requirements because the form on the email tab form was sufficient.

It also has a link to Illumination Repairs Facebook page and the Illumination Repairs website.

The biggest flaw with this app is that for all of the people who approach us for a repair it is a one-off contact – who would download an app just to get one or two things repaired, so it will never go into production in it’s current form. All is not lost – I know a little more about how to embed a video into a Flutter app, I have more of an idea about how to create an email enquiry form in Flutter, I can put links into buttons to webpages and email (the second email code works a bit different to the first) and the links to the webpages including Facebook/Meta can be done several ways – I tried the most common way (according to Stack Overflow) and it didn’t work as it was trying to parse ipv6 addresses and I think that that particular method was best suited to ipv4 addresses and so I found another method much better. I will use what I have learned in other apps and it has opened my horizons to the possibility of other apps.

That link to my GitHub Repository containing the code for this app:-

https://github.com/CullenDevelopment/illumination_repairs

Things that I have repaired.

These are some of the things that I have repaired as part of Illumination Repairs since November 2021.

Shredder

This was the second shredder that I repaired – this one had a bent paper switch – the one that activates the shedder when you put paper in the feed. The first one had a broken switch and I re-wired and replced the switch.

Kettle

The one of the bi-metallic strips needed replacing – I had a spare lying around from a kettle that could not be repair due to a broken and non-replaceable element. This one went to a charity shop – it was an Asda basic range kettle and wasn’t worth much so we gave it away after extending it’s life.

Toaster

This toaster – the metal strips that holds the bread has come off it’s rails – it was given a new lease of life via the charity shop – it made nice toast – well, you have to try these things out (you do actually, more about that later) but wasn’t worth much but someone will have the use of it and it’s one less easily mended electrical in landfill.

Nespresso Coffee Machine.

It wasn’t puncturing the pods. It turned out that it did if you put the pods in at a certain angle. It wasn’t broken as such but perhaps a little worn and worked perfectly if you were careful. It went back to a very grateful client who gave a donation. Nice machine.

A “Flip-over clock” from Habitat

This clock wasn’t flipping over the days of the week due to a broken mechansim post and so the gears were not engaging. I replaced the post with a screw and it went back to it’s owner.

Sit in electric toy car.

After much investigation, it turns out that there is a switch in the charging point socket. When it is charging the circuit goes one way; when it is not charging i.e. when the charging plug is not inserted a switch closes enabling the battery to power the motors, lights, horn, radio and a host of other accessories. The problem was that the switch was stuck – it only needed to free the mechanism of the switch. The parent of the owner was very grateful and I have since heard that her children are getting a lot of use out of it again. We don’t usually repair things this big – it was sat in my sitting room for several weeks. We were sad and also pleased to see it go at the same time!

Morphy Richards Steam Generator Iron.

The steam was working but the iron was not getting hot – I replaced a relay that controlled the current to the iron element once I found the problem – it is always worth investigating – the obvious answer was that the element in the iron was defective but by a series of resistance measurements that was found not to be true and I was able to trace it back to the relay. The owner was very pleased and made a generous donation.

DeLonghi Eletta Coffee Machine

Despite the owners very thorough cleaning regime it turned out that the reason this coffee machine stopped brewing was a blockage in the hot water pipe.

Whenever we complete a repair on anything that uses mains electricity we have to ensure that it is safe and to that end we Portable Appliance Test (PAT) the items and record the results then apply a sticker to show that it has been done and the appliance is safe.

The first part of the test is a visual check of plugs for sound connections, that the cable is secure, that an appropriate value fuse is inserted and that it is in good condition (no tin foil, nails or other bodges), no signs of overheating or cracks and other damage to the plug. The cable is inspected to show that it is in good condition and we check for cracks and other damage on the appliance. We then determine what “Class” of electrical item we are dealing with and set the PAT Tester to check the appliance according to it’s class. Class I tests Earth Conductivity (Bonding) and Insulation resistance. Class II, just Insulation Resistance. We can also do a “cord test” which is generally detachable cables like “kettle leads”. All of the values should be (well) within the values set by the Institution of Engineering and Technology (IET) Code of Practice for “In-Service Inspection and Testing of Electrical Equipment” 5th Edition.

My Seaward Primetest 100 PAT tester

This is my PAT Tester. The smart ones amongst you might be thinking the top figure – Earth Conductivity – is a little high as we would prefer the figure to be <0.1 Ohms (the guidance is <0.2 Ohms usually and in special circumstances <0.5 Ohms) but it was down to the length and conductor cross surface area of the cable.

The last part of the test is that it functions as it should do which is why I enjoyed the toast with the toaster that I repaired as well as coffee from both coffee machines.

I also replaced the screen on a DAB radio, the aerial on another DAB radio and repaired an assortment of other things that I haven’t got photgraphs for…

I decided to create a Flutter based app on the theme of Illumination Repairs… More about that next time….

While I’ve been “away”.

Hello again! May I just apologise for my absence – I got a bit distracted. I was scrolling through my Instagram account when I was recommended an account to follow called “Illumination Repairs”. They are a Community Interest Company and their mandate is to repair electrical items that have broken and would otherwise go to landfill or less likely, be recycled. It is a cause that is close to my heart, they are based in the area where I live and there was an opportunity for me to join them as a repairer. It would give me an opportunity to fiddle with electric and electronic devices and gain further knowledge and experience in that area. They wanted volunteers so I contacted them and arranged to meet James, the company founder. I went to meet him and walked away with five things to repair.

They currently have an arrangement with a local village market where broken items are dropped off, taken away and repaired if possible. The items can be donated and repaired items are sold to raise funds, or they are returned a month later at the same market – we then invite the clients to make a donation when they are happy with the repair. To give some idea of the sort of items that we expect….

It is not an exhaustive list; we will generally consider many things under 25 kg, electrical/electronic items if we think that they can be repaired.

You might ask “where does the sales of repaired items money and donations go?” It will go to support helping people into work through sharing skills and making people more employable through learning how to repair electricals by “sitting at Nellie’s knee” – working alongside more experienced repairers. It also goes towards buying spare parts, liability insurance and tools.

This was the bit that attracted me. I thought “That’s me!” I have put in more than a few hours each month since joining in November 2021.

I will be writing about the some of the things that I have repaired since joining, new things that I have learned, my latest app which is related to this venture – and why it won’t see the light of day but how many of the features that I have learned creating it will be used in other apps in the future.

Illumination Repairs website:-

https://www.illuminationrepairs.org.uk/about

https://www.facebook.com/IlluminationRepairs

See you tomorrow…

The Body Mass Index Calculator.

Hello and welcome back. My latest Flutter and Dart project is my body mass index calculator or as some know it BMI. Body mass index is a somewhat out of vogue way of assessing if someone is of a healthy weight for their height and quite rightly so, many a professional Rugby player will have a BMI of 35 or above, particularly those forwards who are all muscle and muscle weighs more than fat. A safer option would be to assess %fat content but that is more difficult so I think that BMI calculation will be around for a bit longer yet so this app may well prove helpful. The calculation for body mass index is:-

BMI = weight in kilograms / (height in metres x height in metres) (substitute * for x if you prefer!).

My app also has a calculator for conversion of imperial weights (stones and pounds – British not US) to metric (kg), and another for imperial height or length (feet and inches) to metric (metres) which can them be used for the BMI calculator. I have included a calculate button for each calculation and a reset button to clear all of the boxes.

The Flutter Version of the BMI Calculator app.

It is the Flutter version of part of a previous Android app with several calculators within it. My intention is to ask those to whom I show all of these Flutter calculation apps which ones they would like to see as a suite and which would not be useful to them. I intend to have several sites; perhaps a paediatric suite and an adult based suite and target them at appropriate audiences. If you have any thoughts on the matter, please feel free to share them with me. Thank you.

My Quiz App.

My daughter is a primary school teacher and holds a Master of Arts Degree in History. I thought that it would be a jolly wheeze if I was to attempt to create a quiz app that might be useful to her endeavours, or at least amuse her. It would also give me an idea for a project – sometimes as an app developer, finding an idea for a project is the most difficult thing. I made it and although it wasn’t suitable for her target audience, I am quite proud of it. There are problems with it, such as the fact that it is difficult to make out the text in front of the background illustrations (some of which are my photographs – Eilean Donan Castle and Gallos from Tintagel castle – look it up!) but it was progress.

Four Quizzes in One.
The front page and links to the other four pages.

It was a first attempt at a quiz app for more than as an educational project. I had created a much less elaborate quiz as a project for my Udacity Android Basics Nanodegree; this quiz was based on the techniques that I had used then. I had created each quiz in a ScrollView – it seems to be frowned on now but I thought it appropriate at the time. The questions use a selection of radio buttons (only allows one choice), grouped check boxes (allows a pre-set number of choices) and each quiz has an edit text (user text input). When the user presses ‘Submit Answers’ it tells them how many points out of a maximum score and if they achieve a perfect score, it displays another message which tells them that they scored a maximum ” ” points (it varies between the quizzes). Finally, each individual quiz can be reset by pressing – you guessed it , the ‘Reset’ button. What’s not to like?

‘Bye for now, I’ll see you next time…

The first draft of the medical calculations app – created in Android Studio.

I wanted to create something useful and given my background in Nursing and all things medical, I was naturally inclined to come up with something that might prove useful to my former colleagues and those who perform a similar role as that is what I know most about.

One of the things that computers do well (and your mobile device is a sophisticated computer) is crunch numbers quicker than a speeding bullet and certainly faster than human brains and what is more, if they have been given the right instructions in the first place, they will do it faultlessly at every time of asking – better than humans there too then. In short, I wanted to simplify peoples lives by taking away some of those routine calculations. Here is my first attempt. It was written in Android Studio solely to work on Android devices. In later iterations I added extra functionality to it, of which I will tell you at a later time. For now, this is the first version:-

The first medical calculations app for Android.
Detail of Android version of Paediatric Resuscitation app for Android
The Menu
Links to useful websites.

If you want detail about how the resuscitation app works, please see the Flutter version post from a couple of days ago. I’ll talk about the fluid calculation app soon. See you later…

How to calculate the skin area of a child.

It is probably not on your usual list of daily considerations but for some people it is. Those people are very talented doctors who treat children and in particular very small children as this calculation is used to decide what dose of drugs to give to these children and to decide on other very critical treatments.

The calculation is:-

Body Surface area = the square root of ((weight in kilograms x length in centimetres)/3600)

The method is known as the Mosteller method.

The Flutter Version.
As it appears in the emulator in Android Studio.

Users type in the weight and length and press ‘Calculate’ then to reset the app press ‘Reset’ – simples…

Again, this app is quite niche but may prove useful if this is your line of work. The final outcome is likely to be that this will be included as part of a suite of specialist applications. In this form I hope to make it available for both Android and iOS. See you soon…

Paediatric Resuscitation App in Flutter.

You have recently read about how I spent a bit of time studying Flutter and Dart with a free course from Udemy. The first personal project that I have commenced is to convert a medical calculations app that I initially created in Android. It included an app to calculate drug and fluid doses used in paediatric cardiac arrest, a body mass index calculator, a fluid infusion rate calculator, a body surface area calculator (used to calculate drug doses for babies), and two metric unit calculators which work in different ways (volumes and lengths). In it’s original form, the app would only work on Android devices. I wanted to present an app or a series of apps that can be used on both Android and iOS so to recreate them in Flutter would be one way of achieving that.

I decided to convert each part of the original Android app separately and I started with the Paediatric Resuscitation dose calculator.

The Flutter version of my Paediatric Resuscitation Calculator.
The Android version (set in ScrollView).

When children get sick it is often not serious but they can deteriorate very quickly and when they do it is important to recognise the signs and act upon then quickly. Often it is to do with dehydration, sepsis due to infection, a low blood sugar or trauma and the story with which they present may give you clues as to what the problem is. A thorough assessment of the patency of their airway, their work of breathing, their circulation, their level of consciousness and any injuries over the whole of their bodies – correcting problems as you go in this priority order is the way to go – not leaving ‘any stone unturned!’. Hopefully, you can reverse the decline and make the child well again. This is the best outcome. Sick children tend to be very resilient to a point and it is up to this point that you have the best chance of success and this success comes by good assessment as above BUT if that window of opportunity is missed the sick child will ‘crash’ quickly and may even go into cardiac arrest. The calculations made by this app are those taught to Doctors, Nurses and other healthcare professionals in how to deal with very sick children and those who have gone into cardiac arrest. The Resuscitation Council UK and the European Resuscitation Council Paediatric resuscitation courses teach these calculations in the case of Paediatric Cardiac arrest. In practice, paediatric resuscitation teams are calculating these numbers as they chase down the hospital corridors to respond to the emergency but my motivation for writing this particular app was for the paediatric ward nurses and doctors who would be involved with resuscitating the child so that they can be be better prepared with drugs and fluids when the ‘team’ arrives. In my experience of being an instructor on Paediatric Resuscitation courses it seemed to me that whilst the attendees were able to do the calculations, they had to have a refresher about what formulae to use as they were not using them all of the time so if it were used it might save them preparation time and stress.

All of the calculations are based on the child’s age as this is reckoned to provide to most accurate calculations in this situation. Users of this app just type in the child’s age and the app will calculate the child’s (likely) weight, the size of uncuffed endotracheal tube (for those under 8years old), the size of cuffed endotracheal tube (for those 8 and over), how much of a DC electrical shock to give them – measured in joules and based on their calculated weight, how much crystalloid fluid to give as a bolus (isotonic sodium chloride or compound sodium lactate) which can be repeated if necessary, how much adrenaline to give as a bolus (which can be repeated every three to five minutes), how much amiodarone could be given if necessary and how much glucose can be given if necessary for very low blood sugar.

Not all of these calculations will be needed but by the same token some of the calculations would be appropriate for emergency treatment of very sick children, not just those in cardiac arrest. Young children particularly will collapse and even arrest due to low fluid volume – dehydration (due to diarrhoea, vomiting, haemorrhage or severe sepsis – the fluid calculation will be of particular importance), low blood sugar (so the glucose calculation will be important). It is unusual for a young child to suffer from a primary cardiac cause unless they were born with it. With severe dehydration there can be a salt imbalance which can cause cardiac problems. It is with older ‘children’ that a primarily cardiac cause might be suspected as adolescents and young adults can suffer from sudden arrhythmias which can cause collapse and cardiac arrest. This is mainly where the DC Shock and amiodarone calculations come into play most frequently as they are used to correct these arrhythmias. The DC shock is delivered by a defibrillator (in manual mode usually by a medical professional with proven rhythm recognition skills.

It is a bit niche but I think that it could be useful for those less familiar with the calculations but may be called to assist in the ‘resuscitation’ (including fluid resuscitation) of a child in a non-critical care healthcare environment such as a standard children’s ward. Once I finish the whole suite of calculation apps in Flutter, I will consult with a former colleague of mine from when I was a Resuscitation Officer who is Lead Paediatric Officer at my local (large) NHS Trust to see what she thinks about it. I showed her photos of the original Android version and she expressed an interest so we will see. Wish me luck!

For those of you that want to see pictures of Android Studio:-

Until next time, take care and stay safe…..

Flutter and Dart Studies.

I know, I have been away a little while but I have been learning new things. I have produced a few prototype apps since my graduation from the Udacity and Google Android Basics Nanodegree (that I have yet to tell you about) but one problem that I face is that they only work on one mobile platform – Android. I bumped into an old colleague of mine from my nursing days; she was a “Matron” and a lot of her work involved filling paper forms and then manually sending them in various directions, most of them digital. Together we came up with an idea for an app to help to automate the process which would save time and effort in her very busy day. I went away to start to design something suitable when I hit a major snag. I develop Android and the hospital trust where she worked issued Apple phones using iOS. It made me think and my solution for the future was that I would have to learn to develop apps for Apple devices too because I was going to hit this roadblock every time with any apps that I created. I wasn’t quite sure where to start. Too much time passed between my conversation with my ex-colleague and the opportunity passed for that project but there would be other times when I hit a similar problem so I was going to have to tackle it.

My initial course of action was to research how to create iOS apps and I found that I would have to look at Objective C, X Code and Swift with a nod towards OS X as well. The code should be similar to what I had become used to being C based languages like the Java that I have been developing my Android apps with. I figured that if I was to make my apps available to everyone I would have to cover Android and iOS (and possibly OS X). It was going to take some time to achieve.

I have had my (Photography) Instagram account for many years and initially I started to share my apps on that account but they were about as popular as a Rattle Snake in a lucky dip – very little response from my established followers who were really there to see my photographs. I opened a new Instagram account based on my Software Development exploits to discuss and share items related to that. One of the growing trends was Flutter – lots and lots of people were talking about it and saying that they were developing apps using it. I investigated and found that it could be very useful to me in overcoming my “problem”.

In case you are not familiar with it, Flutter – developed by Google, enables app developers to create apps once which can be suitable for both iOS and Android. It is not a perfect solution, some apps don’t do so well with it and I understand that it is a bit less swift on end user devices but I could put it to good use for most if not all of my simple offerings. Another piece of fortune; one of my new followers has a website that publishes vouchers for Udemy courses which are available for limited periods. I have taken advantage of this twice now; firstly for the Java course that I recently completed and then another which the trainers called “30 days of Flutter” which was 10 hours of video tuition about building Android and iOS apps using Flutter and Dart. The two work together but Flutter largely related to the User Experience/User Interface part and the Dart is the “doing” parts – where the number crunching goes on and it is written in .dart files.

I completed the course on the evening of the 17th of April 2021 and I am looking forward to adapting some of my Android apps and creating new ones using Flutter and Dart.

I still intend to learn how to code “Native” iOS apps but at least I can get some cross-platform apps out in the meantime.

That web-site where you can get vouchers for Udemy courses:- https://fastbooks.in/

I’ll be back to tell you more of my adventures soon – Stay Safe.