Some of those in attendance for the speech said they were inspired by his appeal for progress in Kenya.
Obama delivered the message at an indoor arena filled with thousands of young people Sunday in Kenya, the ancestral homeland of his father.
Shebab fighters have staged a string of suicide attacks and bombings on Kenyan soil, including the April massacre at Garissa university, in which 148 people died.
The US president said bad things happen when governments get into the habit of treating people differently.
It will be the first time an American president addresses the AU.
“I’ll be back”, he said.
Homophobia is on the rise in Africa and espousing evangelical Christian values is a major vote-winner in many countries.
WARNER: Well, just picture American flags being waved and a lot of people saying, Obama for president in 2017 – Kenyan president.
There he had discussed trade and security but also called for greater human rights and warned of the dangers of corruption.
US President Barack Obama landed in Ethiopia on Sunday (Jul 26), beginning a two-day stay and becoming the first American leader to visit Africa’s second most populous nation.
Nairobi has witnessed a massive security operation, with parts of the usually traffic-clogged capital locked down.
Mr Obama will also highlight efforts to support African youth by visiting a regional centre for his Young African Leaders Initiative, a programme to help cultivate the next generation of African leaders.
He also urged Kenya to “embrace diversity”, a clear reference to gay rights.
On corruption, Mr Obama said money spent on bribes would be better paid to someone “doing an honest day’s work”.
“We will stand shoulder to shoulder with you in this fight against terrorism – for as long as it takes”, Obama said during Sunday’s speech.
But he also spoke about the opportunities the continent offers.
“That was the first time my name meant something and that it was recognized”, the president said.
On this trip, Auma Obama said, it was her brother who gave her a ride from that same airport in the “Beast”, the armored limousine shipped over from the U.S. before the president arrives in a country.
“Obviously this is personal for me”. When I was in college, and my father was here, I wrote him a letter telling him of my hope to visit.
The president also laid a wreath at the memorial site of the former US embassy destroyed in an Al-Qaeda attack in 1998, standing in silence in memory of the 224 killed in the twin bombings in Nairobi and Tanzania.
The courts, banks, schools and other businesses were shut after the government announced some key roads will be closed to provide way for Obama due in Nairobi on Friday evening.
Obama, who is no stranger to the dance floor and made headlines for his moves throughout his presidency, quickly picked up the maneuvers during the Nairobi event.
“We recognize the fact that as the most protected individual in the world, there will be some security measures undertaken by his team which could include the temporary disruption of mobile signals close to where the President is at any given time”, Safaricom said.
Steve Case, co-founder of America Online and chief executive officer of the venture capital firm Revolution LLC, who attended the entrepreneurship summit, said Nairobi now has a “vibrant startup community” and anticipates several companies will go public with valuations in the billions of dollars in the next few years.