Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

- Community Forums
- :
- Forums
- :
- Hardware Development
- :
- AI Engine, DSP IP and Tools
- :
- Binary Points must be less than or equal to number...

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

hrboland

Newbie

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

06-19-2020 03:04 PM

682 Views

Registered:
06-19-2020

Hello,

I am implementing a Biquad filter in fixed point within the Xilinx system generator/Simulink environment! Coefficients of the filter are so small; I need to define the filter coefficients data types as (1,32,39) per say where I would keep one bit for the sign, and the LSB should represent (2^-39)! However, I am getting the following error (see the attached snapshot) from the Xilinx system generator that the binary point must be less than number of bits! Does anyone know how to define and implement such a data type in system generator? it is easy to implement it in matlab/fixed point data toolbox!

I'd appreciate any input!

3 Replies

ravidapu

Xilinx Employee

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

06-22-2020 02:22 AM

599 Views

Registered:
12-14-2017

Hi,

This is an overflow condition, The guideline is applicable for Fixed point data, you will see the overflow error even in simulink during simulation if you set the binary points more than the total number of bits

Whenever you are setting the binary points, the value should be less than or equal to the total number of bits used for representing the data. In your example, the total number of bits 32 and you were trying to set binary points 39 which is out side of the range (32 bits)

If your requirements to have resolution 2^-39, please increase the total number of bits say 42 or 64 (greater than or equal to 39)

data types fix(1,32,39) is also not valid in simulink, you will see overflow error during simulation

I hope this will help you

Regards,

Raju A.

hrboland

Newbie

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

06-22-2020 04:33 PM

570 Views

Registered:
06-19-2020

Hello Raju,

I'd appreciate your prompt reply! I have tested data types in the format of say (1,32,39) in Matlab's fixed-point integer toolbox and it works flawlessly! As you pointed the precision is 2^-39 but since the range is small, we don't need to increase the number of integer bits! If I increase the number of bits to say 46 or so,I am not basically using the resources optimally! please advise

Regards

Hamid

ghagmann

Visitor

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

04-06-2021 10:19 AM

95 Views

Registered:
06-19-2019

is there no other way than just waisting ressources? I agree with Hamid, we should have a way to define the binary point bigger than the number of bits

Regards

Greg