
    The People of the State of New York, Respondent, v Kenneth Nilsson, Appellant.
   Appeal by the defendant from a judgment of the County Court, Suffolk County (Cacciabaudo, J.), rendered March 12, 1985, convicting him of robbery in the first degree, upon his plea of guilty, and sentencing him to an indeterminate term of from 2Vz to IV2 years’ imprisonment.

Ordered that the judgment is affirmed.

We are satisfied that there was no reasonable basis for ordering psychiatric examinations of the defendant pursuant to CPL article 730 prior to acceptance by the trial court of the defendant’s guilty plea (see, People v Armlin, 37 NY2d 167; People v Corwise, 120 AD2d 604). Moreover, the trial court made proper inquiry to ensure that the defendant’s waiver of, inter alia, his right to trial and to raise certain defenses (see, e.g., Penal Law §§ 15.25, 160.15 [4]) was knowingly, voluntarily and intelligently made (see, People v Mitchell, 90 AD2d 854; see also, People v Serrano, 15 NY2d 304; People v Wedgewood, 106 AD2d 674) and the defendant may not here challenge the factual basis for his plea (People v Riley, 120 AD2d 752).

Finally, the trial court was not obligated to sentence the defendant to an indeterminate term of from 2 to 6 years’ incarceration, which had been promised upon acceptance of a plea of guilty the defendant was thereafter permitted to withdraw (cf., People v Ifill, 108 AD2d 202; People v Grant, 99 AD2d 536). The defendant pleaded guilty a second time with the understanding that he would receive the sentence which was thereafter actually imposed and shows no basis to complain that the sentence was excessive (see, People v Kazepis, 101 AD2d 816). Mollen, P. J., Brown, Weinstein, Eiber and Harwood, JJ., concur.  