0
Beantwoord

Is there a way to trigger some values/tags on iRidiumServer Linux x64?

Martin Lang 6 jaar geleden bijgewerkt 6 jaar geleden 4

Is it possible to get values directly into iRidium Server from within the linux bash? 


Or is the only way the workaround to make a local tcp connection to bring in some comments?

+1
Beantwoord

Hello

Unfortunately, we can not offer a simple method of exchange through the command line. You can try experimenting through working with GPIO (because in Linux it's  just a file that we can change from the command line), but there are no
ready-made examples for this.

ok thx. i'll try to make it via a udp or tcp server and send commands on the bash/scripts via the shortcuts method listed on this website: http://xmodulo.com/tcp-udp-socket-bash-shell.html

+3
IR.AddListener(IR.EVENT_START,0,function()
{
   //AV & Custom Systems (File)
   var device = IR.CreateDevice(IR.DEVICE_CUSTOM_STREAM, "name", {FileName:'/home/user/abc'});
   var val = 0;
   IR.AddListener(IR.EVENT_ONLINE, device, function()
   {
     IR.Log("ONLINE");
   });
 
    IR.AddListener(IR.EVENT_OFFLINE, device, function()
   {
     IR.Log("OFFLINE");
   });
 
   IR.AddListener(IR.EVENT_RECEIVE_DATA, device, function(data)
   {
     IR.Log("DATA RECEIVED: " + data);
   });
 
   function Blink()
   {
     val = (val) ? 0 : 1;
     if(device)
     device.Send([val.toString()]);
   }
 
   //IR.SetInterval(5000, Blink);
  });
$ echo command:1 > /home/user/abc
ls -l /home/user/abc
chmod 744 /home/user/abc