You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* @param abs_time Absolute timeout time, referenced to Kernel::Clock.
142
+
*
143
+
* @return Pointer to memory block that you can fill with mail or nullptr in case error.
144
+
*
145
+
* @note You cannot call this function from ISR context.
146
+
* @note the underlying RTOS may have a limit to the maximum wait time
147
+
* due to internal 32-bit computations, but this is guaranteed to work if the
148
+
* wait is <= 0x7fffffff milliseconds (~24 days). If the limit is exceeded,
149
+
* the wait will time out earlier than specified.
150
+
*/
151
+
T *alloc_until(Kernel::Clock::time_point abs_time)
152
+
{
153
+
return _pool.alloc_until(abs_time);
122
154
}
123
155
124
156
/** Allocate a memory block of type T, blocking.
@@ -132,10 +164,13 @@ class Mail : private mbed::NonCopyable<Mail<T, queue_sz> > {
132
164
* due to internal 32-bit computations, but this is guaranteed to work if the
133
165
* wait is <= 0x7fffffff milliseconds (~24 days). If the limit is exceeded,
134
166
* the wait will time out earlier than specified.
167
+
* @deprecated Pass a chrono time_point, not an integer millisecond count. For example use `Kernel::Clock::now() + 5s`
168
+
* rather than `Kernel::get_ms_count() + 5000`.
135
169
*/
170
+
MBED_DEPRECATED_SINCE("mbed-os-6.0.0", "Pass a chrono time_point, not an integer millisecond count. For example use `Kernel::Clock::now() + 5s` rather than `Kernel::get_ms_count() + 5000`.")
/** Allocate a memory block of type T, blocking, and set memory block to zero.
219
+
*
220
+
* @param abs_time Absolute timeout time, referenced to Kernel::Clock.
221
+
*
222
+
* @return Pointer to memory block that you can fill with mail or nullptr in case error.
223
+
*
224
+
* @note You cannot call this function from ISR context.
225
+
* @note the underlying RTOS may have a limit to the maximum wait time
226
+
* due to internal 32-bit computations, but this is guaranteed to work if the
227
+
* wait is <= 0x7fffffff milliseconds (~24 days). If the limit is exceeded,
228
+
* the wait will time out earlier than specified.
229
+
*/
230
+
T *calloc_until(Kernel::Clock::time_point abs_time)
231
+
{
232
+
return _pool.calloc_until(abs_time);
166
233
}
167
234
168
235
/** Allocate a memory block of type T, blocking, and set memory block to zero.
@@ -176,10 +243,13 @@ class Mail : private mbed::NonCopyable<Mail<T, queue_sz> > {
176
243
* due to internal 32-bit computations, but this is guaranteed to work if the
177
244
* wait is <= 0x7fffffff milliseconds (~24 days). If the limit is exceeded,
178
245
* the wait will time out earlier than specified.
246
+
* @deprecated Pass a chrono time_point, not an integer millisecond count. For example use `Kernel::Clock::now() + 5s`
247
+
* rather than `Kernel::get_ms_count() + 5000`.
179
248
*/
249
+
MBED_DEPRECATED_SINCE("mbed-os-6.0.0", "Pass a chrono time_point, not an integer millisecond count. For example use `Kernel::Clock::now() + 5s` rather than `Kernel::get_ms_count() + 5000`.")
due to internal 32-bit computations, but this is guaranteed to work if the
111
134
wait is <= 0x7fffffff milliseconds (~24 days). If the limit is exceeded,
112
135
the wait will time out earlier than specified.
136
+
@deprecated Pass a chrono time_point, not an integer millisecond count. For example use `Kernel::Clock::now() + 5s`
137
+
rather than `Kernel::get_ms_count() + 5000`.
113
138
*/
139
+
MBED_DEPRECATED_SINCE("mbed-os-6.0.0", "Pass a chrono time_point, not an integer millisecond count. For example use `Kernel::Clock::now() + 5s` rather than `Kernel::get_ms_count() + 5000`.")
due to internal 32-bit computations, but this is guaranteed to work if the
164
217
wait is <= 0x7fffffff milliseconds (~24 days). If the limit is exceeded,
165
218
the wait will time out earlier than specified.
219
+
@deprecated Pass a chrono time_point, not an integer millisecond count. For example use `Kernel::Clock::now() + 5s`
220
+
rather than `Kernel::get_ms_count() + 5000`.
166
221
*/
222
+
MBED_DEPRECATED_SINCE("mbed-os-6.0.0", "Pass a chrono time_point, not an integer millisecond count. For example use `Kernel::Clock::now() + 5s` rather than `Kernel::get_ms_count() + 5000`.")
0 commit comments