Save Graph (Trigger by logic state)

Save Graph (Trigger by logic state), a forum discussion on Cleverscope. Join us for more discussions on Save Graph (Trigger by logic state) on our Questions forum.

Back to Forum Index : Back to Questions   RSS

3 Sep 2009
Posts:

Hello everybody,

I'm quite new about using osciloscope, so I'm sorry if my question sounds dumb.

I'm facing a technical dificulty here to save several files of graphs using an external activator (logical signal from a MSP).

Is it possible to trigger (I'm saving files using trigger) from a logic signal (0 or 1) instead of slope?!

I've read a post about enabling logging and save a file by the push of button (wiring a buttong at the ext trigger) but I'm not sure this would be usefull to my case. Because I need to save the whole frame (graph) not log through time.

Thank you very much
Jen John Lee
University of Sao Paulo (Brazil).

7 Sep 2009
Posts: 398

Hello Jen, I think you are almost there. If you use File/File Options, and then set the Save Options to 'Save on Trigger' (and set up the save file base name, and save start and save stop numbers), then the Cleverscope will save the Scope Graph data set every time there is a trigger.

You have a digital signal available, which you can sense with any of the channels. I will assume you are using a digital input to do the sensing. Usually you would want to trigger on a change in state (eg 0 -> 1), however you can trigger on a level (eg 1) if you want - the cleverscope will then run at full rate (20 frames/sec) until the trigger condition is no longer met. To make this concrete, using Digital Input 1, set the trigger source to Digital, and the Digital Pattern to XXXX XXX1 for triggering continuously while digital 1 is high, or XXXX XXX^ (^ means rising edge, I don't have the symbol here) if you want to trigger when Input 1 changes from 0 to 1. In either case, every time there is a trigger you will save a file with an incrementing suffix until you get to the last number you specified. Each save will be time and date stamped with the trigger time (to 10ns resolution).

10 Sep 2009
Posts:

Thank you for your reply.
This would be almost exactly what I want to do. Unfortunately, my cleverscope model (CS320), do not have digital Inputs. Only Chanel A, B and Ext Trigger. What I intended to do, was use an logic signal (5V to Ground) that I can control on my PC (an MSP on the USB port) on Ext Trigger. I guess I need a full clock signal on the Ext Trigger to make it sense the slope. Right?

Any Ideas?

Thank you very much.
Jen John Lee

10 Sep 2009
Posts: 398

Hello Jen John Lee,
You are exactly right. The digital inputs allow triggering on a level, but the analog inputs or external do not. We will think about that (not that anyone else has ever asked for it!). But there is a solution :-) You can use Maths to look at the External Trigger input and do an autosave if the level is high. You will need this equation:

Equation Process Destination
x:1 A:B Autosave c

This equation senses the external trigger (x) and autosaves the Scope Graph (1) if any x is >0. The result (0 for no save, 1 for a save) is written to c (which you can use for something else if you like). You need to have set up Autosave with a base name, start number and end number, and 'Save manually' before you start. To run Maths, you need the Maths Graph open. Use 'Auto' triggering to run continuosly. The Maths will only save if External Trigger is high.

I hope this helps.

11 Sep 2009
Posts:

I´ll try this solution. It sounds exactly what I need.
I´ll post later if I´m successful :-)
Thank you very much and congrats about the product, we are very pleased about it.

Regards
Jen John Lee

11 Sep 2009
Posts:

We are almost there :-)
I could not sense the signal at external trigger (x) using the Math Graph, but I could sense the digital signal connected at the B (b:1) channel (it is probably some setting I must do at math graph to show the signal I want to see).
Re-reading the posts above, I realized that I explained not very well what I need to do. I need to save 1 scope graph at each digital signal.
So, at this point, instead of saving one file of the graph (of the channel A that interests me) each time I set my digital signal (at channel B) to 1, it saves the whole set of files that I configured at File Options (e.g. Start 1, Stop 10: it saves all 10 files at that time, not one each time I set and unset the signal).
Is there any configuration that I can do to solve for this problem? I´ve tried to increase the Auto Save Time and Set and unset my digital signal very quickly, but this do not seen a very reliable solution.

Thanks again,
Jen John Lee

11 Sep 2009
Posts: 398

Hello Jen John Lee,
It sounds like you want a plain old edge triggered file save. So every time the digital signal goes from low to high, you want to save the file. Is this correct? If it is, then go with easiest option which is:
1. Set the trigger source to External Trigger (or Chan A or B if you want).
2. Set the External Trigger threshold to something useful eg 2Vif you are using 5V logic.
3. Set the trigger to be falling or rising as you want.
4. Set up File/File Options, the Save Options to be 'Save on Trigger'. Set the Save File Base Name, Save Start and Save stop numbers.
5. Click on the graph you want to save, to select it.
6. Click Triggered on the Cleverscope Control Panel. Now everytime you get an external trigger you will save a file.

Before setting up Autosave, it might be useful to setup the graph the way you want it (Time and Amplitude axis), and get the triggering working properly.
The reason x did not work in the Maths Graph is because you need the digital display on to see the external trigger. I did not tell you that.

Sorry, I understood from your first question that you wanted level, not edge sensing. But edge sensing is better! I'm glad we have got there.

Let us know how you go :-)

11 Sep 2009
Posts:

This was the first thing I ever tried :-) (Maybe I haven´t set the threshold properly so it has not worked properly with my digital signal).
I used to be able to do this using a trigger generator (from a FPGA that we programed to do so), so each time I pushed a button, a full step signal was generated and I could record a graph.
My problem started when we changed the FPGA for a MSP that gives me only state (0 or 1) not a full step, so I was not able to sense the slope (or maybe I just guessed wrong it was not able to).
I´ll try the solution provided by you (paying double attention to all the steps you gave us) and see what happens. (unfortunately I´ll have to wait till tomorrow, it is already late here in Brazil :-)

Thank you very much again.
Best regards
Jen John Lee

11 Sep 2009
Posts: 398

Hi Jen John Lee,
Thanks for your update. You might like to capture the signal coming out of the MSP using Chan A or B. My guess is that it is using 3.3V logic, and so you may need to set the External Trigger Threshold to about 1.5V. Look at it with one of the analog channels just to see. The MSP will still output voltage levels , one for 0 (usually 0V) and the other for 1 (usually 3.3V or it may be lower - down to 1.8V). You need to make sure the external trigger threshold is in between the two levels. You are interested in saving when the logic changes from 0 (0V) to 1 (1.8-3.3V), this is edge triggering. There is no problem with how fast the state changes, the cleverscope will sense it. Good luck with it.

15 Sep 2009
Posts:

I´m starting to think I will have to make some modification to my setup.
I´ve checked the voltage level of my logic signal. It is 3.3V. I´ve set the threshold to 1.5V (tried 1V, 1.5V, 1.6V, 1.8V, 2V and 2.5V). Tried both slope modes. But when I set my logic state from 0 to 1 or 1 to 0, nothing happens. It feels like the state changes too fast to be sensed, but as the last post said, it should be no problem about this.
Any suggestions?

Thank you very much
Best regards
Jen John Lee

15 Sep 2009
Posts:

SOLVED!!!

I managed to solve the issue. The problem was that my ""Frames per capture"" on ""Aquisition Settings"" was too high (69), so I had to trigger my signal 69 times to update the screen (then it was able to save a file).
I´ve set it to 1, and it is working as desired.
I guess that I can use this feature (Frames per capture) to set how ""Averaging"" works. Am I right?

Thank you very much
Best regards
Jen John Lee
Back to Forum Index : Back to Questions   RSS
You must be logged in to post a reply



You need to Register or Log In before posting on these forums.

×

Your shopping cart is empty.