You can use the macro's
@ INT_ENABLE RX_INT
@ INT_DISABLE RX_INT
or
set / clear the pie1.rcif bit yourself (usually pie1.5) but check your data sheet
You can use the macro's
@ INT_ENABLE RX_INT
@ INT_DISABLE RX_INT
or
set / clear the pie1.rcif bit yourself (usually pie1.5) but check your data sheet
Thank you Richard for the prompt answer. Just what I was looking for!
Cheers
Al.
All progress began with an idea
I have a chunk of time critical bit banging code for driving WS2811 LEDs so I cant allow it to be interupted.You can use the macro's
@ INT_ENABLE TMR1_INT
@ INT_DISABLE TMR1_INT
If I do the following.....
Would TMR1 be able to flag an interrupt that would then be picked up when I re-enabled the DT Interrupt or would I miss that event completely ?Code:@ INT_DISABLE TMR1_INT {whole chunk of time critical code} @ INT_ENABLE TMR1_INT
Thanks in advance.
Keith
Keith
www.diyha.co.uk
www.kat5.tv
In general yes, but that depends on the version of DT-INTS you're using. Some of the ones I've seen clear the IF bit in INT_ENABLE, others don't.
Might be easier to just set/clear the TMR1IE bit yourself (It's normally bit 0 of PIE1). If the TMR1IF bit is set when you set TMR1IE it'll generate an interrupt.
Keith, I did the exact same thing when I wrote code some years ago for the WS2811 LEDs. That is the reason I switched to using the APA102C led's as they are SPI based and there is no need to disable the interrupts. In fact I just finished a table lamp for my daughter using 204, APA102C's and 29, 5.25 inch hard disk platters.
Dave Purola,
N8NTA
EN82fn
Thanks Tumbleweed, will do some experimenting when I get home.
Love the lamp Dave. Looks really cool.
I am using WS2801, WS2811, APA102 and some PL9823 LEDs in a project. Will post pictures once its complete.
Keith
www.diyha.co.uk
www.kat5.tv
Bookmarks