|
Features
The alarms are controlled via the PC system clock, but it is also possible to use a internal stop watch. The internal stop watch is especially interesting to start sequence controls only when required and independent to the system clock. It is also possible to load all alarm lists every full hour. This way you can do changes on the .uhr files via a network by just overwriting the changed file(s). Since version 2.2.2.2 you can use the parameter /BUFFER to protect other channels to be reset while using the /ON or /OFF commands. Example see below "Optional parameter /BUFFER" To control more channels at one time use flags for the channel parameter. For example: licht24pro.exe /CONRADSERIAL /11000000 /ON switches the channel 1 + 2 of a Conrad card permanently to HIGH. With serial cards the in the program itself adjusted COM-port is used. The parameters need to be as shown in the example: licht24pro.exe /device /channel /time or licht24pro.exe /device /channel /ON or licht24pro.exe /device /channel /OFF or licht24pro.exe /device /flags /ON or licht24pro.exe /device /channel /ON /BUFFER or licht24pro.exe /device /channel /OFF /BUFFER Parameter device: 8255 AVR-NET-IO CONRADSERIAL CSI7002 CSI8 DEDITEC IO32USB IO88 K8055USB K8056 PARALLEL PCIREL16 USBOPTO16IO USBOPTOREL16 USBOPTOREL32 USBREL8 USBREL8LC USBTTL24 Parameter channel: Number of the output or 11111111 to switch 8 channels 1111111111111111 to switch 16 channels 111111111111111111111111 to switch 24 channels Example: licht24pro.exe /CONRADSERIAL /11000000 /ON switches the channel 1 + 2 of a Conrad card permanently to HIGH. Parameter time: Time in milliseconds (after the time has expired the channel is set to LOW automatically) or ON or OFF (switch channel to HIGH or LOW) Optional parameter /BUFFER: Using the /BUFFER command the last state of the outputs is stored in a file (buffer.txt). So it is possible to switch single channels with the /ON or /OFF command without turning off other outputs. Example: licht24pro.exe /CONRADSERIAL /1 /ON /BUFFER switches the channel 1 of a Conrad card to HIGH. then licht24pro.exe /CONRADSERIAL /2 /ON /BUFFER switches the channel 2 of a Conrad card to HIGH without resetting channel 1. To erase the buffer call Licht24 Pro as follows: licht24pro.exe /CLEARBUFFER or just edit the file buffer.txt in the Licht24 Pro installation folder. Optional parameter /STATUS: The state of the inputs of a Velleman K8055 USB can be read with this command line call. The values of the inputs are stored in the licht24pro.ini file and can be read out with your own external software. The command line with parameter is: licht24pro.exe /K8055USB /STATUS The variables in the licht24pro.ini are: [Velleman_K8055_USB] K8055USB_STATUS_0=0,0,0 K8055USB_STATUS_1=0,33,71 K8055USB_STATUS_2=0,0,0 K8055USB_STATUS_DATE=04\27\2010,10:53:06K8055USB_STATUS_0 is card no.1 with the values for DIGITAL,ANALOG1,ANALOG2 K8055USB_STATUS_1 is card no.2 with the values for DIGITAL,ANALOG1,ANALOG2 K8055USB_STATUS_2 is card no.3 with the values for DIGITAL,ANALOG1,ANALOG2 K8055USB_STATUS_DATE is the timestamp DATE,TIME HINT: Using flags or ON/OFF parameter the outputs remain in their state although the software stops. This can be a security risk, for example if the PC crashes you can NOT reset the outputs until reboot and rerun of the software. Using these functions is made at your own risk! The command line parameters can be sent also as a message (WMCopyData) to Licht24 Pro. The Licht24 Pro software is running permanently and can receive WMCopyData commands. This way you can send also commands from your own software to Licht24 Pro. In the Licht24 Pro installations directory there is a tool which can send commands to Licht24 Pro. The tool is called sndmsg.exe and is executed like Licht24 pro with command line parameter, eg. sndmsg.exe /CONRADSERIAL /11000000 /ON switches the channel 1 + 2 of a Conrad card to HIGH. Using sndmsg.exe to have parameter control we do not have to start and quit Licht24 Pro. This saves time and therefore a very short command sequence is possible. Here is the Delphi source code of sndmsg.exe (send data via WMCopyData).
unit usndmsg;
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
StdCtrls, Spin;
type
TForm1 = class(TForm)
procedure MySendMessage;
procedure FormCreate(Sender: TObject);
private
{ Private-Deklarationen }
public
{ Public-Deklarationen }
end;
var
Form1: TForm1;
implementation
{$R *.DFM}
procedure TForm1.MySendMessage;
var
aCopyData : TCopyDataStruct; // instance of the records
hTargetWnd : hWnd; // handle of Licht24 Pro
s : String;
i, x : Integer;
begin
// check parameter count
x := ParamCount;
if x = 0 then Exit;
// copy the parameters to a string
s := '';
for i := 1 to x do begin
s := s + ParamStr(i) + ' ';
end;
trim(s);
// set data
with aCopyData do begin
dwData := 0;
cbData := StrLen(PChar(s)) + 1;
lpData := PChar(s);
end;
// Find the receiver window for the message via the title
hTargetWnd := FindWindow(nil, PChar('Licht24 Pro'));
if hTargetWnd <> 0 then
SendMessage(hTargetWnd, WM_CopyData, LongInt(Handle), LongInt(@aCopyData));
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
Application.ShowMainForm := false;
MySendMessage;
Application.Terminate;
end;
end.
The program sndmsg.exe is executed with the command line parameters. These then are sent to Licht24 Pro by using WMCopyData.
Since version v2.3.2.6 there are special remote commands available:
Example: "sendmsg.exe /CMD_CLOSE" closes Licht24 Pro - Alarm list Log, shows all switches done by the alarm list timer. - All Log, shows all switches that has been done. - Error Log, shows all errors that has been appeared. | |||||||||||||||||||||
|
Copyright © 1997-2011 by bksoft | |||||||||||||||||||||