I am working on developing a camera and I am trying to select hardware for the camera. I believe that I may need a digital signal processor to compress image data before it is transmitted to a computer or other device (MCU)
. What I am trying to figure out is how to estimate the processing power needed given a specific DSP
. For example I was considering the OV5670 Image Sensor
. This sensor is capable of transmitting 5 megapixel
image data at 30 fps
. If each pixel is stored as a 10 bit value
that means in total 1.5Gbps
would be being transmitted to a digital signal processor of my choice. The reason I am doing compression is that my ideally the camera would record data and then upload it to a cloud based server. I think it would be ideal then for compression to take place before uploading the data to reduce bandwidth usage.
From here I am uncertain how to proceed. For example I examined the ADSP-BF529BCPZ DSP chip
. This chip can execute instructions at a rate of 400 MHz
. In the data specs it is specified that the processing core of this chip contains
"Blackfin processor core contains two 16-bit multipliers
, two 40-bit accumulators, two 40-bit ALUs, four video ALUs, and a 40-bit shifter
."
Now each MAC
can do a 16 bit
multiplication and accumulate the result in the 40
bit shifter. There are 2
such MACs. If I were trying to compress the data by taking a DFT
and then selecting the largest coefficients then I could say to calculate a single coefficient in the frequency domain I would need to multiply each pixel by a value and then sum it. Between the 2 MACs this would take 2.5 million cycles
for one coefficient of a single frame.
Based on the above calculations it seems unlikely that the selected chip would be able to handle the compression as I need it to. But at the same time I know algorithms exists such as the FFT
which can drastically boost the speed of the DFT
.
What I am looking for is either confirmation that my current intuition into selecting a DSP chip is correct or alternatively that I am over/under-estimating the capabilities of DSP chips. In the later case, if possible please suggest other methods for predicting the required processing power from a DSP for a specific image compression application.
Thank You in advance, if any additional information is needed please let me know. Also feel free to suggest other solutions to my problem. For example, if you believe that I do not need a DSP and could instead achieve my goals through either a MCU
or an FPGA
then feel free to make such a suggestion.
edit: Also if anyone looks at the datasheets for the above listed components you will see that the image sensor transfers data via MIPI-CSI2 protocol
. Which the DSP chip does not support. I am aware of that shortcoming but it is not the main driver of my current question.
code
is not an improvement in readability. Please don't do that; I had to reject your proposed changes. The`
notation is used for source code only. $\endgroup$