Former U.S. President Barack Obama delivered the Nelson Mandela Annual Lecture in Johannesburg Tuesday. The event marked what would have been Mandela's 100th birthday.

"It was in service of this long walk towards freedom and justice and equal opportunity that Nelson Mandela devoted his life," Obama said.

Obama focused his speech on the values Mandela stood for during his life — including democracy, diversity and equal opportunities for all.

"Through his sacrifice and unwavering leadership and perhaps, most of all, through his moral example, Mandela and the movement he led would come to signify something larger. He came to embody the universal aspirations of dispossessed people all around the world," Obama said.

Obama also seemingly touched on politics in the U.S.

"But given the strange and uncertain times that we are in — and they are strange, and they are uncertain, with each day's news cycles bringing more head-spinning and disturbing headlines — I thought maybe it would be useful to step back for a moment and try to get some perspective," Obama said.

"Politicians have always lied, but it used to be if you caught them lying, they'd be like, 'Aw, man.' Now they just keep on lying," Obama said.

This was Obama's first visit to Africa since he left office. About 15,000 people gathered to hear his lecture.