Turns out that a few months ago, Microchip posted app notes for
* DMX512 transmission
* DMX512 reception
* Software-based 3 color PWM generation
Granted, it's all written in assembly. And it may not be quite as user-friendly to PBP newbies as DT's Instant Interrupts / SSPWM (very nice, BTW!).
But they can gather all 512 channels of dimmer data in 27 lines of .asm code. Pretty neat!
It's elegantly written, very compact and fairly easy to follow. Their write-up on DMX gives a nice overview of the various stages of the signal and what the processor needs to do during each.
Their trick for generating the break signal on the transmit side is nice, too.
Their DMX receive code is *not* interrupt based, but the PWM routine is.
Check out notes #1074 and #1076
Link:
http://www.microchip.com/stellent/id...GE&nodeId=2048
Best,
JEC
Bookmarks