Functions
Signals
kvaDbLib

Add, delete and modify signals in messages. More...

## Functions
KvaDbStatus | kvaDbGetFirstSignal (KvaDbMessageHnd mh, KvaDbSignalHnd *sh)
KvaDbStatus | kvaDbGetNextSignal (KvaDbMessageHnd mh, KvaDbSignalHnd *sh)
KvaDbStatus | kvaDbGetSignalByName (KvaDbMessageHnd mh, char *buf, KvaDbSignalHnd *sh)
KvaDbStatus | kvaDbSetSignalMode (KvaDbSignalHnd sh, int mux)
KvaDbStatus | kvaDbGetSignalMode (KvaDbSignalHnd sh, int *mux)
KvaDbStatus | kvaDbGetSignalMessage (KvaDbSignalHnd sh, KvaDbMessageHnd *mh)
KvaDbStatus | kvaDbGetSignalValueFloat (KvaDbSignalHnd sh, double *f, void *data, size_t len)
KvaDbStatus | kvaDbGetSignalValueInteger (KvaDbSignalHnd sh, int *f, void *data, size_t len)
KvaDbStatus | kvaDbRetrieveSignalValuePhys (KvaDbSignalHnd sh, double *value, void *data, size_t len)
KvaDbStatus | kvaDbRetrieveSignalValueRaw (KvaDbSignalHnd sh, int *value, void *data, size_t len)
KvaDbStatus | kvaDbRetrieveSignalValueRaw64 (KvaDbSignalHnd sh, uint64_t *value, void *data, size_t len)
KvaDbStatus | kvaDbGetSignalValueEnum (KvaDbSignalHnd sh, char *buf, size_t buflen, void *data, size_t len)
KvaDbStatus | kvaDbGetSignalValueLimits (KvaDbSignalHnd sh, double *minval, double *maxval)
KvaDbStatus | kvaDbGetSignalValueScaling (KvaDbSignalHnd sh, double *factor, double *offset)
KvaDbStatus | kvaDbGetSignalValueSize (KvaDbSignalHnd sh, int *startbit, int *length)
KvaDbStatus | kvaDbGetSignalName (KvaDbSignalHnd sh, char *buf, size_t buflen)
KvaDbStatus | kvaDbGetSignalQualifiedName (KvaDbSignalHnd sh, char *buf, size_t buflen)
KvaDbStatus | kvaDbGetSignalComment (KvaDbSignalHnd sh, char *buf, size_t buflen)
KvaDbStatus | kvaDbGetSignalUnit (KvaDbSignalHnd sh, char *buf, size_t buflen)
KvaDbStatus | kvaDbGetSignalEncoding (KvaDbSignalHnd sh, KvaDbSignalEncoding *e)
KvaDbStatus | kvaDbGetSignalRepresentationType (KvaDbSignalHnd sh, KvaDbSignalType *t)
KvaDbStatus | kvaDbGetSignalPresentationType (KvaDbSignalHnd sh, KvaDbSignalType *t)
KvaDbStatus | kvaDbAddSignal (KvaDbMessageHnd mh, KvaDbSignalHnd *sh)
KvaDbStatus | kvaDbDeleteSignal (KvaDbMessageHnd mh, KvaDbSignalHnd sh)
KvaDbStatus | kvaDbSetSignalValueLimits (KvaDbSignalHnd sh, double minval, double maxval)
KvaDbStatus | kvaDbSetSignalValueScaling (KvaDbSignalHnd sh, double factor, double offset)
KvaDbStatus | kvaDbSetSignalValueSize (KvaDbSignalHnd sh, int startbit, int length)
KvaDbStatus | kvaDbSetSignalName (KvaDbSignalHnd sh, char *buf)
KvaDbStatus | kvaDbSetSignalComment (KvaDbSignalHnd sh, char *buf)
KvaDbStatus | kvaDbSetSignalUnit (KvaDbSignalHnd sh, char *buf)
KvaDbStatus | kvaDbSetSignalEncoding (KvaDbSignalHnd sh, KvaDbSignalEncoding e)
KvaDbStatus | kvaDbSetSignalRepresentationType (KvaDbSignalHnd sh, KvaDbSignalType t)
KvaDbStatus | kvaDbStoreSignalValuePhys (KvaDbSignalHnd sh, void *can_data, int len, double value)
KvaDbStatus | kvaDbStoreSignalValueRaw (KvaDbSignalHnd sh, void *can_data, int len, int value)
KvaDbStatus | kvaDbStoreSignalValueRaw64 (KvaDbSignalHnd sh, void *can_data, int len, uint64_t value)
KvaDbStatus | kvaDbGetFirstEnumValue (KvaDbSignalHnd sh, KvaDbEnumValueHnd *eh)
KvaDbStatus | kvaDbGetNextEnumValue (KvaDbSignalHnd sh, KvaDbEnumValueHnd *eh)
KvaDbStatus | kvaDbGetEnumValue (KvaDbEnumValueHnd eh, int *val, char *buf, size_t buflen)
KvaDbStatus | kvaDbGetFirstEnumValuePair (KvaDbSignalHnd sh, KvaDbEnumValueHnd *eh, int *val, char *buf, size_t buflen)
KvaDbStatus | kvaDbGetNextEnumValuePair (KvaDbSignalHnd sh, KvaDbEnumValueHnd *eh, int *val, char *buf, size_t buflen)
KvaDbStatus | kvaDbAddEnumValue (KvaDbSignalHnd sh, int val, const char *name)
KvaDbStatus | kvaDbDeleteEnumValue (KvaDbSignalHnd sh, KvaDbEnumValueHnd eh)

## Detailed Description

Add, delete and modify signals in messages.

## Function Documentation

## ◆ kvaDbAddEnumValue()

KvaDbStatus kvaDbAddEnumValue | ( | KvaDbSignalHnd | sh,
|  | int | val,
|  | const char * | name
| ) |  |

Add a new enumeration value to a signal.

Parameters

  [in] | sh | A signal handle
  [out] | val | The enumeration value
  [out] | name | The enumeration name

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbDeleteEnumValue()

## ◆ kvaDbAddSignal()

KvaDbStatus kvaDbAddSignal | ( | KvaDbMessageHnd | mh,
|  | KvaDbSignalHnd * | sh
| ) |  |

Add a new signal to a message.

Parameters

  [in] | mh | A message handle
  [out] | sh | A handle to the new signal

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbDeleteSignal()

Examples:
  candb_sample.c.

## ◆ kvaDbDeleteEnumValue()

KvaDbStatus kvaDbDeleteEnumValue | ( | KvaDbSignalHnd | sh,
|  | KvaDbEnumValueHnd | eh
| ) |  |

Delete an enumeration value from a signal.

Parameters

  [in] | sh | A signal handle
  [in] | eh | An enumeration value handle

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbAddEnumValue()

## ◆ kvaDbDeleteSignal()

KvaDbStatus kvaDbDeleteSignal | ( | KvaDbMessageHnd | mh,
|  | KvaDbSignalHnd | sh
| ) |  |

Delete a signal from a message.

Parameters

  [in] | mh | A message handle
  [in] | sh | A handle to the signal to delete

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbAddSignal()

Examples:
  candb_sample.c.

## ◆ kvaDbGetEnumValue()

KvaDbStatus kvaDbGetEnumValue | ( | KvaDbEnumValueHnd | eh,
|  | int * | val,
|  | char * | buf,
|  | size_t | buflen
| ) |  |

Get the string and integer from an enumeration value.

Parameters

  [in] | eh | An enumeration value handle
  [out] | val | The enumeration value
  [out] | buf | The buffer that will hold the enumeration name
  [in] | buflen | The length of the buffer

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetFirstEnumValue()

## ◆ kvaDbGetFirstEnumValue()

KvaDbStatus kvaDbGetFirstEnumValue | ( | KvaDbSignalHnd | sh,
|  | KvaDbEnumValueHnd * | eh
| ) |  |

Get the first enumeration value in a signal.

Parameters

  [in] | sh | A signal handle
  [out] | eh | A handle to the first enumeration value

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetNextEnumValue()

## ◆ kvaDbGetFirstEnumValuePair()

KvaDbStatus kvaDbGetFirstEnumValuePair | ( | KvaDbSignalHnd | sh,
|  | KvaDbEnumValueHnd * | eh,
|  | int * | val,
|  | char * | buf,
|  | size_t | buflen
| ) |  |

Get the string and integer from the first enumeration value for a signal.

Parameters

  [in] | sh | A signal handle.
  [out] | eh | An enumeration value handle
  [out] | val | The enumeration value
  [out] | buf | The buffer that will hold the enumeration name
  [in] | buflen | The length of the buffer

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

## ◆ kvaDbGetFirstSignal()

KvaDbStatus kvaDbGetFirstSignal | ( | KvaDbMessageHnd | mh,
|  | KvaDbSignalHnd * | sh
| ) |  |

Get the first signal in a message.

Parameters

  [in] | mh | A message handle
  [out] | sh | A handle to the first signal

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetNextSignal()

Examples:
  candb_sample.c.

## ◆ kvaDbGetNextEnumValue()

KvaDbStatus kvaDbGetNextEnumValue | ( | KvaDbSignalHnd | sh,
|  | KvaDbEnumValueHnd * | eh
| ) |  |

Get the next enumeration value in a signal. Should be called after kvaDbGetFirstEnumValue().

Parameters

  [in] | sh | A signal handle
  [out] | eh | A handle to the next enumeration value

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetNextEnumValue

## ◆ kvaDbGetNextEnumValuePair()

KvaDbStatus kvaDbGetNextEnumValuePair | ( | KvaDbSignalHnd | sh,
|  | KvaDbEnumValueHnd * | eh,
|  | int * | val,
|  | char * | buf,
|  | size_t | buflen
| ) |  |

Get the string and integer from the next enumeration value for a signal. Should be called after kvaDbGetFirstEnumValuePair().

Parameters

  [in] | sh | A signal handle.
  [out] | eh | An enumeration value handle
  [out] | val | The enumeration value
  [out] | buf | The buffer that will hold the enumeration name
  [in] | buflen | The length of the buffer

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

## ◆ kvaDbGetNextSignal()

KvaDbStatus kvaDbGetNextSignal | ( | KvaDbMessageHnd | mh,
|  | KvaDbSignalHnd * | sh
| ) |  |

Get the next signal in a message. Should be called after kvaDbGetFirstSignal().

Parameters

  [in] | mh | A message handle
  [out] | sh | A handle to the next signal

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetFirstSignal

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalByName()

KvaDbStatus kvaDbGetSignalByName | ( | KvaDbMessageHnd | mh,
|  | char * | buf,
|  | KvaDbSignalHnd * | sh
| ) |  |

Get a signal handle by seaching for the signals's name.

Parameters

  [in] | mh | A message handle
  [in] | buf | The buffer that contains the name of the signal to search for
  [out] | sh | A handle to the signal

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetFirstMsg()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalComment()

KvaDbStatus kvaDbGetSignalComment | ( | KvaDbSignalHnd | sh,
|  | char * | buf,
|  | size_t | buflen
| ) |  |

Get the signal comment.

Parameters

  [in] | sh | A signal handle
  [out] | buf | The signal comment
  [in] | buflen | The length of the buffer that will hold the signal comment

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbSetSignalComment()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalEncoding()

KvaDbStatus kvaDbGetSignalEncoding | ( | KvaDbSignalHnd | sh,
|  | KvaDbSignalEncoding * | e
| ) |  |

Get the signal encoding.

Parameters

  [in] | sh | A signal handle
  [out] | e | The signal encoding, Intel or Motorola, KvaDbSignalEncoding

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbSetSignalEncoding()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalMessage()

KvaDbStatus kvaDbGetSignalMessage | ( | KvaDbSignalHnd | sh,
|  | KvaDbMessageHnd * | mh
| ) |  |

Get handle to message, which given signal is associated with.

Parameters

  [in] | sh | A signal handle
  [out] | mh | Signal's message

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbStoreSignalValuePhys()

## ◆ kvaDbGetSignalMode()

KvaDbStatus kvaDbGetSignalMode | ( | KvaDbSignalHnd | sh,
|  | int * | mux
| ) |  |

Gets mux from multiplexer mode value of given signal. See KVADB_MUX_xxx for special (negative) values of multiplexer mode.

Parameters

  [in] | sh | A signal handle
  [out] | mux | Signal's multiplex mode

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  KVADB_MUX_xxx

## ◆ kvaDbGetSignalName()

KvaDbStatus kvaDbGetSignalName | ( | KvaDbSignalHnd | sh,
|  | char * | buf,
|  | size_t | buflen
| ) |  |

Get the signal name.

Parameters

  [in] | sh | A signal handle
  [out] | buf | The signal name
  [in] | buflen | The length of the buffer that will hold the signal name

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbSetSignalName()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalPresentationType()

KvaDbStatus kvaDbGetSignalPresentationType | ( | KvaDbSignalHnd | sh,
|  | KvaDbSignalType * | t
| ) |  |

Get the signal representation type.

Note
  This function is deprecated and will be replaced by kvaDbGetSignalRepresentationType()

Parameters

  [in] | sh |
  [out] | t | The signal representation type, KvaDbSignalType

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbSetSignalRepresentationType()

## ◆ kvaDbGetSignalQualifiedName()

KvaDbStatus kvaDbGetSignalQualifiedName | ( | KvaDbSignalHnd | sh,
|  | char * | buf,
|  | size_t | buflen
| ) |  |

Get the qualified signal name. which is the database, message ans signal names separated by dots.

Parameters

  [in] | sh | A signal handle
  [out] | buf | The qualified signal name
  [in] | buflen | The length of the buffer that will hold the qualified signal name

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalName()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalRepresentationType()

KvaDbStatus kvaDbGetSignalRepresentationType | ( | KvaDbSignalHnd | sh,
|  | KvaDbSignalType * | t
| ) |  |

Get the signal representation type.

Parameters

  [in] | sh | A signal handle
  [out] | t | The signal representation type, KvaDbSignalType

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbSetSignalRepresentationType()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalUnit()

KvaDbStatus kvaDbGetSignalUnit | ( | KvaDbSignalHnd | sh,
|  | char * | buf,
|  | size_t | buflen
| ) |  |

Get the signal unit.

Parameters

  [in] | sh | A signal handle
  [out] | buf | The signal unit
  [in] | buflen | The length of the buffer that will hold the signal unit

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbSetSignalUnit()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalValueEnum()

KvaDbStatus kvaDbGetSignalValueEnum | ( | KvaDbSignalHnd | sh,
|  | char * | buf,
|  | size_t | buflen,
|  | void * | data,
|  | size_t | len
| ) |  |

Retrieve signal's enumeration (string) value from can data.

Parameters

  [in] | sh | A signal handle
  [out] | buf | The buffer that will hold the enumeration string
  [in] | buflen | The length of the buffer.
  [in] | data | The data buffer to be converted
  [in] | len | The length of the data buffer

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbStoreSignalValueRaw()

## ◆ kvaDbGetSignalValueFloat()

KvaDbStatus kvaDbGetSignalValueFloat | ( | KvaDbSignalHnd | sh,
|  | double * | f,
|  | void * | data,
|  | size_t | len
| ) |  |

Retrieve signal's physical (floating-point) value from can data.

This function is deprecated and should not be used. Consider kvaDbRetrieveSignalValuePhys() instead

Parameters

  [in] | sh | A signal handle
  [out] | f | The converted value
  [in] | data | The data buffer to be converted
  [in] | len | The length of the data buffer

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbStoreSignalValuePhys()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalValueInteger()

KvaDbStatus kvaDbGetSignalValueInteger | ( | KvaDbSignalHnd | sh,
|  | int * | f,
|  | void * | data,
|  | size_t | len
| ) |  |

Retrieve signal's raw (integer) value from can data.

This function is deprecated and should not be used. Consider kvaDbRetrieveSignalValueRaw() instead

Parameters

  [in] | sh | A signal handle
  [out] | f | The converted value
  [in] | data | The data buffer to be converted
  [in] | len | The length of the data buffer

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbStoreSignalValueRaw()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalValueLimits()

KvaDbStatus kvaDbGetSignalValueLimits | ( | KvaDbSignalHnd | sh,
|  | double * | minval,
|  | double * | maxval
| ) |  |

Get the minimum and maximum values from a signal.

Parameters

  [in] | sh | A signal handle
  [out] | minval | The minimum value
  [out] | maxval | The maximum value

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbSetSignalValueLimits()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalValueScaling()

KvaDbStatus kvaDbGetSignalValueScaling | ( | KvaDbSignalHnd | sh,
|  | double * | factor,
|  | double * | offset
| ) |  |

Get the scale factor and offset from a signal.

Parameters

  [in] | sh | A signal handle
  [out] | factor | The signal scale factor
  [out] | offset | The signal offset

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbSetSignalValueScaling()

Examples:
  candb_sample.c.

## ◆ kvaDbGetSignalValueSize()

KvaDbStatus kvaDbGetSignalValueSize | ( | KvaDbSignalHnd | sh,
|  | int * | startbit,
|  | int * | length
| ) |  |

Get the size and position of the signal value.

Parameters

  [in] | sh | A signal handle
  [out] | startbit | The bit where the signal value starts
  [out] | length | The length of the signal value in bits

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbSetSignalValueSize()

Examples:
  candb_sample.c.

## ◆ kvaDbRetrieveSignalValuePhys()

KvaDbStatus kvaDbRetrieveSignalValuePhys | ( | KvaDbSignalHnd | sh,
|  | double * | value,
|  | void * | data,
|  | size_t | len
| ) |  |

Retrieve signal's physical (floating-point) value from can data.

Parameters

  [in] | sh | A signal handle
  [out] | value | The converted value
  [in] | data | The data buffer to be converted
  [in] | len | The length of the data buffer

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbStoreSignalValuePhys()

## ◆ kvaDbRetrieveSignalValueRaw()

KvaDbStatus kvaDbRetrieveSignalValueRaw | ( | KvaDbSignalHnd | sh,
|  | int * | value,
|  | void * | data,
|  | size_t | len
| ) |  |

Retrieve signal's raw (integer) value from can data.

Parameters

  [in] | sh | A signal handle
  [out] | value | The converted value
  [in] | data | The data buffer to be converted
  [in] | len | The length of the data buffer

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbStoreSignalValueRaw()

## ◆ kvaDbRetrieveSignalValueRaw64()

KvaDbStatus kvaDbRetrieveSignalValueRaw64 | ( | KvaDbSignalHnd | sh,
|  | uint64_t * | value,
|  | void * | data,
|  | size_t | len
| ) |  |

Retrieve signal's raw (integer) value from can data.

Parameters

  [in] | sh | A signal handle
  [out] | value | The converted value (64-bits)
  [in] | data | The data buffer to be converted
  [in] | len | The length of the data buffer

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbStoreSignalValueRaw64()

## ◆ kvaDbSetSignalComment()

KvaDbStatus kvaDbSetSignalComment | ( | KvaDbSignalHnd | sh,
|  | char * | buf
| ) |  |

Set the signal comment.

Parameters

  [in] | sh | A signal handle
  [in] | buf | The buffer that contains the signal comment

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalComment()

Examples:
  candb_sample.c.

## ◆ kvaDbSetSignalEncoding()

KvaDbStatus kvaDbSetSignalEncoding | ( | KvaDbSignalHnd | sh,
|  | KvaDbSignalEncoding | e
| ) |  |

Set the signal encoding.

Parameters

  [in] | sh | A signal handle
  [in] | e | The signal encoding, Intel or Motorola, KvaDbSignalEncoding

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalEncoding()

Examples:
  candb_sample.c.

## ◆ kvaDbSetSignalMode()

KvaDbStatus kvaDbSetSignalMode | ( | KvaDbSignalHnd | sh,
|  | int | mux
| ) |  |

Sets signal's multiplex mode. If value is equal to KVADB_MUX_SIGNAL, marks signal as a multiplexer.

Parameters

  [in] | sh | A signal handle
  [in] | mux | Signal's multiplex mode

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  KVADB_MUX_xxx

## ◆ kvaDbSetSignalName()

KvaDbStatus kvaDbSetSignalName | ( | KvaDbSignalHnd | sh,
|  | char * | buf
| ) |  |

Set the signal name.

Parameters

  [in] | sh | A signal handle
  [in] | buf | The buffer that contains the signal name

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalName()

Examples:
  candb_sample.c.

## ◆ kvaDbSetSignalRepresentationType()

KvaDbStatus kvaDbSetSignalRepresentationType | ( | KvaDbSignalHnd | sh,
|  | KvaDbSignalType | t
| ) |  |

Set the signal representation type.

Parameters

  [in] | sh | A signal handle
  [in] | t | The signal representation type, KvaDbSignalType

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalRepresentationType()

Examples:
  candb_sample.c.

## ◆ kvaDbSetSignalUnit()

KvaDbStatus kvaDbSetSignalUnit | ( | KvaDbSignalHnd | sh,
|  | char * | buf
| ) |  |

Set the signal unit.

Parameters

  [in] | sh | A signal handle
  [in] | buf | The buffer that contains the unit for the signal

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalUnit()

Examples:
  candb_sample.c.

## ◆ kvaDbSetSignalValueLimits()

KvaDbStatus kvaDbSetSignalValueLimits | ( | KvaDbSignalHnd | sh,
|  | double | minval,
|  | double | maxval
| ) |  |

Set the value limits for a signal.

Parameters

  [in] | sh | A signal handle
  [in] | minval | The minimum signal value
  [in] | maxval | The maximum signal value

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalValueLimits()

Examples:
  candb_sample.c.

## ◆ kvaDbSetSignalValueScaling()

KvaDbStatus kvaDbSetSignalValueScaling | ( | KvaDbSignalHnd | sh,
|  | double | factor,
|  | double | offset
| ) |  |

Set the scale factor and offset for a signal.

Parameters

  [in] | sh | A signal handle
  [in] | factor | The scale factor for the signal value
  [in] | offset | The offset for the signal value

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalValueScaling()

Examples:
  candb_sample.c.

## ◆ kvaDbSetSignalValueSize()

KvaDbStatus kvaDbSetSignalValueSize | ( | KvaDbSignalHnd | sh,
|  | int | startbit,
|  | int | length
| ) |  |

Set the value position and size for a signal.

Parameters

  [in] | sh | A signal handle
  [in] | startbit | The starting bit of the signal's value
  [in] | length | The length of the value in bits

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalValueSize()

Examples:
  candb_sample.c.

## ◆ kvaDbStoreSignalValuePhys()

KvaDbStatus kvaDbStoreSignalValuePhys | ( | KvaDbSignalHnd | sh,
|  | void * | can_data,
|  | int | len,
|  | double | value
| ) |  |

Convert a physical signal value to data bytes.

Parameters

  [in] | sh | A signal handle
  [out] | can_data | The buffer that will hold the converted value
  [in] | len | The length of the data buffer
  [in] | value | The physical signal value to convert

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbGetSignalValueFloat()

Examples:
  candb_sample.c.

## ◆ kvaDbStoreSignalValueRaw()

KvaDbStatus kvaDbStoreSignalValueRaw | ( | KvaDbSignalHnd | sh,
|  | void * | can_data,
|  | int | len,
|  | int | value
| ) |  |

Convert a raw signal value to data bytes.

Parameters

  [in] | sh | A signal handle
  [out] | can_data | The buffer that will hold the converted value
  [in] | len | The length of the data buffer
  [in] | value | The raw signal value to convert

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbRetrieveSignalValueRaw()

## ◆ kvaDbStoreSignalValueRaw64()

KvaDbStatus kvaDbStoreSignalValueRaw64 | ( | KvaDbSignalHnd | sh,
|  | void * | can_data,
|  | int | len,
|  | uint64_t | value
| ) |  |

Convert a raw signal value to data bytes.

Parameters

  [in] | sh | A signal handle
  [out] | can_data | The buffer that will hold the converted value
  [in] | len | The length of the data buffer
  [in] | value | The raw signal value to convert (64-bits)

Returns
  kvaDbOK (zero) if success
  kvaDbErr_xxx (negative) if failure

See also
  kvaDbRetrieveSignalValueRaw64()