From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Assignment help - new

Please help, i need help with the following assignment, I am new to this and so I am pretty stuck:

 

This assignment is designed to work on a sampled TTL square wave of up to 100 samples stored in an appropriate array. The two logic states are represented by the following values:

 

          A logic 1 (High) by a value of 5 + 0.5 (V).

 

          A logic 0 (low) by a value of 0 + 0.5 (V).

 

Specification 1 (65%)

 

To design a VI that will identify every transition between either of the two states and calculate the number of Logic 1s as a percentage of the total number of samples.

 

The front panel will consist of the following:

 

          An array of controls holding the sampled values.

 

          An array of indicators holding the index values of where each transitions occurred.

 

          An indicator holding the percentage of high values.

 

Hint: Research Build array and Initialise array functions.

 

Specification 2 (75%)

 

To design a VI that will meet specification 1 and can also be used as a sub VI in another VI. The sub VI should be fully documented, have its own icon and connector pane.

 

Specification 3 (100%)

 

To design a VI that will meet Specification 2 and will also be capable of detecting any errors that occur: i.e. samples that fall outside the permitted ranges. If errors are detected analysis should be aborted and the samples in error identified in an appropriate manner.

0 Kudos
Message 1 of 11
(5,007 Views)

Start here.  It'll get you very far.

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 2 of 11
(4,991 Views)

Thanks for that...

 

But I am asking for help, not a solution! I am pretty stumped.

0 Kudos
Message 3 of 11
(4,985 Views)

And what help are you asking for?

 

What have you done so far?

What hardware do you have?

What LabVIEW version do you have?

0 Kudos
Message 4 of 11
(4,971 Views)

A point in the right direction, a starting point.

 

I was trying to do a paper trace but keep hitting a wall. I made an array but was unsure about which values should go into it. I was trying to find a way to identify the transitions but really am not sure how to do it. And then calculating the number of logic ones as a percentage of the total number of samples is a whole other story...

 

I am using a PC

 

Versio 8.6 of labVIEW

0 Kudos
Message 5 of 11
(4,964 Views)

Shift Registers are your friend here.  Use a shift register to keep track of your transition locations, another one for the number of 1s, and a third for keeping the previous state.  By keeping the previous state, you can check to see if the previous state and the new state are different (a transition occurred).


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 6 of 11
(4,950 Views)

Ok thanks, hopefully a start in the right direction 🙂

0 Kudos
Message 7 of 11
(4,947 Views)

Here's a quick-and-dirty sample data generator.  It's something to get you started looking for the transitions.

 

DataGenerator.png

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

0 Kudos
Message 8 of 11
(4,940 Views)

Thanks Jim, much appreciated.

0 Kudos
Message 9 of 11
(4,936 Views)

thank you jim

0 Kudos
Message 10 of 11
(4,063 Views)