EntityMetaDataWrapper exception when calling commerce_cart_product_add()
You are using commerce_cart_product_add wrong.

You can pretty much replace your entire code with:

$product_id = ...; // You need to product id, from somewhere, you can get it from the SKU
commerce_cart_product_add_by_id($product_id);