#17154 - 01/18/07 04:48 PM
Re: Code for Blinds - SECU16
[Re: Andre Ramos]
|
Dowser
journeyman
Registered: 12/04/06
Posts: 73
Loc: Sweden
|
Not an answer to your question, but...
You don't seem to have any form of time-out for the motors, does the hardware take care of turning the motor of in the end-possitions?
|
|
Top
|
|
|
|
#17163 - 01/19/07 12:51 PM
Re: Code for Blinds - SECU16
[Re: Andre Ramos]
|
Guy Lavoie
Beyond All Hope
   
Registered: 12/21/02
Posts: 6401
Loc: Montreal, QC, Canada
|
Quote:
Guy,
So, actually (if I got it right) the response speed would be affected by:
- Total Number of inputs and outputs, as I understand the table gets updated regardless the program uses them or not. - Number of program lines. - "stuff" sent out to the bus line.
Being the case, it wouldn't make such a big difference (except for program execution time) if I call only a few points or if I call a lot of them.
I put this question because yesterday I was testing a routine only with a partial amount of points... and the response time was acceptable to the customer.
Am I right ?
Essentially yes, that's it. I'd like to know more about your test "with a partial amount of points". Was it noticeably faster then a program looking at more i/o points, or are you just saying that with whatever delay you were seeing, you were wondering if adding more i/o points to the same program would affect its speed? Adding more code for additionnal i/o points should not be noticeable. A greater source of slowdowns would be to add a few more expansion modules. To really see any difference with program length, you would need to go say from a 100 line program to a 1000 line one. Even then, your source of delays is more related to the bus scanning routine then program looping speed. A 300 line program will loop maybe 3 or 4 times per second. At 1000 lines, it will loop about 2 times per second.
If your programs start to get really long (1000 lines or more) then you can often optimize it with Skip To statements (to answer your last post). If a code section is dealing exclusively with looking for changes in i/o module inputs, you could read all the module inputs as a data value (IF Data for Module...) and compare that against the value from the previous pass. If nothing has changed, then you can skip the entire input reading routine. The same can be done with: Leopard button presses, Incoming X-10 commands and received IR. My own program is over 2100 lines long and it runs like a 500 line one. Let me know if you want to know more about this.
Lastly, is the Comms LED on your Ocelot blinking rapidly and constantly, with the occasional short pause every 10 seconds or so?
_________________________
"If you don't know what you're doing, do it neatly..."
|
|
Top
|
|
|
|
#17164 - 01/19/07 01:25 PM
Re: Code for Blinds - SECU16
[Re: Guy Lavoie]
|
Andre Ramos
newbie
Registered: 02/21/03
Posts: 23
Loc: Portugal Europe
|
The Comms LED blinks more like rapidly and constantly. The actual hardware layout is: - Ocelot - 6 ea SECU16 - 11 ea Infrared Receivers - Vishay TSOP1238 (I had a lot of interference with the 1738, 1238 works fine all in parallel). - XM10 (powerline interface, European) - SC9000 SafeGuard (aka Protector Plus) Console for 16 addresses telephone communication. - For lights and other appliances I use X10 modules and micromodules.
The Ocelot program will have "this part" for controlling the blinds, then other sections:
- Read IR digits (from 0 to 9) and compose them into a decimal pair like 11,12,13....99. This will be the addressing of every point infraredwise. Read IR commands and convert to X10 functions. - Conversion Section of decimal reads of IR and X10 addresses like: A1=11, A2=12...,...F9=99. - Conversion Section of X10 addresses and the blinds ran by SECU's.
The idea is: - use X10 addresses on the CM11 for creating scenarios and timers, crating Macros on address from G - use remote control in any location of the house to control any address from A01 to F08, with the same remote, that's why I change it to decimal, otherwise using the X10 addresses I could only run one House Code at a time. - Trigger Macro (stored on CM11) by telephone. - Control over the internet using BlueIris and Zeus (www.zeushome.com), similar to our demo site on http://camera.domvs-sapiens.com
_________________________
Freedom is having an ELSE for every THEN
|
|
Top
|
|
|
|
#17165 - 01/19/07 01:51 PM
Re: Code for Blinds - SECU16
[Re: Andre Ramos]
|
Dowser
journeyman
Registered: 12/04/06
Posts: 73
Loc: Sweden
|
The demo-site you link to requires authentication, is it available for us?
|
|
Top
|
|
|
|
Moderator: Dan Smith, Monte G, ADI Tech Support, Guy Lavoie
|
1 registered
(kuro)
and 21 anonymous users online.
|
|
2747 Members
19 Forums
3837 Topics
22714 Posts
Max Online: 67 @ 08/16/11 03:08 PM
|
|
|
|
|
|
1
|
2
|
3
|
4
|
|
5
|
6
|
7
|
8
|
9
|
10
|
11
|
|
12
|
13
|
14
|
15
|
16
|
17
|
18
|
|
19
|
20
|
21
|
22
|
23
|
24
|
25
|
|
26
|
27
|
28
|
29
|
|
|
|
|
|