diff --git a/lib/include/srslte/phy/utils/vector.h b/lib/include/srslte/phy/utils/vector.h index 008df488b..c8590a4f1 100644 --- a/lib/include/srslte/phy/utils/vector.h +++ b/lib/include/srslte/phy/utils/vector.h @@ -82,6 +82,8 @@ SRSLTE_API cf_t srslte_vec_acc_cc(const cf_t* x, const uint32_t len); SRSLTE_API void* srslte_vec_malloc(uint32_t size); SRSLTE_API cf_t* srslte_vec_cf_malloc(uint32_t size); SRSLTE_API float* srslte_vec_f_malloc(uint32_t size); +SRSLTE_API int32_t* srslte_vec_i32_malloc(uint32_t nsamples); +SRSLTE_API uint32_t* srslte_vec_u32_malloc(uint32_t nsamples); SRSLTE_API int16_t* srslte_vec_i16_malloc(uint32_t nsamples); SRSLTE_API uint16_t* srslte_vec_u16_malloc(uint32_t nsamples); SRSLTE_API int8_t* srslte_vec_i8_malloc(uint32_t nsamples); diff --git a/lib/src/phy/utils/vector.c b/lib/src/phy/utils/vector.c index 35a3f6ece..c9849dcb6 100644 --- a/lib/src/phy/utils/vector.c +++ b/lib/src/phy/utils/vector.c @@ -154,6 +154,16 @@ float* srslte_vec_f_malloc(uint32_t nsamples) return (float*)srslte_vec_malloc((uint32_t)sizeof(float) * nsamples); } +int32_t* srslte_vec_i32_malloc(uint32_t nsamples) +{ + return (int32_t*)srslte_vec_malloc((uint32_t)sizeof(int32_t) * nsamples); +} + +uint32_t* srslte_vec_u32_malloc(uint32_t nsamples) +{ + return (uint32_t*)srslte_vec_malloc((uint32_t)sizeof(uint32_t) * nsamples); +} + int16_t* srslte_vec_i16_malloc(uint32_t nsamples) { return (int16_t*)srslte_vec_malloc((uint32_t)sizeof(int16_t) * nsamples);