Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > VHDL > Tristate

Reply
Thread Tools

Tristate

 
 
Michael
Guest
Posts: n/a
 
      09-15-2003
hello
I'm having trouble synthesising the following tristate implementation:

-- ...
-- ...
architecture Behavioral of driver is
signal current_state, next_state : std_logic_vector(4 downto 0);
signal tmp : std_logic_vector(1 downto 0);
begin
-- ...
-- ...
out_logic: process(current_state)
begin
case current_state is
when "00001" =>
C_BE <= DEV_RTYP;
FRAME <= '1';
AD <= DEV_ADDR;
IRDY <= 'Z';
when "00010" =>
IRDY <= 'Z';
if LAST = '1' then
FRAME <= '0';
end if;
when others =>
DRV_RDY <= '0';
end case;
end process out_logic;
end Behavioral;

IRDY is a port declared as inout stdlogic. The error I'm getting is :

ERROR:Xst:742 - Unexpected 'Z' expression found.
ERROR:Xst:746 - Failed to build equation for signal <irdy> in unit <driver>.

If i have the 00010 case removed, it synthesises, I really don't know why.

Please help

thank you
 
Reply With Quote
 
 
 
 
Michael Chan
Guest
Posts: n/a
 
      09-15-2003
I'm pretty new to VHDL, but I think your code might work if you give IRDY a
default value:

out_logic: process(current_state)
begin
IRDY <= 'Z';
case
...
end

If a value for IRDY is not specified for all cases, you get a latch, which
doesn't make a lot of sense for 'Z'.

Cheers,

Michael.

"Michael" <> wrote in message
news: om...
> hello
> I'm having trouble synthesising the following tristate implementation:
>
> -- ...
> -- ...
> architecture Behavioral of driver is
> signal current_state, next_state : std_logic_vector(4 downto 0);
> signal tmp : std_logic_vector(1 downto 0);
> begin
> -- ...
> -- ...
> out_logic: process(current_state)
> begin
> case current_state is
> when "00001" =>
> C_BE <= DEV_RTYP;
> FRAME <= '1';
> AD <= DEV_ADDR;
> IRDY <= 'Z';
> when "00010" =>
> IRDY <= 'Z';
> if LAST = '1' then
> FRAME <= '0';
> end if;
> when others =>
> DRV_RDY <= '0';
> end case;
> end process out_logic;
> end Behavioral;
>
> IRDY is a port declared as inout stdlogic. The error I'm getting is :
>
> ERROR:Xst:742 - Unexpected 'Z' expression found.
> ERROR:Xst:746 - Failed to build equation for signal <irdy> in unit

<driver>.
>
> If i have the 00010 case removed, it synthesises, I really don't know why.
>
> Please help
>
> thank you



 
Reply With Quote
 
 
 
 
Michael
Guest
Posts: n/a
 
      09-16-2003
Thanks for the reply.
I got a question, but doesn't the others statement handle the default value?

thanks
"Michael Chan" <> wrote in message news:<bk4n63$1b4$>...
> I'm pretty new to VHDL, but I think your code might work if you give IRDY a
> default value:
>
> out_logic: process(current_state)
> begin
> IRDY <= 'Z';
> case
> ...
> end
>
> If a value for IRDY is not specified for all cases, you get a latch, which
> doesn't make a lot of sense for 'Z'.
>
> Cheers,
>
> Michael.
>
> "Michael" <> wrote in message
> news: om...
> > hello
> > I'm having trouble synthesising the following tristate implementation:
> >
> > -- ...
> > -- ...
> > architecture Behavioral of driver is
> > signal current_state, next_state : std_logic_vector(4 downto 0);
> > signal tmp : std_logic_vector(1 downto 0);
> > begin
> > -- ...
> > -- ...
> > out_logic: process(current_state)
> > begin
> > case current_state is
> > when "00001" =>
> > C_BE <= DEV_RTYP;
> > FRAME <= '1';
> > AD <= DEV_ADDR;
> > IRDY <= 'Z';
> > when "00010" =>
> > IRDY <= 'Z';
> > if LAST = '1' then
> > FRAME <= '0';
> > end if;
> > when others =>
> > DRV_RDY <= '0';
> > end case;
> > end process out_logic;
> > end Behavioral;
> >
> > IRDY is a port declared as inout stdlogic. The error I'm getting is :
> >
> > ERROR:Xst:742 - Unexpected 'Z' expression found.
> > ERROR:Xst:746 - Failed to build equation for signal <irdy> in unit

> <driver>.
> >
> > If i have the 00010 case removed, it synthesises, I really don't know why.
> >
> > Please help
> >
> > thank you

 
Reply With Quote
 
Marc Guardiani
Guest
Posts: n/a
 
      09-16-2003
Michael,
Yes it does, but you're not setting it there. Try adding it and see if
that fixes your problem. BTW, which version of the Xilinx software are
you using?
Marc

Michael wrote:
> Thanks for the reply.
> I got a question, but doesn't the others statement handle the default value?
>
> thanks
> "Michael Chan" <> wrote in message news:<bk4n63$1b4$>...
>
>>I'm pretty new to VHDL, but I think your code might work if you give IRDY a
>>default value:
>>
>>out_logic: process(current_state)
>>begin
>> IRDY <= 'Z';
>> case
>> ...
>>end
>>
>>If a value for IRDY is not specified for all cases, you get a latch, which
>>doesn't make a lot of sense for 'Z'.
>>
>>Cheers,
>>
>>Michael.
>>
>>"Michael" <> wrote in message
>>news: .com...
>>
>>>hello
>>>I'm having trouble synthesising the following tristate implementation:
>>>
>>>-- ...
>>>-- ...
>>>architecture Behavioral of driver is
>>>signal current_state, next_state : std_logic_vector(4 downto 0);
>>>signal tmp : std_logic_vector(1 downto 0);
>>>begin
>>>-- ...
>>>-- ...
>>>out_logic: process(current_state)
>>>begin
>>>case current_state is
>>>when "00001" =>
>>>C_BE <= DEV_RTYP;
>>>FRAME <= '1';
>>>AD <= DEV_ADDR;
>>>IRDY <= 'Z';
>>>when "00010" =>
>>>IRDY <= 'Z';
>>>if LAST = '1' then
>>>FRAME <= '0';
>>>end if;
>>>when others =>
>>>DRV_RDY <= '0';
>>>end case;
>>>end process out_logic;
>>>end Behavioral;
>>>
>>>IRDY is a port declared as inout stdlogic. The error I'm getting is :
>>>
>>>ERROR:Xst:742 - Unexpected 'Z' expression found.
>>>ERROR:Xst:746 - Failed to build equation for signal <irdy> in unit

>>
>> <driver>.
>>
>>>If i have the 00010 case removed, it synthesises, I really don't know why.
>>>
>>>Please help
>>>
>>>thank you


 
Reply With Quote
 
Michael
Guest
Posts: n/a
 
      09-16-2003
it's 4.2WP3.x

thanks
Marc Guardiani <> wrote in message news:<cxu9b.4805$>...
> Michael,
> Yes it does, but you're not setting it there. Try adding it and see if
> that fixes your problem. BTW, which version of the Xilinx software are
> you using?
> Marc
>
> Michael wrote:
> > Thanks for the reply.
> > I got a question, but doesn't the others statement handle the default value?
> >
> > thanks
> > "Michael Chan" <> wrote in message news:<bk4n63$1b4$>...
> >
> >>I'm pretty new to VHDL, but I think your code might work if you give IRDY a
> >>default value:
> >>
> >>out_logic: process(current_state)
> >>begin
> >> IRDY <= 'Z';
> >> case
> >> ...
> >>end
> >>
> >>If a value for IRDY is not specified for all cases, you get a latch, which
> >>doesn't make a lot of sense for 'Z'.
> >>
> >>Cheers,
> >>
> >>Michael.
> >>
> >>"Michael" <> wrote in message
> >>news: .com...
> >>
> >>>hello
> >>>I'm having trouble synthesising the following tristate implementation:
> >>>
> >>>-- ...
> >>>-- ...
> >>>architecture Behavioral of driver is
> >>>signal current_state, next_state : std_logic_vector(4 downto 0);
> >>>signal tmp : std_logic_vector(1 downto 0);
> >>>begin
> >>>-- ...
> >>>-- ...
> >>>out_logic: process(current_state)
> >>>begin
> >>>case current_state is
> >>>when "00001" =>
> >>>C_BE <= DEV_RTYP;
> >>>FRAME <= '1';
> >>>AD <= DEV_ADDR;
> >>>IRDY <= 'Z';
> >>>when "00010" =>
> >>>IRDY <= 'Z';
> >>>if LAST = '1' then
> >>>FRAME <= '0';
> >>>end if;
> >>>when others =>
> >>>DRV_RDY <= '0';
> >>>end case;
> >>>end process out_logic;
> >>>end Behavioral;
> >>>
> >>>IRDY is a port declared as inout stdlogic. The error I'm getting is :
> >>>
> >>>ERROR:Xst:742 - Unexpected 'Z' expression found.
> >>>ERROR:Xst:746 - Failed to build equation for signal <irdy> in unit
> >>
> >> <driver>.
> >>
> >>>If i have the 00010 case removed, it synthesises, I really don't know why.
> >>>
> >>>Please help
> >>>
> >>>thank you

 
Reply With Quote
 
Charles M. Elias
Guest
Posts: n/a
 
      09-16-2003
Marc Guardiani <> wrote in message news:<cxu9b.4805$>...
> Michael,
> Yes it does, but you're not setting it there. Try adding it and see if
> that fixes your problem. BTW, which version of the Xilinx software are
> you using?
> Marc
>
> Michael wrote:
> > Thanks for the reply.
> > I got a question, but doesn't the others statement handle the default value?
> >
> > thanks
> > "Michael Chan" <> wrote in message news:<bk4n63$1b4$>...
> >
> >>I'm pretty new to VHDL, but I think your code might work if you give IRDY a
> >>default value:
> >>
> >>out_logic: process(current_state)
> >>begin
> >> IRDY <= 'Z';
> >> case
> >> ...
> >>end
> >>
> >>If a value for IRDY is not specified for all cases, you get a latch, which
> >>doesn't make a lot of sense for 'Z'.
> >>
> >>Cheers,
> >>
> >>Michael.
> >>
> >>"Michael" <> wrote in message
> >>news: .com...
> >>
> >>>hello
> >>>I'm having trouble synthesising the following tristate implementation:
> >>>
> >>>-- ...
> >>>-- ...
> >>>architecture Behavioral of driver is
> >>>signal current_state, next_state : std_logic_vector(4 downto 0);
> >>>signal tmp : std_logic_vector(1 downto 0);
> >>>begin
> >>>-- ...
> >>>-- ...
> >>>out_logic: process(current_state)
> >>>begin
> >>>case current_state is
> >>>when "00001" =>
> >>>C_BE <= DEV_RTYP;
> >>>FRAME <= '1';
> >>>AD <= DEV_ADDR;
> >>>IRDY <= 'Z';
> >>>when "00010" =>
> >>>IRDY <= 'Z';
> >>>if LAST = '1' then
> >>>FRAME <= '0';
> >>>end if;
> >>>when others =>
> >>>DRV_RDY <= '0';
> >>>end case;
> >>>end process out_logic;
> >>>end Behavioral;
> >>>
> >>>IRDY is a port declared as inout stdlogic. The error I'm getting is :
> >>>
> >>>ERROR:Xst:742 - Unexpected 'Z' expression found.
> >>>ERROR:Xst:746 - Failed to build equation for signal <irdy> in unit
> >>
> >> <driver>.
> >>
> >>>If i have the 00010 case removed, it synthesises, I really don't know why.
> >>>
> >>>Please help
> >>>
> >>>thank you


It looks as though IRDY never has a value assigned other than 'Z'.
Surely in some case it will have a value of '0' or '1'; otherwise it
is not of much use.

Charles
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
i need vhdl code for tristate logic and schmitt input trigger buffer uday424@gmail.com VHDL 1 03-11-2007 04:05 PM
processor bus tristate at two places praveen.kantharajapura@gmail.com VHDL 1 03-14-2006 03:29 AM
Tristate-Master-Slave testbench description ALuPin@web.de VHDL 5 05-18-2005 07:15 AM
Problems with Tristate ALuPin VHDL 12 11-28-2004 07:32 AM
Tristate Flip Flop Jim VHDL 12 11-18-2004 12:45 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57