N95 Masks (Mar 30)

Last year, I spent many weekends with a heat gun, removing lead paint off the exterior of my house (built in 1910). Construction unit cost = 12 square feet per hour. Bought a box of 3M N95 respirator masks for the work, then misplaced it over the summer and bought another.

Covid-19 has pretty much turned the remaining masks into gold nuggets. I gave a few to high-risk friends.  Offered the rest to my GP, but they are already well-stocked, and using face shields as well as masks. The local hospital needs tons of masks, but folks have mobilized to sew them. A few N95s won’t make much difference there.

There’s good evidence that Covid-19 has a stealth mode: spread by people with no symptoms, via small droplets in the air from talking or breathing. There’s also good evidence that general use of face masks helps to reduce viral spread. China and the Czech Republic saw lower infection rates when masks were used widely.

It’s complicated, because protective gear is in desperately short supply. Where should they go?

Most people in Ithaca are staying home and/or physically isolating, but the grocery stores are still busy. I finally decided to donate the remaining masks to checkout staff at the local Aldi’s supermarket. They are crowded, with no self-checkouts. Maybe masks will slow down the transmission rate, and reduce the number of people who need the hospital.

Construction companies often have face masks or full respirators laying around.  It might be a good time to think about how best to allocate them, based on local needs.

Since masks and other PPE are in short supply, they will need to be reused and sanitized.  Low heat in an oven is the most convenient way to do that. One study says a pre-heated oven at 56° C (133° F) for 90 minutes, 67° C (153° F) for 60 minutesm or 75° C (167° F) for 30 minutes. A second study says 56° C (133° F) for 15 minutes is enough to kill the virus. A third study recommends 60° C (140° F) for 30 minutes. Take your pick.

If you have enough masks, you also can rotate them without additional treatment. The SARS-CoV-2 virus has a half-life of about 1.2 hours in air, .8 hours on copper, 3.5 hours on cardboard, 5.6 hours on stainless steel, and 6.8 hours on plastic. 4 days is the recommended minimum wait before reuse.

Dennis Kolva
Programming Director
TurtleSoft.com

We’re #1 for Covid-19 (Mar 26)

The USA became #1 for cases of Covid-19 today. We lapped both Italy and China in a single day. Globally, there are over a half million cases. It’s doubling about every 4 days, so expect a million next Monday.

Here’s a timeline for Ithaca. It probably is a good predictor for how the pandemic will unfold in other communities. I’ll keep it updated.

Mar 1: 0 cases. WHO warns about pandemic.
Mar 2-6: 0 cases.
Mar 7: 0 cases. NY declares state of emergency (76 cases in NYS).
Mar 8-9: 0 cases.
Mar 10: 0 cases.  Cornell bans events with 50+ people.
Mar 11: 0 cases.  Cornell plans switch to online classes on Mar 28.
Mar 12: 0 cases (15 tested).
Mar 13: 0 cases. Cornell ends classes, sends students home. County state of emergency.
Mar 14: 1 case.
Mar 15: 1 case (46 tested).
Mar 16: 2 cases. All NY restaurants, gyms, malls closed (960 cases NYS).
Mar 17: 3 cases (107 tested).
Mar 18: 6 cases (146 tested).
Mar 19: 6 cases (279 tested).
Mar 20: 11 cases. Non-essential NY businesses closed (7102 cases NYS).
Mar 21: 12 cases (449 tested).
Mar 22: 15 cases (451 tested).
Mar 23: 16 cases (592 tested).
Mar 24: 18 cases (666 tested).
Mar 25: 23 cases (731 tested).
Mar 26: 32 cases (1009 tested).
Mar 27: 48 cases (1191 tested, community spread).
Mar 28: 56 cases (1191 tested, 2 hospitalized).
Mar 29: 70 cases (1197 tested, 2 hospitalized).
Mar 30: 73 cases (1419 tested, 1 hospitalized, 1 recovered).
Mar 31: 76 cases (1419 tested, 1 hospitalized, 28 recovered).
Apr 1: 80 cases (1480 tested, 1 hospitalized, 33 recovered).
Apr 2: 87 cases (1553 tested, 2 hospitalized, 46 recovered).
Apr 3: 93 cases (1620 tested, 2 hospitalized, 51 recovered).

The hospital only has 8 ICU beds, so things may get dire quickly.  We’ll see.

I’ve been watching Coronavirus since it first hit the news in December, and started to prepare in February. And yet, despite the long advance warning, I probably still should have acted faster. Most likely, today’s 32 cases were first shedding virus around Mar 14. At that time I was still shopping, going to the gym, eating in restaurants. Slightly cautious, but more would have been better.

I have a hand-wavy theory that the human brain is hard-wired to calculate jumps between trees, from when we were small arboreal primates. The distance you fall from gravity is squared over time. The series goes 1-4-9-16-25-36-49-64-81-100. The same math also applies to throwing things. Also cars, and most other stuff we deal with in real life.

Epidemics and explosions are exponential. The series goes 1-2-4-8-16-32-64-128-256-512-1028.  It starts out slower than the gravity curve. Humans often are fooled by that, and think it’s no big deal. Then it catches up. Suddenly it’s 10x bigger. Another 10 jumps and it’s a million, when we were expecting 400. Another 10 jumps is a billion.

Dennis Kolva
Programming Director
TurtleSoft.com

Coronavirus & Table Clicks (Mar 24)

Here in New York, the Coronavirus storm is upon us. 20,875 cases with 15 locally, and growing. Ithaca is almost a ghost town. Hopefully it won’t get as bad here as in New York City.

The John Hopkins Covid-19 Tracker has gone back to tracking US cases for each county. It gives a clearer picture of where we all stand right now. Keeping that site updated must be a ton of work, and I really admire them for it. Last week it stalled out a lot, but they seem to have added servers to cope with the load.

The bad news is, confirmed cases are distributed throughout the entire US: big city, small city, suburban and rural. Right now it’s worst in NYC, then Seattle. However, everywhere else is only a week or two behind. Most of the regional differences are from lack of testing, rather than lack of infections.

The graph of the infection count keeps getting steeper. If you click to see the daily increase, it’s the same curve. The rate of increase in that one is also the same curve. Exponential growth works that way. The rate it gets faster keeps getting faster.

The way this pandemic plays out in each part of the US will depend a lot on the actions of state Governors and state/local health departments now. Balancing physical distancing with the need to get groceries and pay bills is going to be extremely challenging. We’re all in for some big changes.

Meanwhile, our staff has settled in to the new normal: isolated and ultra-cautious. We are back to programming, again.

A few weeks ago, two different types of tables were filling in data and looking pretty good. Then we clicked on one, and it crashed immediately, somewhere deep inside the MFC library.

It used to be possible to step through MFC source code to figure out problems like this. Unfortunately, that has become more difficult with newer versions of Windows. One option gave thousands of error messages in the compiler. The other option took hours to load up. Frustrating.

Luckily, taking a break from problems is often a good thing. Coming back afresh, we quickly found a nice CodeGuru explanation for the fix.  It only took a few minutes in the Class Wizard to get it working properly.

MFC is old and complicated. It’s going to be a slog. But we are making progress.

Dennis Kolva
Programming Director
TurtleSoft.com

 

Coronavirus & Construction #2 (Mar 20)

In the last post I did math to figure if and when Covid-19 overwhelms hospitals. The next few weeks will determine how accurate it was. Massive social distancing may prevent a crisis.

There is a second problem that may be more serious, with an even bigger impact on construction businesses (and everyone else).

By now, you’ve probably seen the “flatten the curve” graphic. If the R0  reproduction value is high, the number of cases is a steep bell-shaped curve. If it’s lower, then the curve is more shallow and the peak is lower. If people aren’t close together, R0 drops.

With an infection growth rate of 15% and no social distancing, half the US population will test positive for Covid-19 approximately May 31. At 25% growth it’s May 3. At 30% it’s April 26. The US is not ready for that size of widespread disaster. Just look at Italy or Iran. It’s worth the chaos now, to flatten the curve and have the next couple months be less insane.

Problem is, those curves don’t have a time scale.

To avoid high death rates, R0  has to be low enough to not overwhelm hospitals, and stay that way until nobody is catching the disease. Containment is unlikely with such a highly-infective virus, so it ends when almost everyone has caught it (resulting in “herd immunity”).

It’s not hard to calculate how long it takes to handle Covid-19 safely. It goes like this:

1. Start with US population (327.2 million).
2. Estimate how many will eventually get Covid-19.
3. Estimate how many of those get pneumonia.
4. Multiply that by average duration in critical care (about 14 days).
5. The result is ICU-days. Divide that by the number of ICU beds available (65,000 to 95,000). The final result is days required to flatten the curve.

You’ll notice there aren’t numbers for steps 2 and 3. This is a new disease, so there isn’t good data for those yet.  However, it’s possible to plug guesses into the spreadsheet, and see what results.

Assuming 70% of people eventually get Covid-19 (the best guess I’ve seen online) and 5% of them end up in intensive care (probably close to results from Wuhan and Italy), the curve needs to be spread out over 4.6 to 6.8 years to avoid zapping the health system. If 1% need ICU care, it requires 338 to 493 days. Of course, many folks are working on vaccines, but those will still take 12 to 18 months to test and produce. That’s a very long spell of social isolating.

Hospitals in the US are run for profit, or by non-profits that are chronically underfunded. To cut expenses, they eliminated excess beds and staff that would have come in handy, right about now. Japan has 13 hospital beds per 1,000 people. S Korea has 12, Germany 8, China 4, US 2.77.

I’m really not sure what the consequences will be for small construction companies, small software companies, or anyone.

Dennis Kolva
Programming Director
TurtleSoft.com

 

 

Why you should worry about Covid-19 (Mar 17)

I just made a spreadsheet with New York coronavirus data, to get an idea of how bad it is likely to get here, and when.

Looking at other countries, the most important factor is whether the hospital system is overwhelmed. If so (as in Wuhan, Iran and Italy)  the death rate is high, and it’s a national emergency. If not (as in Taiwan, Singapore, S Korea and most of China), then the pandemic is less of a disaster.

It takes 3 numbers to calculate the risk and timing:

      1. Virus growth rate. World-wide outside China, cases are increasing by about 15% per day. NY cases are growing by 30% per day. Calculating from R0 rate of spread (1.4 to 3.9 infections per case) and incubation period (5 days, range 2 to 14) gives numbers in about the same range.
      2. Hospital capacity. Different sources say 3,000 to 4,000 ICU beds in the state.
      3. Percent of confirmed cases that need intensive care. Most studies show it between 5% and 10%.

The most optimistic calculation says that NY will run out of ICU beds on April 15 (four weeks from today). The most pessimistic version says crisis hits March 31 (two weeks from today).

Different sources say the US has 45,000 to 95,000 ICU beds. Using the same logic, they all are filled sometime between April 3 and April 25.  Four weeks away, plus/minus 10 days. The math assumes that ICU beds are currently half full, but another 50% can be added on short notice.

Keep in mind that testing in the US has been woefully sparse. All confirmed counts are just a bare minimum. Actual infections could easily be 10x or 100x higher. However, that does not affect the timing by much. The numbers it changes just cancel out.

For local planning, many state health departments are now publishing case counts in each city or county. Wikipedia also is adding tracking pages for hard-hit states (search coronavirus + your state name).  Their basic pandemic page is at this link.  (update Mar 19: Politico has tracking of all Covid-19 test results for each state).

There’s a good visual of the NY growth curve on Wikipedia. Take your state’s current case count, and you can guess at what it will look like over the next week or two. All US states now have at least 1 reported case.

Also keep in mind that there’s a week or two lag between infection and testing/confirmation. It means that social distancing does not act quickly to reduce hospitalizations. You need to wait a week or two to see the benefits.

NY/NJ/CT closed all restaurants and bars yesterday. Everyone is panic-buying and preparing to hunker down. This is one situation where irrational fears are actually useful.

According to the math, we may just squeak by. To make it happen, social distancing has to reduce R0 to 1 or below, and start really soon.

Dennis Kolva
Programming Director
TurtleSoft.com

Coronavirus & Construction (Mar 13)

Not much programming progress this week: our staff has been distracted by pandemic news and planning. It’s hard to stay focused on code when something possibly-deadly is happening outside.

Coronavirus probably has been around ever since vertebrates first moved onto land. It lives in the respiratory system and spreads mostly via cough/sneeze droplets. Several strains exist in humans. They and rhinovirus cause most common colds. No big deal.

However, COVID-19 is a new variation. It jumped from bats to another mammal to humans last fall. People aren’t used to it, and that’s why it’s dangerous. This new virus is more infectious than influenza, and more lethal. Most people just catch a chest cold with slight fever, so they barely notice it (and spread it to others). 20% get pneumonia and need hospital care. Some of them die: especially if over 60, or in already poor health. With good medical care, the death rate is under 1% (still 10x as bad as the flu). When the disease spreads too quickly, hospitals are overwhelmed and 3% to 6% die.

Countries with significant deaths from SARS in 2003 were well-prepared for SARS-CoV-2. They contained the spread, and are almost back to normal now. It required a huge response in China, and less extreme actions elsewhere.

The rest of the world hasn’t done as well.  Things are real bad in Italy right now, and they turned deadly very quickly. The rest of Europe is only a week or so behind them. Conditions in the USA are more uncertain, since there has been so little testing here.  However, cases are already reported in almost every state. Celebrities are catching it. The shit is almost certain to hit the fan very soon. Exponential growth gets scary at this part of the curve.

It’s too late to stop Covid-19, but it can be slowed. Then hospitals aren’t overloaded, and fewer people die. Word is already getting out about the need for social distancing, but here are some thoughts more specific to construction companies:

      • Shut down for a while, if you can. If you are solo, this is a great time to get some  work done on your own house. If you have employees, can they handle a break? Isolation is the best way to protect your own health, and the health of your community.
      • If not, use face masks. N95 masks significantly reduce the spread of virus-laden droplets. “Easy breathe” masks won’t protect others if the user is infected, but a bit of duct tape over the outlet will fix that. Full respirators and haz-mats are even better if you can stand them. Fortunately, construction sites are less disease-transmittable than most workplaces, and they have other hazards that require masks.
      • Be clear with employees and subs. Send them home ASAP if sick, or don’t even let them come in. This might be time to start paying sick leave, if you don’t already. Emphasize the need for testing and self-quarantine. If you have an ear thermometer, it might help to check people for fever.
      • Stagger work hours & locations if you can. The less time people spend close to each other, the slower disease spreads.
      • Be clear with clients. If you work in client homes, let them know your plans. You might need to add plastic sheeting barriers, and sanitize more thoroughly at day’s end. Switch to outdoor work, if possible.
      • Take the usual precautions. Wash hands often. Cancel group events. Practice social distancing. Listen to local & state health departments. Check out the links below.

What you should do as a Business Owner
Covid-19 FAQs from Harvard U
CDC Covid-19 Website
Vox guide to Coronavirus
Johns Hopkins tracker (sometimes overloaded)

Please stay safe and healthy!

Dennis Kolva
Programming Director
TurtleSoft.com

Goldenseal Pro Progress- Tables & Beyond (Mar 2)

As of last week, breakdown tables are looking good in Goldenseal Pro for Windows. The code is clean and orderly. The appearance is pretty much as we’d like. It’s just a grid of little rectangles with text in them, but making that happen requires a surprising amount of code.

Many details are still unfinished, but our staff has moved on to other things for a while. There are several other types of tables in Goldenseal, and we might as well get them all working at the same time. We’ll come back to them after the entire interface is in place.

Table grids have a basic design issue: how do you enter data into the little boxes? Over the years, Microsoft Excel has approached it in two different ways: with a separate formula bar, and with an edit box that pops up when you click in a cell. Mac Finder and Windows Explorer edit in place after a delay, though it’s often easier to right-click and choose Rename.

The current version of Goldenseal also uses edit boxes that appear when you click. However, our tables are more complicated. Some cells are just text; some show a popup button and a menu list; some are check boxes or padlocks. It took a lot of programming time to get them working properly, and they still aren’t perfect.

When we worked on the Mac version last year, it was very hard to get edit-in-place fields working (especially for the smart fields that pop up a list of items). We finally gave up and tried a third approach: a separate window that pops up when you double-click in a row. Kinda like a little data entry window for a single breakdown item. It seemed like a big improvement over the current approach. Less cluttered, better use of space, easier to modify in the future. Most likely we will do the same thing for breakdown tables in the Windows version.

Right now we are working on Preferences, and the little windows that manage lists of payroll tax tables, cost categories, and many other details.

In the Mac version, there was a worrisome database bug that appeared when a breakdown table opened for the second time. Fortunately, it happened in the Windows version also, and it was easier to debug there. Working with code that is all in the same programming language really is easier. The bug wasn’t in the database code, after all. That was reassuring.

Dennis Kolva
Programming Director
TurtleSoft.com

Goldenseal Files and the Internet (Feb 18)

A long-time user recently posted a message about their use of OneDrive to run Goldenseal from multiple computers. They store company data in the cloud, rather than on a local drive.

A warning: we have not tested Goldenseal for use with files stored remotely on OneDrive, iCloud, DropBox, Google Drive or other remote file services. We designed Goldenseal to save data on a local disk (hard drive or SSD), or to a local server if you have the multi-user version. Saving files over the Internet is much riskier.

Many apps have relatively small files that are easy to keep in synch. Some apps with large files only add new info at the end of the file, so there isn’t much to change with each file update.

Goldenseal company files are more difficult because they are big, and because changes are scattered through the entire file. That makes it harder to sync data between two locations. For example, a new material purchase posts changes to the vendor account, the job account, and a couple of utility accounts. It may also updated prices in some Cost Items. All those records could be anywhere within the file. If they get out of sync, you will have mystery accounting problems later.

Even worse, if records change in size, Goldenseal will move them to somewhere else in the file where there is available space. If the indexes that store record locations get out of sync, the file will have serious problems. You may lose data, or the file may become completely unusable.

There definitely will be problems if more than one person uses a remote file. If two users both change a record at about the same time, one set of changes will probably be lost. You’ll get mystery problems later.

Even with one user, a remote file is more risky. Our code is careful to save all changes to disk at the same time, so there is only a small fraction of second when a crash could cause data corruption.  OneDrive and iCloud transfer data to and from the remote file at unexpected times. The update process may take many seconds. It means more opportunities for something to go wrong.

If you do decide to use a remote file despite these warnings, use the Verify File command frequently to check for file damage. Also, please send us the exact text of any error messages you see. It helps us make Goldenseal more bullet-proof. Most of our messages include the source code location where the problem occurred, so include that in your error report.  It makes debugging much, much easier.

Goldenseal multi-user currently uses Unix sockets to communicate over the network. It locks records while they are in use, so another user won’t ever conflict (they can view that record, but can’t change it).

To be technical, we use TCP/IP to send messages between clients and the server. They can travel over a wired or wireless LAN (local area network), or over an Internet connection. When a client looks for a server, it currently broadcasts via UDP.  That can’t go out into the general Internet. A few users have been successful at setting up a VPN (virtual private network) to allow UDP to broadcast over it, but the process is not easy. We tried it here but gave up.

As a 64-bit app, Goldenseal Pro can use more modern Internet access tools.  That will allow us to set up a local server that can be reached by any Internet-connected device: laptop, phone, pad or whatever.

Dennis Kolva
Programming Director
TurtleSoft.com

 

Running Goldenseal on Macintosh (Feb 7)

For the past 5.5 years, this blog has covered our efforts to update Goldenseal into a 64-bit app. To summarize:

1. We did not finish the 64-bit update (Goldenseal Pro) in time for the release of Mac OS 10.15 Catalina last October.
2. The current Goldenseal 4.96 for Mac is a 32-bit app that will not run on Catalina or future Mac OS versions. It does run on Mac OS 10.14 Mojave and earlier.
3. The current Goldenseal 4.96 for Windows runs OK on Windows 10, and anything back to Win 98. However it has annoying screen drawing problems caused by its reliance on Apple’s QuickTime.
4. Goldenseal Pro for Mac is now on hold, and we are working exclusively on Goldenseal Pro for Windows until it’s done. The update removes QuickTime and its problem, and has many other improvements.
5. Whether we ever finish Goldenseal Pro for Mac depends on Apple’s future plans for Macintosh. Hopefully we will know more after the WWDC in early June.

In the meantime, our Mac users are upgrading to Mac OS 10.16 Catalina, or considering it. Here are some options on how to cope for the next couple years.

For less than $100, an External SSD in an excellent addition to any computer setup. If you have a USB 3 or USB C connection, it will run faster than an internal HD. 500GB is big enough to split into 2 or 3 partitions, so you can install a different OS version on each. Use Startup Disk in System Preferences to switch between OS versions.

Many iMacs and Mac Minis allow you to add an SSD as a second drive internally. It will be faster than an external, but it may be a difficult install. I updated one Mini that way, but will never do another.  It was a tight squeeze near fragile components. Too much risk of failure.

Since storage is so cheap, I think it’s wise to always install new OS versions on a new, empty partition, rather than overwriting your current system. That way you can test it out, and revert painlessly if needed.  Carbon Copy Cloner is a great way to move entire disk contents from one place to another, if you want to update the internal drive later.

In general, a Mac is optimized for the OS version that was out during its release. You can install newer OS versions, but not older ones. So any model from early to mid-2019 or earlier will still run Goldenseal using OS Mojave. Anything newer probably can’t.

If you have a big monitor and a second Mac, consider a KVM switch. It allows you to use just one monitor, mouse and keyboard, and move quickly between multiple machines. I personally use a 4-port ioGear DVI switch, with 3 Macs and 1 Windows attached (sometimes 2 & 2).  Most KVMs are in the $40 to $200 range. Be aware of the cable type (VGA, DVI or HDMI). You may need adapters if the computer age range is wide.

Finally, external hard drives are also cheap these days: e.g. $60 for 2 terabytes. Give them multiple partitions and you can use one for Time Machine, and the rest for backups and older OS versions. It may come in handy if there’s an app you want to run, that capped out at Sierra or earlier.

For the long haul, it’s still too early to predict where the Mac is headed. These days it is less than 10% of sales for Apple. They’ve prioritized accordingly for at least the past 5 or 6 years. On the other hand, Macintosh is still bringing in a steady $25 billion a year (about the same as Tesla sales for 2019).

Dennis Kolva
Programming Director
TurtleSoft.com

 

 

 

 

 

Goldenseal Pro Progress- Windows & Macintosh (Jan 28)

Our staff is still working on code for breakdown tables in Goldenseal Pro for Windows. The starting point was GridCtrl sample code, available online. After removing 2/3 of that, we are now revising the remainder to include the best ideas from our original table classes (plus Cocoa’s NSTableView).

It’s possible we should have just started from scratch. But Windows and MFC have many quirks, and most likely we would have spent many frustrating weeks or months learning those the hard way. Better to use something that actually works at the start.

Meanwhile on the Mac side, it’s not looking good for the future of Objective-C and Cocoa.  All signs point to them being retired soon, and replaced with the new Swift language and SwiftUI framework. Moving to Swift would be much harder than Cocoa, well beyond our abilities.  So, it’s not looking good for the future of Goldenseal Pro for Macintosh either.

Microsoft is working on WinUI 3, which is a grand plan to modernize its developer tools. In theory, WinUI 3 will allow us to gradually replace our GUI code with more modern controls. They’ll look better, work more smoothly, and be more compatible with future OS versions.

Of course, Microsoft is a big corporation that doesn’t always deliver on its promises. Sometimes it produces products that suck. But at least their process is visible so we can plan around it. As turtles living under the feet of elephants, it’s kinda nice to know where they are headed.

Meanwhile, we filed a support incident with Apple Developer Tech Support in November, trying to get better info about their plans for Cocoa and Objective-C. We also emailed tcook@apple.com.

Apple DTS replied in late December that they don’t release future plans.  We then asked if anyone at Apple will talk with small developers like us. Yesterday they just replied again that they don’t release future plans. We didn’t hear from Tim or his assistants at all. We are still trying to find someone else at Apple who actually listens to developers, but it may be a futile task.

Back in TurtleSoft’s first decade, Apple had a dedicated manager for the A/E/C market (architects, engineers and construction).  Besides that, there were several other Apple employees that we could talk with. All that evaporated when Apple almost died in the late 90s, and it wasn’t replaced when they became prosperous again.

Swift and SwiftUI look great for building small phone apps.  They are not good for building large desktop apps such as ours.  We really need easy linkage to C++, and a promise that it won’t require major rewrites every 5 years. Windows delivers all that: if anything they have too much backwards compatibility. Apple has been the opposite, and they are getting worse at it.

It wouldn’t hurt for our die-hard Mac users to contact Apple, and let them know that you still need specialty apps that run on the Mac desktop. Otherwise, the future appears to be a Macintosh that is pretty much a big-screen iPad. Lots of pretty little apps but no software for business.

Dennis Kolva
Programming Director
TurtleSoft.com