Package fr.soleil.salsa.entity.impl

Examples of fr.soleil.salsa.entity.impl.ActuatorImpl


                        if (actuatorsValueKeysArray != null) {
                            for (String actuatorValueKey : actuatorsValueKeysArray) {
                                entityName = TangoDeviceHelper.getEntityName(actuatorValueKey);
                                actuatorName = TangoAttributeHelper.getLabel(scanServerName, entityName);
                                actuator = new ActuatorImpl();
                                actuator.setName(actuatorName);
                                actuator.setEnabled(true);
                                // X Actuator
                                if (entityName.startsWith("actuator_1")) {
                                    actuatorList = scanResult.getActuatorsXList();
View Full Code Here


                DeviceAttribute actuatorXValueAttribute;
                for(int actuatorXIndex = 0;
                        actuatorXIndex < actuatorsXNamesArray.length && actuatorXIndex < actuatorsXValueKeysArray.length;
                        ++actuatorXIndex) {
                    actuatorXName = actuatorsXNamesArray[actuatorXIndex];
                    actuatorX = new ActuatorImpl();
                    actuatorX.setName(actuatorXName);
                    actuatorX.setEnabled(true);
                    scanResult.getActuatorsXList().add(actuatorX);
                   
                    actuatorXValueKey = actuatorsXValueKeysArray[actuatorXIndex];
                   
                    actuatorXValueAttribute = scanServerProxy.read_attribute(actuatorXValueKey);
                    actuatorXValuesArray = AttributeHelper.extractToDoubleArray(actuatorXValueAttribute);
                    actuatorX.setScanServerAttributeName(scanServerProxy.get_name() + "/" + actuatorXValueKey);

                    row = 0;
                    column = 0;
                    for(double actuatorXValue : actuatorXValuesArray) {
                        scanPointsMatrix[row][column].getActuatorsXValuesMap().put(actuatorX, actuatorXValue);
                        ++column;
                        if(column >= columnsNumber) {
                            column = 0;
                            ++ row;
                        }
                    }
                }
   
                // Actuators dimension Y
                String[] actuatorsYNamesArrayTmp = scanServerProxy.read_attribute("actuators2").extractStringArray();
                // The actuatorsYNamesArrayTmp contains the data twice : once for reading and once for writing.
                String actuatorYName;
                String[] actuatorsYNamesArray = new String[actuatorsYNamesArrayTmp.length / 2];
                for(int actuatorYIndex = 0; actuatorYIndex < actuatorsYNamesArray.length; ++actuatorYIndex) {
                    actuatorsYNamesArray[actuatorYIndex] = actuatorsYNamesArrayTmp[actuatorYIndex];
                }
               
                String[] actuatorsYValueKeysArray = scanServerProxy.read_attribute("actuators2DataList").extractStringArray();
                IActuator actuatorY;
                String actuatorYValueKey;
                double[] actuatorYValuesArray;
                DeviceAttribute actuatorYValueAttribute;
                for(int actuatorYIndex = 0;
                        actuatorYIndex < actuatorsYNamesArray.length && actuatorYIndex < actuatorsYValueKeysArray.length;
                        ++actuatorYIndex) {
                    actuatorYName = actuatorsYNamesArray[actuatorYIndex];
                    actuatorY = new ActuatorImpl();
                    actuatorY.setName(actuatorYName);
                    actuatorY.setEnabled(true);
                    scanResult.getActuatorsYList().add(actuatorY);
                   
                    actuatorYValueKey = actuatorsYValueKeysArray[actuatorYIndex];
View Full Code Here

                        if (actuatorsValueKeysArray != null) {
                            for (String actuatorValueKey : actuatorsValueKeysArray) {
                                entityName = TangoDeviceHelper.getEntityName(actuatorValueKey);
                                actuatorName = TangoAttributeHelper.getLabel(scanServerName, entityName);
                                actuator = new ActuatorImpl();
                                actuator.setName(actuatorName);
                                actuator.setEnabled(true);
                                // X Actuator
                                if (entityName.startsWith("actuator_1")) {
                                    actuatorList = scanResult.getActuatorsXList();
View Full Code Here

                double[] actuatorXValuesArray;
                DeviceAttribute actuatorXValueAttribute;
                for (int actuatorXIndex = 0; actuatorXIndex < actuatorsXNamesArray.length
                        && actuatorXIndex < actuatorsXValueKeysArray.length; ++actuatorXIndex) {
                    actuatorXName = actuatorsXNamesArray[actuatorXIndex];
                    actuatorX = new ActuatorImpl();
                    actuatorX.setName(actuatorXName);
                    actuatorX.setEnabled(true);
                    scanResult.getActuatorsXList().add(actuatorX);

                    actuatorXValueKey = actuatorsXValueKeysArray[actuatorXIndex];
View Full Code Here

            dim.getRangesXList().add(r);
        }

        // Actuators
        for (int i = 0; i < _nbActuators; i++) {
            IActuator a = new ActuatorImpl();
            a.setName("/mon/actuator/" + i);
            a.setEnabled(i % 2 == 0);
            dim.getActuatorsList().add(a);
        }

        for (int i = 0; i < dim.getRangesXList().size(); i++) {
            for (int j = 0; j < dim.getActuatorsList().size(); j++) {
View Full Code Here

    /**
     * Default constructor, that creates a new instance of ActuatorImpl and wraps it.
     */
    public ActuatorModel() {
        this(new ActuatorImpl());
    }
View Full Code Here

                        if (actuatorsValueKeysArray != null) {
                            for (String actuatorValueKey : actuatorsValueKeysArray) {
                                entityName = TangoDeviceHelper.getEntityName(actuatorValueKey);
                                actuatorName = TangoAttributeHelper.getLabel(scanServerName, entityName);
                                actuator = new ActuatorImpl();
                                actuator.setName(actuatorName);
                                actuator.setEnabled(true);
                                // X Actuator
                                if (entityName.startsWith("actuator_1")) {
                                    actuatorList = scanResult.getActuatorsXList();
View Full Code Here

        // Add Range
        view.addRange(2);

        // Add actuator
        IActuator actuator = new ActuatorImpl();
        actuator.setName("tango/tangotest/1/ampli");
        actuator.setEnabled(true);
        List<IActuator> actuatorList = new ArrayList<IActuator>();
        actuatorList.add(actuator);

        actuator = new ActuatorImpl();
        actuator.setName("tango/tangotest/2/ampli");
        actuator.setEnabled(true);
        actuatorList.add(actuator);

        view.addDevice(actuatorList);

        // Set HCS
        view.setHCSTrajectory(true);
        view.setYTrajectory(false);

        view.clearTrajectoriesView();

        actuatorList.clear();

        // Add Range
        view.addRange(1);

        actuator = new ActuatorImpl();
        actuator.setName("tango/tangotest/1/short_scalar_w");
        actuator.setEnabled(true);
        actuatorList.add(actuator);

        actuator = new ActuatorImpl();
        actuator.setName("tango/tangotest/2/short_scalar_w");
        actuator.setEnabled(true);
        actuatorList.add(actuator);

        view.addDevice(actuatorList);

        // Set HCS
View Full Code Here

                    String actuatorXValueKey;
                    double[] actuatorXValuesArray;
                    for (int actuatorXIndex = 0; actuatorXIndex < actuatorsXNamesArray.length
                            && actuatorXIndex < actuatorsXValueKeysArray.length; ++actuatorXIndex) {
                        actuatorXName = actuatorsXNamesArray[actuatorXIndex];
                        actuatorX = new ActuatorImpl();
                        actuatorX.setName(actuatorXName);
                        actuatorX.setEnabled(true);
                        scanResult.getActuatorsXList().add(actuatorX);

                        actuatorXValueKey = actuatorsXValueKeysArray[actuatorXIndex];
View Full Code Here

    /**
     * Default constructor, that creates a new instance of ActuatorImpl and wraps it.
     */
    public ActuatorModel() {
        this(new ActuatorImpl());
    }
View Full Code Here

TOP

Related Classes of fr.soleil.salsa.entity.impl.ActuatorImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.