I think the problem you are going to run into is if they purchase both types of products at the same time.
you can test for an item being in the cart by ID using this code:
<?php
if($<yourCartName>->InCart("1") == true)) {
header("Location: other_cart.php");
}
?>