Programatically saving a field collection containing taxonomy terms

There is plenty of information on how to save a field collection (D7) in code, but nothing about collections containing taxonomy terms.  It requires a slightly different array structure (including 2 'value' fields instead of 1).
 
It seems silly that it needs the $term object AND the $term->tid both passed to it since tid is in the $term object but aren't we all fond of the silly?  
 
<?php

function _save_field_collection($node, $values) {
 
// Load the controller class file.
 
module_load_include('inc', 'entity', 'includes/entity.controller');

// Setup the values in the structure expected by the field_collection entity.
 
$fc_values = array(
   
'field_name' => 'field_example',
   
'field_example_taxonomy' => array(
         
LANGUAGE_NONE => array(array(
           
'tid' => $values['term']->tid,
           
'taxonomy_term' => $values['term'])),
        ),
  );

 

$entity = entity_create('field_collection_item', $fc_values);
 
$entity->setHostEntity('node', $node);
 
$entity->save();

}

?>

 

Joshua Walker