Samplers
A JSON object describing a signal generator sampler has the following syntax:
{
"@IoComponents.SignalGenerator.Sampler": {
"id": "Sampler",
"uuid": "e95ba266-c8eb-41fb-800c-de31b73f9fcb",
"children": [
...
]
}
}
- Object Members
id | A string value containing the ID of the sampler. The ID is used to construct the sampler’s primary key. |
uuid | A string value containing the unique UUID of the sampler. |
children | A JSON array containing the signals of the sampler.
Please remember that each element block requires two layers of {} due to the syntax restrictions of the JSON format.
|
Signals
A JSON object describing a signal generator signal has the following syntax:
{
"@IoComponents.SignalGenerator.Signal": {
"id": "Inspector 1",
"uuid": "391c774a-c2ee-45c4-acac-a9eda90a392f",
"dataType": "float32",
"top": 100,
"bottom": 0,
"waveForm": {
"@Pulse": {
"period": 5000000,
"phaseOffset": 0,
"pulseWidth": 1500000
}
}
}
}
- Object Members
id | A string value containing the ID of the signal. The ID is used to construct the signal’s primary key. |
uuid | A string value containing the unique UUID of the signal. |
dataType | The generated data type. The following data types are supported:
Keyword | Data Type |
"int8" | 8 bit signed integer |
"int16" | 16 bit signed integer |
"int32" | 32 bit signed integer |
"int64" | 64 bit signed integer |
"uint8" | 8 bit usigned integer |
"uint16" | 16 bit usigned integer |
"uint32" | 32 bit unsigned integer |
"uint64" | 64 bit unsigned integer |
"float32" | single precision floating point number |
"float64" | double precision floating point number |
"bool" | Boolean value. Wave form values greater than 0.5 are represented as true, Values less than or equal to 0.5 are represented as false |
|
top | A numeric value containing the top of the value range of the generated signal. If this value is less than bottom, then the wave form will be inverted. |
bottom | A numeric value containing the bottom of the value range of the generated signal. If this value is greater than top, then the wave form will be inverted. |
waveForm | A JSON object containing information about the wave form to generate. The object is a double nested JSON object. The outer object has a single member whose name is the type of wave form, and whose value is another JSON object that contains the actual properties of the wave form.
Signals generators support the following wave forms:
The inner object has the following members:
period | A numeric value containing the period of the generated wave, in microseconds.
This member is not available for @Noise wave forms.
|
phaseOffset | An optional numeric value containing the phase offset of the generated wave, in microseconds. The wave form will be shifted to the left by the specified number of microseconds, compared to wave forms with phase offset 0.
This member is not available for @Noise wave forms.
|
pulseWidth | The width, in microseconds, of the “up” phase of a pulse wave, where the value is equal to the top value. This value must be greater than 0, and less than the period.
This member is only available for @Pulse wave forms.
|
|