I used to by a shy junior developer. What helped me was that the environment was very friendly and whenever I spoke, I was heard. Not just heard, but if my suggestions were good they enacted upon. If not, I was explained why.
I also had many casual discussions with my manager so that helped me open up with him. Later I had discussions with other (equally welcoming) senior devs. Now the whole team feels like friends to me and I generally don't shy in speaking up.