Tap Menu, then Math and then Edit...
IntroScoppy is firmware and an Android app that can be used with a Rasperry Pi Pico, Pico W or RP2040 to create a 2-channel, 150kHz oscilloscope.
Up until now a missing feature of Scoppy that is found on most oscilloscopes is math functions. With the release of version 1.027 of the Scoppy Android app this situation has now been remedied. Scoppy now supports two math channels that can be configured using a range of arithmetic functions.
Up to five functions and three sources can be combined to create a wide variety of formulas.
Enabling the Math Channel(s)Tap 'Menu' and then 'Math'. From here you can switch on or off either of the math channels or tapping 'Edit' will display the math settings screen.
For now we will tap MA1 to switch on the first math channel. The formula used to calculate the math waveform defaults to CH1 + CH2. Later on in this tutorial we will describe how to edit the formula.
Math channel measurements and vertical scale and positionNow that we have enabled the math channel, the channel badge, measurements and vertical selector for the channel will be displayed.
To change the vertical scale or position, tap the selector for the channel and then use the + and - buttons just as you would for any other channel.
Long tapping the channel badge will switch off the display of the channel waveform. To remove the channel badge from the screen use the same Math menu that was used to enable the math channel.
Note that you can switch off the source channels (in our example here both CH1 and CH2) and the math channel will still be displayed.
Now for the fun part - editing the formulas for the math channels. From the Math channel menu, tap Edit and the Math settings screen will be displayed.
The formula used for each math channel uses up to 2 operators (eg. add, subtract, log etc) and 3 operands. These operands consist of a source for the data (eg. CH1) and optionally a unary function (eg. LOG, LN, SQUARE, SQRT) to be applied to the source.
These 5 functions and 3 sources can be combined to create formulas as simple as LOG(CH1) or as complicated as SQUARE(CH1) x LOG(CH2) + SQRT(3.142)
A summary of the current formula is displayed below the settings.
Operators and operands are used to construct the math channel forumulas. If the operator is set to a unary function it is applied to the preceeding operand. If set to a binary function, the preceeding and succeeding operands are used as the variables of the function.
Where the 2nd operator is enabled, it uses the result of the previous function as the first variable.
The examples below will make this clearer - I hope :)
Math channel formula examplesCH1 + CH2
This is what the settings screen looks like with the first math channel (MA1) forumula configured to be CH1 + CH2. You'll notice that the 2nd operator is set to NONE which indicates that it is not used. The 3rd operand is also not used if the 2nd operator is set to NONE (or to a unary function) and so it is not displayed in this example.
LOG(CH1)
Now lets change the formula for MA1 to LOG(CH1). Tap the first operator for M1 (currently ADD) and change it LOG.
The summary will be updated to reflect the change. You'll also notice that the 2nd operand button (CH2) is no longer visible - this is because LOG is a unary function and so the 2nd operand is not used.
LOG(CH1) + CH2
Change the operator back to ADD. We now get our original CH1 + CH2 formula. To apply the LOG function to CH1, tap the first operand button and set the function to LOG.
The operand setting screen can also be used to select the source of data for the operand. This can be either CH1, CH2 or a constant value.
ABS(LOG(CH1) + CH2)
If we want to take the absolute value of the result of the previous formula simply set the 2nd operator to ABS.
ABS(LOG(CH1)+CH2) x 3.14
So far we haven't seen the 3rd operand. To make this visible set the 2nd operator to a binary function (eg. ADD, MULTIPLE, DIVIDE, SUBTRACT). In this example we want to multiply the result of the previous ADD operator by 3.14. To do this set the 2nd operator to MULTIPLY and then tap the button for the 3rd operand. Set the source to 'CONSTANT' and the constant value to 3.14
Check the displayed formula to verify the we have configured the channel correctly.
We are aware of the following limitations of the math channels and plan to fix these in future releases.
* The app doesn't automatically adjust the vertical scale when a math channel is configured. This might result in the math channel waveform being off the screen or maybe flat. You may have to adjust the vertical scale and/or position.
* A math channel cannot be used as the source for another math channel.
* Some common math functions are missing eg. differentiation and integration.
* The FFT of a math channel cannot be displayed.
Summary of math channel features* Up to two math channels can be displayed simultaneously
* Math channel formulas can contain up to 5 functions and 3 sources
* 11 functions are available with more to come
* The math waveform(s) can displayed even when the source channel(s) is(are) switched off
* Math channels can be used with XY mode
Scoppy premium upgrade
The math channels are only available if you have purchased the Scoppy premium upgrade or are using hardware that unlocks premium features (eg. the DSO-500K or DSO500K-U by FHDM TECH)
Comments
Please log in or sign up to comment.