How does erection work? The physiological process of erection starts in the central nervous system where sexual arousal takes place. Then, it shoots through preganglionic parasympathetic nerves, triggering the release of nitric oxide in the penis. Nitric oxide causes dilation of the penis dorsal arteries walls as the corpus cavernosa get filled with blood, provoking an erection. So, for the erection to take place, there must be a psychological/sexual stimulus first; then, you must have an acceptable testosterone level in your blood stream for you to have a libido (sex drive or desire); finally, your penis arterial blood vessel walls must be relaxed.
Erection worst enemies
Stress (which causes the release of adrenaline, which is bad for your testosterone levels); alcohol, which also inhibits testosterone production; smoking; calcium channel blockers hypertension medicines; central nervous system depressants, such as barbiturates, morphine, alcohol, etc.; diabetes.