Hi, thank you for contacting JustAnswer.com. My name is Russell. I will do my best to provide the right answer to your question.
(I regret that I am not able to offer Live Phone Call service at this time; However, your request is still open to other Experts in this category, and one of them may pick up on it at any time.)
Did the legacy 30mm lens ever work with your Pentax K1 camera body?
And, what is the maker name of your legacy 30 mm lens assembly, please?
Do you have other lenses to use with the Pentax K1 body?
Have you tried removing the lens assembly, then cleaning its contacts (on the lens mount side of the lens assembly) with a clean dry soft cloth, wiping gently so as to not wipe off the rather thin conductive coating on those electric contacts - ?
I fear that I cannot help further with this case.
I have Opted Out, opening the case to other Experts in this category - but still able to respond, offer advice, and rejoin the case.