MetisControlDelegate Protocol Reference


Overview


The MetisControlDelegate protocol defines the optional methods implemented by the control delegate of the Metis object. The protocol is defined in Metis.h.

The first argument of the methods is the Metis object that sends the message to the delegate.


Tasks


Receiving Keying Changes

- metis:ptt:
-
metis:dah:
-
metis:dit:


ADC Overflows

- metis:adcOverflow:
-
metis:mercury:adcOverflow:


Power

- metis:board:forwardPower:
-
metis:board:reversePower:


Analog Voltages

- metis:powerSupply:
-
metis:analogInput:value:


Digital Bits

- metis:ioBit:state:


Static Information

- metis:board:versionNumber:


Mercury states

- metis:mercury:versionNumber:


Cyclops states

- metis:cyclopsFrequencyChanged:
-
metis:cyclopsPLLLock:


Undefined Controls

- metis:unusedControl:
-
metis:unusedControlChanged:



Instance Methods


metis:adcOverflow:

This message is sent when the overflow state of the primary radio's ADC changes state.

- (void)metis:(Metis*)metis adcOverflow:(Boolean)state

Parameters

metis
the Metis object that sent the message,

state
ADC overflow state.




metis:analogInput:value:


Analog voltage. The input is either 3 or 4. Analog input 1 and 5 are used to measure forward power, analog input 2 is used to reverse power, and analog input 6 is used to measure Hermes power supply voltage.

- (void)metis:(Metis*)metis analogInput:(int)input value:(float)voltage

Parameters

metis
the Metis object that sent the message,

input
either input 3 or input 4,

voltage
the measured voltage.




metis:board:forwardPower:

This message is sent when the forward power in one of the components changes. The power is expressed as a 12 bit integer.

- (void)metis:(Metis*)metis board:(HPSDRBoard)board forwardPower:(unsigned int)power

Parameters

metis
the Metis object that sent the message,

board
an HPSDR board type,

power
12-bit integer representation of the power.




metis:board:reversePower:

This message is sent when the forward power in one of the components changes. The power is expressed as a 12 bit integer.

- (void)metis:(Metis*)metis board:(HPSDRBoard)board reversePower:(unsigned int)power

Parameters

metis
the Metis object that sent the message,

board
an HPSDR board type,

power
12-bit integer representation of the power.




metis:board:versionNumber:

This is static information and is only issued when resendControls is sent to the Metis object. versionNumber is an integer representation of the firmware version. When divided by 10, the fractional part is the minor version number and the whole part is the major version number. I.e., 23 represents version 2.3.

- (void)metis:(Metis*)metis board:(HPSDRBoard)board versionNumber:(unsigned int)version

Parameters

metis
the Metis object that sent the message,

board
an HPSDR board type,

version
integer representation of the firmware version.




metis:cyclopsFrequencyChanged:

This message is sent when the Cyclops firmware changes frequency.

- (void)metis:(Metis*)metis cyclopsFrequencyChanged:(Boolean)state

Parameters

metis
the Metis object that sent the message,

state
always true.




metis:cyclopsPLLLock:

This message is sent when the Cyclops PLL Lock state changes.

- (void)metis:(Metis*)metis cyclopsPLLLock:(Boolean)state

Parameters

metis
the Metis object that sent the message,

state
PLL lock state in Cyclops.




metis:dah:

This message is sent when the "dah" contact closure from the Metis device has changed. This is typically the ring of a "Key" phone jack.

- (void)metis:(Metis*)metis dah:(Boolean)state

Parameters

metis
the Metis object that sent the message,

state
the new state of the contact closure.




metis:dit:

This message is sent when the "dit" contact closure from the Metis device has changed. This is typically the tip of a "Key" phone jack.

- (void)metis:(Metis*)metis dit:(Boolean)state

Parameters

metis
the Metis object that sent the message,

state
the new state of the contact closure.




metis:ioBit:state:


This message is sent when the I/O bits change. The ioBit is 1, 2, 3 or 4. State is true if the bit is active (0) and false if the bit is inactive (1).

- (void)metis:(Metis*)metis ioBit:(int)bit state:(Boolean)state

Parameters

metis
the Metis object that sent the message,

bit
the I/O bit,

state
state of the I/O bit.




metis:mercury:adcOverflow:

This message is sent when the overflow state of a Mercury board's ADC changes state. The Mercury index is 1, 2, 3 or 4.

- (void)metis:(Metis*)metis mercury:(int)mercury adcOverflow:(Boolean)state

Parameters

metis
the Metis object that sent the message,

index
is the index of one of multiple Mercury boards,

state
ADC overflow state.




metis:mercury:versionNumber:

This is static information and is only issued when resendControls is sent to the Metis object.

versionNumber is an integer representation of the firmware version of a Metis device that is connected to multiple Mercury boards. When divided by 10, the fractional part is the minor version number and the whole part is the major version number. I.e., 23 represents version 2.3.

- (void)metis:(Metis*)metis mercury:(int)index versionNumber:(unsigned int)version

Parameters

metis
the Metis object that sent the message,

index
is the index of one of multiple Mercury boards,

version
integer representation of the firmware version.




metis:powerSupply:

Indicates the power supply voltage. The accuracy depends of the zener reference and voltage divider toleraces. This can be calibrated by the application software.

- (void)metis:(Metis*)metis powerSupply:(float)voltage

Parameters

metis
the Metis object that sent the message,

voltage
approximate power supply voltage.




metis:ptt:

This message is sent when the "ptt" contact closure from the Metis device has changed.

- (void)metis:(Metis*)metis ptt:(Boolean)state

Parameters

metis
the Metis object that sent the message,

state
the new state of the contact closure.




metis:unusedControl:

As of HPSDR v1.47 Frame documentation,only control sequences whose first byte is between 0x00 and 0x20 are defined. To take care of future extensions, the Metis framework can send back any control sequences that are not decoded by the framework. The control sequence is a 5 byte string.

- (void)metis:(Metis*)metis unusedControl:(unsigned char *)sequence

Parameters

metis
the Metis object that sent the message,

sequence
a 5 byte HPSDR format control sequence.





metis:unusedControlChanged:

As of HPSDR v1.47 Frame documentation, only control sequences whose first byte is between 0x00 and 0x20 are defined. To take care of future extensions, the Metis framework can send back any control sequences that are not decoded by the framework. The control sequence is a 5 byte string.

The delegate is only called when the control sequence changes.

- (void)metis:(Metis*)metis unusedControlChanged:(unsigned char *)sequence

Parameters

metis
the Metis object that sent the message,

sequence
a 5 byte HPSDR format control sequence.