Copyright © Glensound Electronics Ltd and individual contributors. All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. Neither the name of Glensound nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Content based on github.com/github/opensource.guide used under the CC-BY-4.0 license.
The common Glensound protocol is documented in GsProtocol.html and defined in common header files Gs*.h. This document refers to device-specific details of the Glensound Spark device, defined in the file Spark.h.
struct Status
The status structure extends Gs::Status
(file GsStatus.h)
The following fields are specific to Spark:
uint8_t reportGenerations[4]
Report generation numbers
0: UI state report generation
1: Mic preamp report generation
2..3: padding
uint8_t meters[20]
Audio meter values:
0..7: Dante Out channels
8..15: Dante In channels
16: Mic input
17-19: reserved
uint8_t leds
LED state bits (0 = off, 1 = on)
bit 0: PGM button
bit 1: TB1 button
bit 2: TB2 button
bit 3: TB3 button
bit 4: Power
int8_t temperature
Internal unit temperature, T = 0.5 * temperature + 44 (in Celsius).
The following standard commands are supported (file GsCommands.h):
Command::AdcSettings
Command::DacSettings
Command::RestoreDefaults
Command::ChannelName
Spark-specific commands are:
Command::MicGain
Sets the gain of the microphone input. The value is in the range of 0 to 63, mapping to the gains of -8 to 55 dB. The command uses the
Value8
structure, where theparam1
andparam2
fields are unused.
Command::Phantom
Enables or disables +48V phantom power for the microphone input. The command uses the
OffOnMsg
structure, where theindex
field is unused.
Command::Compressor
Enables or disables slow compressor on the microphone input. Enabling the compressor boosts gain by +18 dB. The command uses the
OffOnMsg
structure, where theindex
field is unused.
Command::PotVolume
Sets volume of one of the audio channels. The value is in the range 0 to 127, in 0.5 dB steps, where 104 is 0 dB. The command uses the
VolumeMsg
structure.
Command::PotPan
Sets panning of one of the audio channels. The value is in the range -7 to +7, with -7 mapping to far left, 0 to centre and +7 to far right. The command uses the
PanMsg
structure.
Command::Button
Sends a press/release event for one of the buttons on the unit's top panel. The command has the same effect as physically operating the button. The command uses the
OffOnMsg
structure, where theindex
field is the button identifier (as the ButtonId enumeration) in the range 0 to 3. Note that the Alt and Pan buttons on the unit's side are not affected.
Command::ButtonMode
Sets the button mode for one of the buttons on the unit's top panel. The command uses the
ButtonModeMsg
structure, where thebuttonId
field is the button identifier in the range 0 to 3. Note that the Alt and Pan buttons on the unit's side are not affected.
Command::PotMode
Sets the volume pot mode for one of the audio channels. Currently, two modes are supported:
PotMode::Unlimited
andPotMode::Limited
. In unlimited mode, the volume can be turned down until it gets muted, while in limited mode there is a lower limit for the volume, to ensure that audio is never muted. The command uses thePotModeMsg
structure.
Command::PgmMuteEnable
Enables or disables muting of the PGM output when TB1, TB2 and/or TB3 outputs are active. The command uses the
PgmMuteEnableMsg
structure, where thebuttonId
field is in the range of 1 to 3 (meaning that only TB1, TB2 and TB3 buttons may affect PGM).
Command::MicGainLock
Unlocks or locks the microphone input gain control on the unit's rear panel. The command uses the
OffOnMsg
structure, where theindex
field is unused.
Command::PhantomLock
Unlocks or locks the phantom power control on the unit's rear panel. The command uses the
OffOnMsg
structure, where theindex
field is unused.