Darrel,
How about this one? I have one interrupt to generate a USB Service, that part works fine. I'd like to add another interrupt for USB reception, is that what USB_INT is for?
Here is a snip of code:
Does that make sense? Or can I leave the USB Service interrupt enabled throughout the USB Reception interrupt?Code:;----[High Priority Interrupts]----------------------------------------------- ASM INT_LIST macro ; IntSource, Label, Type, ResetFlag? INT_Handler TMR1_INT, _ServiceUSB, PBP, yes INT_Handler USB_INT, _ReceiveUSB, PBP, yes endm INT_CREATE ; Creates the High priority interrupt processor ENDASM '---[USB - interrupt handler]------------------------------------------------ ReceiveUSB: @ INT_DISABLE TMR1_INT ; disable USB service interrupt USBBufferCount = USBBufferSizeRX DoUSBIn: USBservice ; Generate USB Service manually USBIn 1, USBBuffer, USBBufferCount, DoUSBIn varUsbIn = conByteHigh ' Set flag data has arrived @ INT_ENABLE TMR1_INT ; enable USB Service interrupts @ INT_RETURN '---[TMR1 - interrupt handler]-------------------------------------------------- ServiceUSB: USBservice @ INT_RETURN
Robert
![]()




Bookmarks