I have some code running on the ARM side of an OMAPL138 (No OS). If I let the code run, I will see it doing a printf without any issues. However when I try to set any peripherals or even turn them on using the PSC interface then the code will hang indefinitely.
I have read some of the documentation and my initial thought is that this is because I am in User Mode while running through main. CPSR M[4:0] = 10000 which confirms that I am in User mode. The documentation says that when you enter a Software Interrupt that you enter Supervisor Mode. Is there another way for me to enter Supervisor Mode?
If there is not another way, how can I modify the register settings of peripherals such as the UART without entering a Software Interrupt?
Here are examples of lines of code that can make it hang:
Psc_ModuleClkCtrl((Psc_DevId)CSL_LPSC_INST_UART_2,
(Uint32)CSL_LPSC_NUMBER_UART_2,TRUE);
HostUsartBase->PWREMU_MGMT = CSL_UART_PWREMU_MGMT_FREE_STOP; (HostUsartBase points to CSL_UART_2_REGS)