1. Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.
    Dismiss Notice

Measuring frequency with LTspice

Discussion in 'Circuit Simulation & PCB Design' started by carbonzit, May 23, 2011.

  1. carbonzit

    carbonzit Active Member

    Joined:
    Mar 19, 2011
    Messages:
    1,958
    Likes:
    13
    Is there any way to measure the frequency of a waveform generated by LTspice?

    I know there's a fast Fourier transform function and display, but I'd really just like to know the (approximate) frequency of a particular waveform.
     
  2. ericgibbs

    ericgibbs Well-Known Member Most Helpful Member

    Joined:
    Jan 4, 2007
    Messages:
    21,189
    Likes:
    644
    Location:
    Ex Yorks' Hants UK
    hi cz,
    Run the sim and create a plot.
    1. hold down Ctrl key, right click on the waveform plot label [ at the top of the plot]

    2. A small window will open, use the 'Attached Cursor' drop down box, select 1st & 2nd.

    3. Two dashed 'axis' lines will appear on the plot, name '1' and '2'

    4. place your cursor on '1' and hold down the left mouse key and move the '1' dashed line to a position on the plot waveform. Then do the same with '2' dashed line, place that one cycle away on the waveform.

    5. There is a small window, bottom right of your screen.

    6. it shows the Freq and other info on the '1' and '2' dashed line positions.

    7. note also it shows the amplitude at the selected points.

    BTW: I have that TwinTosc .asc if you want to play with it.
     
    • Like Like x 2
  3. ikelectro

    ikelectro Member

    Joined:
    Aug 25, 2012
    Messages:
    388
    Likes:
    4
    Location:
    Kolkata, Proud to be an Indian.
    Hi eric!!!!
    I now that i'm digging up a old thread.... is it possible to get the LM358 and LM393 in the LTSpice....?????/:):)
     
  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. ericgibbs

    ericgibbs Well-Known Member Most Helpful Member

    Joined:
    Jan 4, 2007
    Messages:
    21,189
    Likes:
    644
    Location:
    Ex Yorks' Hants UK

    hi ike,

    I would recommend you join the free Yahoo LTS user group http://tech.groups.yahoo.com/group/LTspice/

    They have the two IC's in the LIB/FILES folder.

    If you have a problem let me know.

    E.
     
  6. ikelectro

    ikelectro Member

    Joined:
    Aug 25, 2012
    Messages:
    388
    Likes:
    4
    Location:
    Kolkata, Proud to be an Indian.
    Hi thanks eric for that link... but how should i use it.... i can't figure it out how add the files to LTspice.....:confused:
     
  7. ericgibbs

    ericgibbs Well-Known Member Most Helpful Member

    Joined:
    Jan 4, 2007
    Messages:
    21,189
    Likes:
    644
    Location:
    Ex Yorks' Hants UK
    hi,
    If the file you download is 'zipped' , unzip it.

    You may see the following types of unzipped files:

    Use Windows Explorer to move as required. [ my LTS is in C:\Program Files\LTC\LTspiceIV] , you may have chosen a different folder.


    If you have: filename.lib move it to the C:\Program Files\LTC\LTspiceIV\lib

    If you have: filename.mod or the filename.sub move it to the C:\Program Files\LTC\LTspiceIV\lib\sub

    If you have: filename.asy move it to the C:\Program Files\LTC\LTspiceIV\lib\sym

    Also most zipfiles have an testname.asc , this is the file you RUN with LTSpice

    You should have the include directive already in the testname.asc file,, if you create a new design and you wish to use the filename.sub or .mod you need to type in the .include as in the original testname.asc

    Let me know if you have a problem.

    E
     
  8. MikeMl

    MikeMl Well-Known Member Most Helpful Member

    Joined:
    Mar 17, 2009
    Messages:
    11,057
    Likes:
    541
    Location:
    AZ 86334
    The proceedure on how to augment the LTSpice library has been discussed hundreds of times on the Yahoo group and on these forums. Use the "Search" feature on either Yahoo or this forum. No point in rehashing it here...
     
  9. ikelectro

    ikelectro Member

    Joined:
    Aug 25, 2012
    Messages:
    388
    Likes:
    4
    Location:
    Kolkata, Proud to be an Indian.
    Hi eric,

    I have a .mod file for LM358 and I have moved it to C:\Program Files\LTC\LTspiceIV\lib\sub (as you have said

    and my LT also in the same directory) ... but cant able to see or use the lm358 in my LTSpice!!! i think I have now only

    problem with the .mod files!!!
     
  10. eTech

    eTech Active Member

    Joined:
    Apr 25, 2012
    Messages:
    561
    Likes:
    43
    Hi

    You need to create a symbol file or use an existing symbol file, and associate the .mod file with it. The symbol file has a . asy file type.
    If you want to use an existing symbol, try using the opamp2.asy

    If you already placed the .mod file below the sub/ folder somewhere:
    Add the opamp2.asy to the schematic,
    then rht-clk the component name and change it to the exact name after the .subckt statement in the mod file.

    eT
     

Share This Page