To the extent that the record on appeal permits review, defendant has not established a violation of his constitutional right to a speedy trial (see People v Taranovich, 37 NY2d 442, 445 [1975]). There was a 40-month delay and defendant was incarcerated for approximately half of that time. However, the People have satisfactorily explained the delay, most of which was attributable to the unavailability of an important witness (see e.g. People v Cruz, 293 AD2d 412 [2002], lv denied 98 NY2d 674 [2002]). In addition, the charges were very serious, and defendant’s claim of prejudice is unpersuasive.
Defendant made a valid waiver of his right to appeal, in a colloquy with the court as well as in writing (see People v Ramos, 7 NY3d 737 [2006]; People v Lopez, 6 NY3d 248 [2006]). That waiver forecloses review of defendant’s contention that the sentence was harsh and excessive. As an alternative holding, we perceive no basis for reducing the sentence. Concur — Saxe, J.P, Catterson, Moskowitz and Acosta, JJ.