Welcome!

On this forum you can discuss iRidium with other users. iRidium consist of 2 main components - i3 pro app and iRidium Server. Please post here your questions, ideas or errors you find.

Please send your questions to support team as a private messages.


Please subscribe to the Change Log to know our news

+2
Answered
Dmitry Ryzhkov 10 months ago in iRidium Script • updated by Andrey S 4 months ago 4

Здравствуйте,


когда можно ожидать добавление функционала .AddChannel & .AddTag


Это очень необходимо для динамического создания драйверов и их каналов.

+2
Voting
Damian Hartin 1 year ago in iRidium Script • updated by Oksana (expert) 1 year ago 3

As per my other topic for info on the new list..

Direction doesn't seem to work? Even in the sample list project you have provided...?

Answer
Oksana (expert) 1 year ago

Hello Damian,

The new list doesn't support Direction now.The new list have a minimal functional in the first release. In future, we plan to improve them.

+1
Declined
geurtsd 1 year ago in iRidium Script • updated 9 months ago 9

Dear support team,


Despite the fact that your training and reference material has grown and professionalised a lot over the time, would it bw possible to publish a list of supported methods of standard javascript? Or a javascript version that the script editor is based on so we can research it ourselves?


I find regularly that standard javascript methods do not work in iridium, which makes it cumbersome to troubleshoot if I did something wrong in my programming, or if the method s just not supported.....


one example: Array method "indexOf"


thanks in advance.


cheers

Answer

Polifill for indexOf("item of array")
add this script in your project and you will be able to use indexOf(array) thats available in ECMA5


// Polifill, IndexOf
// ECMA-262, 5, 15.4.4.14
// http://es5.github.io/#x15.4.4.14

if (!Array.prototype.indexOf) {
  Array.prototype.indexOf = function(searchElement, fromIndex) {
    var k;

    if (this == null) {
      throw new TypeError('"this" is null or not defined');
    }

    var O = Object(this);

    var len = O.length >>> 0;

    if (len === 0) {
      return -1;
    }

    var n = +fromIndex || 0;

    if (Math.abs(n) === Infinity) {
      n = 0;
    }

    if (n >= len) {
      return -1;
    }


    k = Math.max(n >= 0 ? n : len - Math.abs(n), 0);

    while (k < len) {

      if (k in O && O[k] === searchElement) {
        return k;
      }
      k++;
    }
    return -1;
  };
}

then you can use it:

var arr = ["All Systems", "Floor 1", "Room 1", "Room 3", "Room 4"];

var a = arr.indexOf("Room 1");
IR.Log(a);   // 2


+1
Voting
Dmitry Ryzhkov 1 year ago in iRidium Script • updated 7 months ago 5
Hello.
Please consider a new opportunity to work with lists of type List to develop new drivers.
At the moment the list is announced in the script,
var myList = Module.GetPopup ("myPopup"). GetItem ("myList");
It has the right to life in the development of drivers for i3 Lite.
In the transition to the development of drivers for i3 Pro it becomes a problem, because the driver is closed and it does not make a difference.
Therefore, you must manage the list of drivers through the channels (Commands and Feedback)
Thus to connect to the driver list is necessary and sufficient to throw drayveha channels on the list in the interface.
In the driver pressing on the list will be processed through IR.EVENT_CHANNEL_SET, and display information through Module.SetFeedback ('myList', [data]);
I am more than sure that there are nuances, but the meaning is clear about.

0
Answered
Braet Stijn 2 weeks ago in iRidium Script • updated by Aleksandr Romanov (CTO) 2 weeks ago 2

Is it possible to change  the image stretch to 'proportional' with a JS -script?

0
mbutuzov 1 month ago in iRidium Script 0

Здравствуйте, можно ли отловить в скрипте - нажатие на кнопку "Скрыть клавиатуру".


Если нет, не могли бы вы добавить данный функционал?


С помощью события  IR.EVENT_KEYBOARD_SHOW я отслеживаю момент открытие клавиатуры и произвожу соответствующие действия.


После нажатия указанной кнопки (закрытия клавиатуры), я хочу выполнить другие действия, но не могу это сделать, т.к. событие  IR.EVENT_KEYBOARD_HIDE отсутствует в API.


Заранее спасибо.




0
Not a bug
Lance 1 month ago in iRidium Script • updated 1 month ago 7

The template/clones are all transparent. When switching the substate colors of a list, it always appears solid black and no other color is possible. In other words, ListName.Color doesn't seem to work.


I thought I had broken some code, but adding the same correct commands to your item_good_list demos I get the same results. is there another way to change the background of a good_list? 

0
AdG 1 month ago in iRidium Script • updated by Andrey S 1 month ago 1

I woulld like to use 1 Popup for several different rooms. So, I want to connect the feedback channels to the value property of the buttons on the Popup.

I made a script that puts the name of the channels in some project tokens. And now I want to connect the channel to the value property. So, not the value of the channel as text on the button at the moment the script is running. But, the value has to change, when the value in the channel is changing.

Can that be done? Or is that only possible by making an AddListener function to check the changing of the value, and then updating the value of the button?

0
Waiting for user's reply
igor 2 months ago in iRidium Script • updated by Ilya Markov (expert) 1 month ago 3

Feedback value doesn't seem to work. It returns "false" instead of the appropriate Temp mode value.


IR.GetDevice('iRidium Server').GetFeedback("Domintell Network (UDP).Temperature Sensor 3608:Temperature Mode")


any suggestions?

0
Waiting for user's reply
igor 2 months ago in iRidium Script • updated 2 months ago 2

How do you change properties for the list items in a template?

My template has 2 dynamic images next to eachother, so for each listitem I need to set 2 url's.


For example:

var list = IR.GetPopup("Pop_camera").GetItem("camera_list");

list.CreateItem(0,1,{Image: urlPrefix+cameras[i]});