This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

wwatch signal error

I am trying to create a signal that will raise an input pin, hold it high for a certain amount of time and then lower it, whenever the CPU writes to a certain SFR. Here is my signal:

signal void p_delay(void){
        while(1){
                wwatch(OUTREG);
                PORT1I |= 0x02;
                swatch(0.00009);
                PORT1I &= ~0x02;
        }
}

In the target program, I poll the input pin and write to the SFR only if it is low, like so:

if(P1 & 0x02 == 0)
    OUTREG = buff[i];

Before running the simulation, I start the signal p_delay(), along with several other signals simulating interrupts.

However, when my target program actually writes to OUTREG, I get a bunch of

p_delay()
error 99: signal() already active

errors. OUTREG is setup in the ISD51.a51 file correctly, so I know that is not the problem. Any ideas on what is going on here?

Parents Reply Children
No data