How to set setup time for a work center in a Production which is dependent on previous production.

Hi, We are dealing with a client who manufactures Bulk Item on contract basis.So he is involved in producing different Bulk Products,But when ever the Product changes the machines used in the production should go for cleaning where those cleaning time depends on the previous product produced on it.

I have thought of taking average time of all the “Cleaning times” that will take from different products to a particular product and using it as a "set up " time for this particular product.But it is not fulfilling the requirement of client since he wants this “Cleaning time” to be consider in planing.We are using AX 2012 for this client. SO can any one please suggest me How to handle this.

Thanks in Advance