Home AMX User Forum NetLinx Studio

Looping Channel Pulses

I have an odd problem with a large (for me) AMX project. I've got about 40 displays being controlled via IR. I have shutdown and startup functions which loop through an array of structs and pulse the discreet on or off channel for each display. This will work fine for a month or so. Then the client will report that random displays will stop reacting to the global on and off macros. They can still turn the displays on or off using dedicated power on and off buttons I've included for every TV (via a button push on their 8400s). That's the strange part. I don't know why the button pushes work and the macro doesn't. Both are simply pulsing the appropriate dev's channel. Also the degenerative nature of the issue is confusing.

Powering down the Netlinx will fix the problem for another month or so.

The system consists of an NI-3100 with two frames stuffed with IR and a few serial cards. The expansion frames are connected via ICSP.

Any ideas?

Comments

  • a_riot42a_riot42 Posts: 1,624
    Kind of hard to guess with no code to look at. My telepathy skills are't what they used to be :(
    Paul
  • DHawthorneDHawthorne Posts: 4,584
    Don't use the PULSE keyword for IR. Use the send_command 'SP'. I've run into all sorts of cases where PULSE acted oddly, and I can only assume it's because it uses a global timer, whereas SP uses the CTON and CTOF settings in the actual port; besides, it buffers the IR and queues it as well.
  • rynandorynando Posts: 68
    a_riot42 wrote: »
    Kind of hard to guess with no code to look at. My telepathy skills are't what they used to be :(
    Paul

    Sorry to hear about your declining telepathy skills. :)

    Here's the loop in the shutdown function:

    [PHP]
    for(i = 1; i <= 33; i++)
    {
    pulse[SanyoDisplays,2];
    }
    [/PHP]

    The button pushes are the same type of thing but they only effect one of the devs in the array and are of course in a button event.

    Ryan
  • rynandorynando Posts: 68
    DHawthorne wrote: »
    Don't use the PULSE keyword for IR. Use the send_command 'SP'. I've run into all sorts of cases where PULSE acted oddly, and I can only assume it's because it uses a global timer, whereas SP uses the CTON and CTOF settings in the actual port; besides, it buffers the IR and queues it as well.

    Thanks. I will give that a shot.
  • the8thstthe8thst Posts: 470
    rynando wrote: »
    Sorry to hear about your declining telepathy skills. :)

    Here's the loop in the shutdown function:

    [PHP]
    for(i = 1; i <= 33; i++)
    {
    pulse[SanyoDisplays,2];
    }
    [/PHP]

    The button pushes are the same type of thing but they only effect one of the devs in the array and are of course in a button event.

    Ryan

    You don't even need a loop to accomplish what you are trying to do.

    [php]pulse[SanyoDisplays,2][/php]

    That will pulse all of the displays at once.

    My preferred way to do it is:
    [php]send_command SanyoDisplays,"'SP',2"[/php]

    This still send the IR command to all displays at once, but has all of the benefits over pulse that have been mentioned earlier in this thread.
  • jjamesjjames Posts: 2,908
    +1 to the above (or below) post.
  • viningvining Posts: 4,368
    jjames wrote: »
    +1 to the above post.
    Am I the only one who lists the newest posts on top? Every time I see this "xx the above post" I get confused cuz I only have posts below. I am a little slow afterall. :)
  • ericmedleyericmedley Posts: 4,177
    mine list newest on bottom. But, to be honest, I never really gave it much thought and just run the thing default out-of-the-box.
  • jjamesjjames Posts: 2,908
    I always knew you were a little backwards! :) (j/k!)

    I changed my post to accommodate your settings.
  • viningvining Posts: 4,368
    jjames wrote: »
    I always knew you were a little backwards! :) (j/k!)
    My mom always told me I was "special" and that's why I got to ride the short bus to school. :)
  • JubalJubal Posts: 77
    DHawthorne wrote: »
    Don't use the PULSE keyword for IR. Use the send_command 'SP'. I've run into all sorts of cases where PULSE acted oddly, and I can only assume it's because it uses a global timer, whereas SP uses the CTON and CTOF settings in the actual port; besides, it buffers the IR and queues it as well.

    how about when you want to minimize tje pulse or time the ir pulse?

    as what i've experience, strangly this IR pulse 4 times in 1 press. when i press down it goes 4 times down, when up it goes 4 times up. thats why i need to set pulse time to minimal to resolve this issue, any advice on this issue?
  • the8thstthe8thst Posts: 470
    Jubal wrote: »
    how about when you want to minimize tje pulse or time the ir pulse?

    as what i've experience, strangly this IR pulse 4 times in 1 press. when i press down it goes 4 times down, when up it goes 4 times up. thats why i need to set pulse time to minimal to resolve this issue, any advice on this issue?

    CTON and CTOF are the commands to setup the ON and OFF times for the SP command on the IR ports.

    Check out AMX-PI.

    One of the reasons SP is preferred over PULSE is that CTON/CTOF are port specific where as SET_PULSE_TIME() is a global time that effects ALL pulses within the system.
Sign In or Register to comment.