I hope so!
But one of the pieces of advice CS Lewis gives is not to pray last thing at night, but to schedule daily prayer for when you are most alert.
I can perceive the necessity for this when I read Lewis's correspondence and the sheer number of people and things he would systemically cover in his daily prayers, and for long periods of time. Clearly, he would not be able to get through this list - especially not kneeling with head bowed and eyes shut - if he was drowsy. He would simply fall asleep.
But I would suggest that prayer while drowsy - in and of itself - is not a bad thing, perhaps a good thing.
I keep returning to consider the vast literature of mysticism being associated with altered states of consciousness, of visions and revelations given in trances and as dreams.
And the ascetic practices of monks and hermits include not just fasting and extremes of temperature, but 'vigils' of continuous prayer while sleep deprived - which suggests a semi-deliberate attempt to induce altered states of consciousness.
Now, while this kind of endeavour is spiritually hazardous if it is, or becomes, focused on the getting of 'religious experience' for reasons of pride, power or entertainment - a hazard which is recognized by the phenomenon of spiritual fathers to supervise ascetic monks - there does seem to be some kind of benign protection accorded to the sleeping state, which renders the sleeper resistant to these hazards.
And of course, drowsy prayer, or prayer in a state of altered consciousness, may be the only possible kind of prayer for some people who - for whatever reason - sleep deprivation or disturbance, medication, illness, drugs or withdrawal of drugs - seldom or never have 'a clear head'; and must go through life with greater or lesser degrees of 'clouded consciousness'.
If such people are to pray, then it will necessarily be in some kind of semi-alert state.
Prayer in a drowsy condition will be shorter and simpler and of narrower coverage - but I would suppose that will not trouble God, since He seems to value the prayers of children most of all.
And, given the state of busy distraction in which so many adults live nowadays, it may only be in that drowsy twilight between sleeping and waking that our minds are stilled sufficiently to listen and hear - as well as to speak: to perceive, albeit transiently, that prayerful communication is a two-way street.