(Reuters) - China's Sun Yang has suffered a number of setbacks in the build up to the Rio Olympics but the freestyle specialist said his controversial past has made him more determined to defend his Olympic titles in the Rio Games.

Sun served a three-month ban in 2014 after testing positive for a banned stimulant, spent a week in jail for crashing a car driven without a license, and most recently was involved in an altercation at last year's the World Championships last year.

The 24-year-old also was also suspended from taking part in any commercial activities by Chinese swimming officials for missing training sessions in 2013.

However, the 1,500 freestyle world record holder said he was looking to learn from his experiences.

"I think I've grown more mature, I won't have a second chance to experience the prime of my athletic career," the Chinese swimmer was quoted as saying in the China Daily.

"So I am fully investing my time and energy in the pool.

"Respect is always earned through hard work. It's not just given, no matter what you won in the past. I am still young and I am still hungry for more titles."

A gold medalist in the 400 and 1500m four years ago, Sun set the fastest time in the 200m freestyle this year at the June international meet in California.

"No one can be 100 percent sure to win gold at the Olympics, but we don't need to question Sun's ability to do that if everything goes well in training," Sun's coach Zhang Yadong added.

"I have faith in him to win all his events in Rio."

(Reporting by Nivedita Shankar in Bengaluru, editing by Pritha Sarkar)