Olin, Wouter, I understand why xoring directly to the port may cause errors and how using the latch corrects this. Thanks! On my scope: Without ultrasound transmitter attached, I see a clear, sharp edged 10Vtt block. With transmitter attached, I have to increase the scope's sensitivity to 15mV/div to see something happening at a 80kHz rate. I assume this is the toggling of the outputs every halfperiod (1 use 40kHz ultrasound). I have not been able to locate any datasheet on the transmitter (MA40A5S). I think it's a Murata part. Looking at the other transmitters at the Murata-site I expect the capacity of the transmitter to be something between 2000 and 2500 pF. I guess one could call this hiiighly capacitive load! I have tried to attach the transmitter between Vdd and one of the us-pins. No luck. This is strange because using the PWM on a 16F877A produced a solid signal when the same transmitter is connected between Vdd and PWM-out... Next test will be to use the PWM of the 18F452. It should behave like the PWM on the 877A, right? If it does not then, I guess, one might conclude that the 877A pins tolerate loads with a higher capacitance than the 452. I'll be back! Marcel -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu