The order dmorton91 is talking about is the order in which the events were published. This is the default for the API call you are using. So if you publish an event 2 days out and then publish an even 1 day out. the 2 day out event will be in the [0] spot in the entry array returned.
I had the same problem so here is the code to fix it so the next event by start date and time will publish.
if (isset($feed->feed->entry)) {
//mod to get soonest start date
$entries = count($feed->feed->entry);
$order = 0;
$closestid = 0;
$mostrecentdate = strftime(strtotime('+1 years'));
$ytwhen = 'yt$when';
while($entries > 0){
$entrystart = strftime(strtotime($feed->feed->entry[$order]->$ytwhen->start));
if($entrystart < $mostrecentdate){
$closestid = $order;
}
$entries--;
$order++;
}
// We have a live video!
$videoFeedUrl = $feed->feed->entry[$closestid]->content->src;