composite inout signals with different driver directions

Discussion in 'VHDL' started by Ralph Friedrich, Nov 7, 2003.

  1. Hello,
    I'm use vectors to combine signals with different driver directions.
    May be that's not a good coding style ?!


    T(
    Q : INOUT Std_logic_vector (24 DOWNTO 0) ;
    ....

    For example:
    Q(12 downto 0) is driven by the testbech.
    Q(24 downto 13) is driven by DUT.

    In the simulation I get there a X on some signals.

    When I set a init value to the vector it works sometimes.

    Does anyone know whats going on?
     
    Ralph Friedrich, Nov 7, 2003
    #1
    1. Advertising

  2. Ralph Friedrich

    Jim Lewis Guest

    Ralph,
    Initially the testbench and the DUT are driving
    driving all elements of the array. If one does
    not drive a field, the value it is effectively
    driving is 'U', the left most value of std_ulogic.

    A simple way to get around this is to initialize
    the port to all 'Z' as follows:

    T(
    Q : INOUT Std_logic_vector (24 DOWNTO 0) := (others => 'Z') ;
    ...

    Cheers,
    Jim

    --
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Jim Lewis
    Director of Training mailto:
    SynthWorks Design Inc. http://www.SynthWorks.com
    1-503-590-4787

    Expert VHDL Training for Hardware Design and Verification
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

    Ralph Friedrich wrote:
    > Hello,
    > I'm use vectors to combine signals with different driver directions.
    > May be that's not a good coding style ?!
    >
    >
    > T(
    > Q : INOUT Std_logic_vector (24 DOWNTO 0) ;
    > ...
    >
    > For example:
    > Q(12 downto 0) is driven by the testbech.
    > Q(24 downto 13) is driven by DUT.
    >
    > In the simulation I get there a X on some signals.
    >
    > When I set a init value to the vector it works sometimes.
    >
    > Does anyone know whats going on?
    >
    >
    >
     
    Jim Lewis, Nov 7, 2003
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Giox
    Replies:
    1
    Views:
    643
    Mike Treseler
    Apr 2, 2006
  2. Christine

    Asking directions.

    Christine, Sep 9, 2003, in forum: C++
    Replies:
    6
    Views:
    470
    Gary Labowitz
    Sep 12, 2003
  3. =?ISO-8859-15?Q?Fr=E9d=E9ric_Lochon?=

    connecting std_logic inout ports and std_logic_vector inout port

    =?ISO-8859-15?Q?Fr=E9d=E9ric_Lochon?=, Nov 6, 2007, in forum: VHDL
    Replies:
    3
    Views:
    882
  4. Ken

    inout to inout

    Ken, May 9, 2008, in forum: VHDL
    Replies:
    2
    Views:
    650
    Aiken
    May 9, 2008
  5. THurkmans
    Replies:
    14
    Views:
    1,915
    Mike Treseler
    Aug 11, 2009
Loading...

Share This Page