Skip to main content

system.kanoa.asset.getModeSourceId

This function requires KanoaOPS module

Description

Returns the modeSourceId for a given modeSourceName. Used to store info on who set the modeEvent i.e. Operator, schedule, plc, etc. (kanoaOPS)

Syntax

getModeSourceId(modeSourceName)
  • Parameters
      modeSourceName (string) - The name of the mode source
  • Returns
      modeSourceId (int) - The ID corresponding to the modeSourceName
  • Code Examples

    # Example Usage:
    mode_source_id = system.kanoa.asset.getModeSourceId('Operator')
    print(f"The modeSourceId for 'Operator' is {mode_source_id}.")