This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

UDP buffer allocation fails

Hello,

I'm trying to send UDP-packets from an LM3S9B96 to the PC. But every time when I call the Library-function "udp_get_buf(len);" I get an Hardfault-IRQ.
Receiving the UDP-Packets from the PC is no problem, so my initialization from the UDP should be ok.
Any ideas what could be wrong?

Thank you.

Regards,
Mike

Parents
  • Hi Mike,

    the remedy could be to run RTX in privilege mode or to modify int_enable_eth() and int_disable_eth() so that when they manipulate the NVIC they temporarily run in privileged mode.

    I also had problems running TCPnet together with RTX on a Cortex M3. That was strange because I had always used that on ARM7s. Finally, I saw the very same crash as yours on int_disable_eth(), looked at the code inside and it flashed a light: the NVIC and the privileged mode!

    I cannot say if your program has other problems, but on a project of mine which successfully uses TCPnet and RTX in protected mode on a CM3, if I turn protected mode off the program crashes.

    Regards, Marco.

Reply
  • Hi Mike,

    the remedy could be to run RTX in privilege mode or to modify int_enable_eth() and int_disable_eth() so that when they manipulate the NVIC they temporarily run in privileged mode.

    I also had problems running TCPnet together with RTX on a Cortex M3. That was strange because I had always used that on ARM7s. Finally, I saw the very same crash as yours on int_disable_eth(), looked at the code inside and it flashed a light: the NVIC and the privileged mode!

    I cannot say if your program has other problems, but on a project of mine which successfully uses TCPnet and RTX in protected mode on a CM3, if I turn protected mode off the program crashes.

    Regards, Marco.

Children