+ Post New Thread
Results 1 to 10 of 10
  1. #1
    Newbie level 4
    Points: 184, Level: 2

    Join Date
    Oct 2018
    Posts
    6
    Helped
    0 / 0
    Points
    184
    Level
    2

    How to read binary stimulus file in SPECTRE in pwm format

    Hello everyone,
    I generated a binary file in Modelsim, wish to use it in Specter as stimulus: "0" -> gnd, "1" -> vdd, how to do it?
    I have tried to use Vpwlf in analogLib, but get a Sawtooth wave, which is not what I wanted. I wish to get a pulse width modulated square wave. Many thanks for help! HJ

    •   AltAdvertisement

        
       

  2. #2
    Advanced Member level 5
    Points: 16,987, Level: 31
    pancho_hideboo's Avatar
    Join Date
    Oct 2006
    Location
    Real Homeless
    Posts
    2,611
    Helped
    700 / 700
    Points
    16,987
    Level
    31

    Re: How to read binary stimulus file in SPECTRE in pwm format

    Use correct terminology.

    Quote Originally Posted by chj88 View Post
    I generated a binary file in Modelsim,
    Cadence spectre does not have an ability to read any binary file.

    Can you understand "a binary file" ?

    Quote Originally Posted by chj88 View Post
    wish to use it in Specter as stimulus: "0" -> gnd, "1" -> vdd, how to do it?
    Your file is a ascii file not binary file.
    It is a bit pattern ascii file.

    Use "vsource" of "type=bit".
    And include instance description of "vsource" as netlist.


    1 members found this post helpful.

  3. #3
    Newbie level 4
    Points: 184, Level: 2

    Join Date
    Oct 2018
    Posts
    6
    Helped
    0 / 0
    Points
    184
    Level
    2

    Re: How to read binary stimulus file in SPECTRE in pwm format

    Thank you very much Pancao! I tried following your instructions, but still have confusions:
    1) How to " include instance description of "vsource" as netlist" ? I didn't find "netlist" under any button in the vsource instance form.
    2) Where to indicate the path to the file?
    Many thanks.



    •   AltAdvertisement

        
       

  4. #4
    Advanced Member level 5
    Points: 16,987, Level: 31
    pancho_hideboo's Avatar
    Join Date
    Oct 2006
    Location
    Real Homeless
    Posts
    2,611
    Helped
    700 / 700
    Points
    16,987
    Level
    31

    Re: How to read binary stimulus file in SPECTRE in pwm format

    Can you understand netlist ?


    1 members found this post helpful.

    •   AltAdvertisement

        
       

  5. #5
    Newbie level 4
    Points: 184, Level: 2

    Join Date
    Oct 2018
    Posts
    6
    Helped
    0 / 0
    Points
    184
    Level
    2

    Re: How to read binary stimulus file in SPECTRE in pwm format

    Hi Pancao,
    If I put vsource in the schematics, the generated netlist should already include the vsource. What is instance description? Really don't know what you mean:)
    Also, how to let the spectre know the location of the file? Thanks for your time, will appreciate very much if you could make it more clear.



  6. #6
    Advanced Member level 5
    Points: 16,987, Level: 31
    pancho_hideboo's Avatar
    Join Date
    Oct 2006
    Location
    Real Homeless
    Posts
    2,611
    Helped
    700 / 700
    Points
    16,987
    Level
    31

    Re: How to read binary stimulus file in SPECTRE in pwm format

    Don’t put vsource in schematic.
    There is no file in vsource of type=bit.
    So include netlist description.

    BTW, how long is your bit pattern ?


    1 members found this post helpful.

  7. #7
    Newbie level 4
    Points: 184, Level: 2

    Join Date
    Oct 2018
    Posts
    6
    Helped
    0 / 0
    Points
    184
    Level
    2

    Re: How to read binary stimulus file in SPECTRE in pwm format

    Thanks, but still confusing.



  8. #8
    Newbie level 4
    Points: 184, Level: 2

    Join Date
    Oct 2018
    Posts
    6
    Helped
    0 / 0
    Points
    184
    Level
    2

    Re: How to read binary stimulus file in SPECTRE in pwm format

    vector file, about 400,000 lines, like
    1
    1
    0
    1
    0
    0
    1
    1
    1
    0

    Thanks



  9. #9
    Advanced Member level 5
    Points: 16,987, Level: 31
    pancho_hideboo's Avatar
    Join Date
    Oct 2006
    Location
    Real Homeless
    Posts
    2,611
    Helped
    700 / 700
    Points
    16,987
    Level
    31

    Re: How to read binary stimulus file in SPECTRE in pwm format

    See spectre -h vsource
    spectre -h pattern

    BTW, can you understand PWM ?
    I don’t think your waveform is PWM.


    1 members found this post helpful.

    •   AltAdvertisement

        
       

  10. #10
    Newbie level 4
    Points: 184, Level: 2

    Join Date
    Oct 2018
    Posts
    6
    Helped
    0 / 0
    Points
    184
    Level
    2

    Re: How to read binary stimulus file in SPECTRE in pwm format

    Thank a lot! I should use pdm. By searing spectre -h vsource, I found a thread in Cadence forum, said there is a file section in vsource form to indicate the path to the file. but I can't find it in the instance form, no matter vsource from analogLib or that from rfLib. Did Cadence remove this section?
    I do remember I used this function long time ago when designing a sigma delta DAC, but forgot whether it was vsource or other thing.



--[[ ]]--