I have the UART2 setup in loopback mode and trying to test out a GIO driver for the UART on an expOMAP-L138 card.
I ported the PSPBIOS driver to work on the ARM and I am seeing some unexpected behavior. I suspect part of the strangeness might be coming from the emulator and reading some other threads on UART issues it looks like that might be part of the problem.
So in the submit function I see the UART RX interrupts being enabled on the first call to the issue for the RX side. The HWI then runs but the IIR NO Pending bit is set so the routine does nothing.
The next operation is the issue to the TX side and the origonal code for the submit function basically setup the active packet and then enabled the UART TX interrupt. It looks like the code was expecting the ISR to go off right away indicating that the TX is empty. I don't get that.
So I modified the submit so that after enabeling the UART TX interrupt I called the TX swi function so that the first character would get loaded. Now the HWI code gets called but again the IIR NO Pending bit is set.
I understand that if a memory window is open and the IIR is being read by the emulator it could be cleared. Very bad. My question has to do with if the register window is open but the UART2 is minimized, does that count? I also have a variable that points to the UART registers so I could see that if that is open it could cause the same issue. But what if it is minimized? Will that cause the issue also?
I am putting a break point on the while instruction inside the HWI. The IIR gets read just before and saved off in a status register and that status register is what I am using to see what the IIR is and seeing the NO PEND bit being set.
Thanks in advance for your help...