AppZone uart callback issue

8 thoughts on “AppZone uart callback issue

  1. Hi,

    I write software for UE910 ver.12.00.417, SDK 12.00.007 (BETA 009). I wrote functions for config uart and set “receive callback” like in example below. The message “DeadLoop” is printing every second, but if I try to send a couple of bytes to uart the module goes to restart and message “Callback called” is not printed. I tried to add some code before uart_init(115200) and sometimes it work(callback is called), but if I add more code before calling uart initialization – module is restarting again when I send bytes. Also I tried to make hw_uart_read_cb as static function, add asm(“.aligned 4”) before uart_init(115200) but without success.

    I’m not sure, but it seems to be like a pointer with unaligned adress or adress relocation problem.

    Please help me to solve this problem!

    Best regards,

    Radu DONOS.


    INT32 hw_uart_read_cb(M2M_T_HW_UART_HANDLE handle, CHAR *buffer, INT32 len)
    m2m_os_trace_out("Callback calledrn");

    void uart_init(UINT32 baudrate)
    M2M_T_HW_UART_IO_HW_OPTIONS uart_settings = {
    .baudrate = baudrate,
    .databits = 8,
    .stop_bits = 1,
    .parity = 0,
    .flow_ctrl = 0

    global_uart = m2m_hw_uart_open();

    m2m_hw_uart_ioctl (global_uart, M2M_HW_UART_IO_HW_OPTIONS_SET, (INT32) &uart_settings);
    m2m_hw_uart_ioctl(global_uart, M2M_HW_UART_IO_BLOCKING_SET, (INT32)M2M_HW_UART_IO_BLOCKING_RELEASE);

    m2m_hw_uart_ioctl (global_uart, M2M_HW_UART_IO_RCV_FUNC, (INT32) &hw_uart_read_cb);

    INT32 M2M_msgProc1(INT32 type, INT32 param1, INT32 param2)
    uart_printf("* Starting build from: %s %srn", __DATE__, __TIME__);


    for(;;) {

    return 0;
    1. Hello,

      You are using a stable firmware release (12.00.417) with Beta SDK release. Where did you find the SDK beta? SDK should be aligned with module firmware version, because there could be differencese in libraries between the two versions.

      Also, could you confirm the firmware version? You can do it with



      Fabio Pintus

      1. Hello Fabio,

        We receive beta SDK from local representative. About version of software the command AT+CGMR respond:




        Maybe I can do some test that will help with searching the problem?


        1. Hello,

          I was able to reproduce the problem, the Software Team has been notified of it. I will update you as soon as I have news.



          1. Thank you. Looking forward for your update, as project timing is very tight.

            Best regards,


          2. Hello Donos,

            The Sw Team is still analyzing the root of the issue. As a workaround, it seems that configuring the UART into the main will work. At the following link you can find a test project I used with success

            It sets the uart and if everything is ok, calls task 1 which loops on the trace prints. the callback will echo the data received.

            Hope it helps.

            Best Regards


          3. Hello Donos,

            Sorry for the late update.

            You can find the B15 firmware and aligned SDK (fixing the issue you were experiencing on UART callback) at the following links:



            We still are working to fix the issue, I will share a good firmware as soon as I can.

            [edited, firmware version was not good, my bad]

            Best Regards

            Fabio Pintus