There was only oil in it and there is no smoke when I cook in other pans. Also the heat was medium and I'm afraid if I turn the heat any lower that my meal will be under-cooked
Different oils have different smoke points. If your oil is smoking it's simply too hot.
I'm assuming you're using fresh oil. Oil that has broken down because it's been reused (after frying, e.g.) or because it's older and has not been stored properly may have a lower smoke point and will most likely be rancid. Always store your oil away from heat, light, and air.
The smoke point of an oil won't change based on the pan, but some pans conduct differently from others, so it's possible that a cast iron pan, for example, may cause oil to smoke faster than a carbon steel pan does, simply because the cast iron pan is getting hotter where your flame or burner is (cast iron does not conduct heat evenly).
Depending on what you're cooking you generally want to heat your pan first then put in the oil when the pan is at the right temperature and then put the food in. If you're cooking with cast iron it's best to heat up your pan on low or medium for a while (several minutes) to let it heat evenly and then put in the oil then the food. If you're searing steak you want the pan ripping hot. One good trick with cast iron is to heat it in the oven then transfer it to the stove top for your searing.
If you provide more information about what oil you're using, what kind of pan, what kind of heat source, and what you're cooking, people here I'm sure will provide additional helpful answers for you.