Hello, Gentleman .
Cough from last few months with mucus ( phlegm or expectoration ) and history of smoking
are all an indication of asthmatic allergic bronchitis
( as you mentioned that there is breathlessness ) .
As you mentioned that yellow color mucus also present so all these symptoms may be due to , these includes.
1 Asthmatic allergic bronchitis as I mentioned above , clinical history and [physical examination will find out this thing.
is the another most common cause of these symptoms , so get in blood for C B C , E SR & X ray chest .
is the another most common cause so get in X RAY chest and blood examination for C B C and E S R, SPUTUM FOR A F B.
As far as concerned about pain in the knee joint , that is a different thing and for this consult an orthopedic surgeon and get his opinion.
For cough and congestion consult a physician and get his opinion.
Avoid hay , dust , mite , SMOKING , fine dusting powder, mold , pollen as these are predisposing factor for allergy