Class AbstractSunSpecPvInverter

    • Method Detail

      • activate

        protected boolean activate​(org.osgi.service.component.ComponentContext context,
                                   java.lang.String id,
                                   java.lang.String alias,
                                   boolean enabled,
                                   int unitId,
                                   org.osgi.service.cm.ConfigurationAdmin cm,
                                   java.lang.String modbusReference,
                                   java.lang.String modbusId,
                                   int readFromCommonBlockNo,
                                   Phase phase)
                            throws OpenemsException
        Make sure to call this method from the inheriting OSGi Component.
        Parameters:
        context - ComponentContext of this component. Receive it from parameter for @Activate
        id - ID of this component. Typically 'config.id()'
        alias - Human-readable name of this Component. Typically 'config.alias()'. Defaults to 'id' if empty
        enabled - Whether the component should be enabled. Typically 'config.enabled()'
        unitId - Unit-ID of the Modbus target
        cm - An instance of ConfigurationAdmin. Receive it using @Reference
        modbusReference - The name of the @Reference setter method for the Modbus bridge - e.g. 'Modbus' if you have a setModbus()-method
        modbusId - The ID of the Modbus bridge. Typically 'config.modbus_id()'
        readFromCommonBlockNo - the starting block number
        phase - the phase the inverter is connected
        Returns:
        true if the target filter was updated. You may use it to abort the activate() method.
        Throws:
        OpenemsException - on error
      • activate

        protected boolean activate​(org.osgi.service.component.ComponentContext context,
                                   java.lang.String id,
                                   java.lang.String alias,
                                   boolean enabled,
                                   int unitId,
                                   org.osgi.service.cm.ConfigurationAdmin cm,
                                   java.lang.String modbusReference,
                                   java.lang.String modbusId,
                                   int readFromCommonBlockNo)
                            throws OpenemsException
        Overrides:
        activate in class AbstractOpenemsSunSpecComponent
        Throws:
        OpenemsException
      • handleEvent

        public void handleEvent​(org.osgi.service.event.Event event)
        Make sure to call this method from the inheriting OSGi Component.

        Requires:

         property = { //
           EventConstants.EVENT_TOPIC + "=" + EdgeEventConstants.TOPIC_CYCLE_EXECUTE_WRITE //
         }
         
        Specified by:
        handleEvent in interface org.osgi.service.event.EventHandler
      • debugLog

        public java.lang.String debugLog()
        Description copied from interface: OpenemsComponent
        Gets some output that is suitable for a continuous Debug log. Returns 'null' by default which causes no output.
        Specified by:
        debugLog in interface OpenemsComponent
        Returns:
        the debug log output
      • isSinglePhase

        protected final boolean isSinglePhase()