Use a third-party tool such as Caffeine, Don't Sleep or an alternative. They generally act by simulating a keypress or reporting a very important task that cannot be interrupted. Of course, check that the application is compatible with lab software.
You might also consider switching OS, if feasible, to one that's still supported. (A location I where I worked kept Windows 3.1 running on one PC until well into Windows 8's reign, but finally chose to use new software!)