Optimising mobile apps for healthcare

15 April 2024

Galen Murdock, CEO and co-founder, ShareMy.Health

Galen Murdock, CEO and co-founder, ShareMy.Health

Image copyright ShareMy.Health

Optimizing health care with mobile applications and services offers huge benefits to professionals and patients. But problems with internet connectivity can blunt the effectiveness of mobile health solutions in communities and rural areas.

In developing nations in Africa and Asia, where mobile infrastructure can vary wildly in quality, connectivity issues can have devastating impacts on health care. And yet, these challenges can be overcome, maximising the positive health outcomes from seamless and accurate data sharing over wireless networks.

Over 200 million children suffer from malnutrition, causing 45% of deaths in children under 5. There is no more urgent need for reliable mobile health technology in low- and middle-income. Over $9 billion is spent annually on global nutrition efforts, yet almost all nutrition programmes addressing the problem are run on paper or spreadsheets. This time-consuming and slow process thwarts the collection and sharing of vital individual health data and more critically, the interventions needed to prevent or reverse malnutrition in a child. For example, it can take anywhere from 3-5 months for a mother to learn the nutrition status of her child. Since good health during the first 1,000 days of a child’s life are critical to avoid irreversible brain damage and stunting, timely communication saves lives.

Enter the innovative solution pioneered by my team at ShareMy.Health: a mobile app enabling nonprofits, families, and governments to end malnutrition — all without the internet. Vital data gathered in the child’s home, or a community health centre can be fed back to the cloud when only one device has an internet connection. When community health workers or parents enter a child's height and weight or mid-upper arm circumference (MUAC), our mobile app generates a set of WHO-based scores including Weight for Height, Height for Age, and Weight for Age, along with user-friendly nutrition descriptions. The system then guides the user to choose from applicable interventions for the child – especially those sourced from local resources – ranging from visiting a health clinic to taking essential micronutrient supplements.
Our goal to achieve near real-time communication used to be challenged by poor connectivity. In many developing regions, cellular connectivity, the primary internet access method, is plagued by intermittency or outright unavailability. This forces health workers back to inefficient paper methods, risking non- compliance with privacy laws and delaying life-saving care to the most vulnerable children in the world.

Research underscores the impact of connectivity issues on digital health initiatives. A study published in the National Library of Medicine highlighted lack of infrastructure, lack of equipment, and technological gaps the three most prevalent digital health barriers in low- and middle-income countries. Despite improvements, the digital divide remains, with 17% of sub-Saharan Africa experiencing a coverage gap. While 4G coverage in continents like Africa is around 50%, lower income groups tend to be more likely served by 3G networks. And even when there is available connectivity, it is either not reliable or not affordable. For example, 1GB of cellular data in Ghana costs 9% of a struggling family’s monthly income. Caregivers and families cannot afford to wait until this telecommunications gap is closed.

ShareMy.Health needed a combination of peer-to-peer mesh networking and distributed database software to replace paper and spreadsheets. During my graduate training in computer science and later in industry, I spent years fine-tuning the features and performance of remote procedure call (RPC) frameworks, overlapped I/O on TCP/IP, distributed objects, web services, occasionally-connected APIs, and more. I knew enough to know that we did not want to create our own offline technology, let alone create our own peer-to-peer data replication technology. I saw numerous PhD students write dissertations on only small fractions of this space.

Our breakthrough came from adopting offline data synchronization technology from Ditto, trusted by Delta Airlines, the U.S. Air Force, and even fast food restaurant chain Chick-fil-A. Late one night, frustrated by months of searching for offline sync technology that had not been gobbled up by database companies or expensive low-code platforms, I stumbled upon Ditto. Sceptical, thinking it was too good to be true, I dove into research mode.

I examined their abstraction layers for iOS and Android in their sample code, their approach to eventual and causal consistency, their topology of ‘small’ and ‘big’ peers, their thoughtful implementation of offline authentication and role-based access control, how they mitigated network saturation, and most importantly, their ‘rainbow bridge’ which doggedly uses all available radios in the device to securely communicate with any other authorized device. I read several underlying research papers, compared Ditto to progress made by other companies, got a feel for their growing edges, speed of development, and exceptional documentation. Through it all I gained a conviction for how flight attendants, jet fighter mechanics, and restaurant staff could operate independently of an internet connection, providing more resilience to outages, enhanced speed, and flexible control to deliver a reliable end-user experience for every customer.

In the ShareMy.Health app, Ditto’s technology automatically manages the complexity of using multiple network transports - such as Bluetooth, P2P WiFi, and Local Area Networks -- to find and connect to other devices and then synchronize all changes made to a medical record. Their use of Conflict-Free Replicated Data Types (CRDTs) provides a consistent view of the data for every device. When our clients are depend on us to operate a large health screening for over 700 children, Ditto delivers at scale. When there is a network interruption, every ‘person’ document and its screening information remains consistent, always operating from a local store. When the connection again becomes available, each document is replicated and resolved atomically, eliminating the possibility of partial updates to one person’s record.

Peer-to-peer data synchronisation is fraught with challenges. Mesh networks can generate huge volumes of data that overwhelm small devices if each node aggressively tries to sync every piece of data. Ditto’s Small Peers only synchronize data they explicitly request, giving developers complete control over storage and bandwidth usage and to implement eventual consistency. In contrast, the Big Peer synchronizes as much data as possible to implement causal consistency, always resolving conflicts along the way.

Since offline devices update at different times, Ditto’s replication must account for incoming data documents with different schema. For example, if a device is offline and therefore outdated, it should still be able to read new data and sync. The remedy lies in how Ditto’s protocol provides a device a reliable order of changes that can be inspected, including incorporating metadata about schema changes over time.

The impact of this technology partnership is profound. With a global nonprofit, we launched nutrition screening in Western Africa (Ghana, Sierra Leone, Liberia, and Nigeria), dramatically increasing screening efficiency and volume. By replacing paper-based processes with our digital solution, processing time per child was reduced from 25 minutes to 8 minutes, enabling a 2.5-fold increase in screening capacity. Ditto’s secure, reliable connectivity and data synchronization technology allows for faster malnutrition assessment and intervention, enabling ShareMy.Health to transform child nutrition programs by providing immediate, life-saving feedback to parents and health workers.

Using Ditto’s mesh networking and distributed database, the ShareMy.Health app is now ‘offline-first,’ meaning it will always operate while disconnected, and while connected will communicate immediately with other ShareMy.Health devices. Families can screen for malnutrition in the comfort of their homes and our platform will automatically relay their health data to the cloud the next time another ShareMy.Health user is in range. Regional and headquarters staff can immediately monitor and evaluate family, community, and national progress.

Looking ahead, we are extending our solution to strengthen maternal and child health by helping mothers track supplement adherence and breastfeeding. Paper and spreadsheets can’t encourage behavioral change as well as digital health apps. ShareMy.Health and Ditto are just beginning to leverage the power our partnership as together we transform the landscape of maternal and child nutrition.

By harnessing the power of offline data sync technology, digital health apps can reach the most remote areas of the world - a vivid reminder of how something as simple as software can transform lives across the globe.