ΣSigmaStudio Ask AI Русский Log in

SigmaStudio basic DSP functions for Left Shift and Arithmetic Right Shift Operations

SigmaDSP & SigmaStudio IanH May 30, 2010 00:00 1 replies Original on forum ↗
Subscribe
IanH Question
May 30, 2010 00:00

Does SigmaStudio support basic Left Shift and Arithmetic Right Shift operations in the DSP core for processors such as the ADAU144x (or any other device)?

ADIApproved Reply
Jun 2, 2010 00:00

There isn't a direct "shift left" and "shift right" block in SigmaStudio, but you can use simple multiplication operations to do this. If you use a multiplication block with two inputs - your signal to be shifted and a dc input source - you can shift the signal bits up and down. Depending on the format of your signal, you will likely set the number format of the dc block to be either 28.0 (control signals, typically) or 5.23 (audio data). To shift the bits of an audio signal right one bit, you would just multiply it by a dc value of 0.5 in 5.23 format. Shifting right by two would be a multiplication of 0.25, and so on.