in reply to Inheritance

I'm not sure exactly what you're looking for. "Inheritance" is a term specific to object oriented programming that describes one way to say "This thing acts like this other thing, perhaps with some small changes."

Inheritance may be one way to solve what you're doing here, but I don't think it is.

You have a couple of options for making one variable or object available across multiple modules:

There are other options, but they're mostly variants of these strategies. I do suggest modularizing your code by behavior and duty, though. It has many other benefits.