Zero Padding Circuit Design

H

hamkanen

Guest
Hi all,

i want to design a zero padding circuit.
The problem is the number of zero depends on the number of input data.

Let's say i have 2000 data input, the number of output data should b
divided by factor of 600.
So number of zero padding = 400 --> (2000+400)/600 = integer value
Remember that number of data input could vary, so it will change the numbe
of zero padding

Can you give me suggestion, how to implement zero padding circuit i
hardware?

*I plan to design the circuit 10 port parallely, so for above example, i
will need 200 clock to input all data.

Thanks



---------------------------------------
Posted through http://www.FPGARelated.com
 
I'm not sure what part is giving you trouble. Without giving away the answer, think about using some combination of appropriately triggered counters. Try walking through your problem (on paper) for various amounts of input data - then it should become obvious how when you should trigger various events and how much the counters will count to before they trigger something else.

Chris
 
I'm not sure what part is giving you trouble. Without giving away th
answe=
r, think about using some combination of appropriately triggered counters
=
Try walking through your problem (on paper) for various amounts of inpu
da=
ta - then it should become obvious how when you should trigger variou
even=
ts and how much the counters will count to before they trigger somethin
el=
se.

Chris
OK I think I have gotten it, well sort of. I found a good example fo
driving a VGA monitor. I have modified it, but I keep getting th
following errors:

Line 32. The type of the element in aggregate does not correspond to an
array type.

Line 44. The type of the element in aggregate does not correspond to an
array type.

Line 32 is:

if (h_counter => "0111100010") and (h_counter <= "1000001011") then

Line 44 is:

if (v_counter => "0100010010") and (v_counter <= "0100011100") then

What am I doing wrong?

---------------------------------------
Posted through http://www.FPGARelated.com
 
I'm not sure what part is giving you trouble. Without giving away th
answe=
r, think about using some combination of appropriately triggered counters
=
Try walking through your problem (on paper) for various amounts of inpu
da=
ta - then it should become obvious how when you should trigger variou
even=
ts and how much the counters will count to before they trigger somethin
el=
se.

Chris
OK I think I have gotten it, well sort of. I found a good example fo
driving a VGA monitor. I have modified it, but I keep getting th
following errors:

Line 32. The type of the element in aggregate does not correspond to an
array type.

Line 44. The type of the element in aggregate does not correspond to an
array type.

Line 32 is:

if (h_counter => "0111100010") and (h_counter <= "1000001011") then

Line 44 is:

if (v_counter => "0100010010") and (v_counter <= "0100011100") then

What am I doing wrong?

---------------------------------------
Posted through http://www.FPGARelated.com
 
On 1/25/2011 12:34 PM, frozen001 wrote:

Line 44 is:

if (v_counter => "0100010010") and (v_counter<= "0100011100") then

What am I doing wrong?
Maybe you mean "greater than or equal" which is >=

-- Mike
 
On Jan 25, 3:48 pm, Mike Treseler <mtrese...@gmail.com> wrote:
On 1/25/2011 12:34 PM, frozen001 wrote:

Line 44 is:

if (v_counter =>  "0100010010") and (v_counter<= "0100011100") then

What am I doing wrong?

Maybe you mean "greater than or equal" which is  
              -- Mike
Good catch, Mike! I really like the very informative error message.
At least the error pointed to the correct lines in the file. My
usual problems with typo's result in an error message pointing
several lines down when the missing "end" suddenly causes
a syntax error.

Regards,
Gabor
 
On Jan 25, 5:21 pm, Gabor <ga...@alacron.com> wrote:
On Jan 25, 3:48 pm, Mike Treseler <mtrese...@gmail.com> wrote:

On 1/25/2011 12:34 PM, frozen001 wrote:

Line 44 is:

if (v_counter =>  "0100010010") and (v_counter<= "0100011100") then

What am I doing wrong?

Maybe you mean "greater than or equal" which is  
              -- Mike

Good catch, Mike!  I really like the very informative error message.
At least the error pointed to the correct lines in the file.  My
usual problems with typo's result in an error message pointing
several lines down when the missing "end" suddenly causes
a syntax error.

Regards,
Gabor
The error message is based on what you typed, not what you are
thinking. The => symbol is used for associations in aggregates. So
it told you your aggregate was wrong.

Rick
 

Welcome to EDABoard.com

Sponsor

Back
Top