If you wanted to pose this as some sort of new tech that maybe has a drawback to it (like requiring a full-body suit for the sensors) I guess that might be fine, but I don't think that illega is necessary. Remember, you're simply automating something that the pilot can do anyway so that if they're injured, they don't have to find that one little switch whilst under pressure.
You could even have it set to eject if one type of ammunition cooks off but not another, so those AP rounds for your AC/5 might not be a worry, but if that ton of MG ammo goes up, you're out of there!