Convert to Q47 arithmetic.

This commit is contained in:
Jonathan Naylor 2020-04-26 13:02:43 +01:00
parent a31cf3d6f8
commit 6f4c19c006
1 changed files with 2 additions and 2 deletions

View File

@ -106,8 +106,8 @@ uint8_t CFMCTCSSTX::setParams(uint8_t frequency, uint8_t level)
q31_t arg = 0; q31_t arg = 0;
for (uint16_t i = 0U; i < m_length; i++) { for (uint16_t i = 0U; i < m_length; i++) {
q31_t value = ::arm_sin_q31(arg) * q15_t(level * 13); q63_t value = ::arm_sin_q31(arg) * q15_t(level * 13);
m_values[i] = q15_t(__SSAT((value >> 15), 16)); m_values[i] = q15_t(__SSAT((value >> 31), 16));
arg += entry->increment; arg += entry->increment;
} }