How to read and print data from UART using Debuglink with AX8052F143?

Hello There!

I’m currently trying to program a AX8052F143 with a GPS module. I need to use the UART0 but I can’t read and print what the GPS module is outputting.

I have tried to use ch = UART0_RX() with an interrupt but it never triggers the interrupt

I define my UART0 like this:

void initUART()
    DIRA |= (1 << 0);   // make Pa0 output
    DIRC |= (1 << 2);   // make PC2 output
    DIRC &= 0xF7;       // make PC3 input
    PALTC |= (1 << 2);  // enable U0TX on PC2
    PINSEL |= (1 << 0); // enable U0RX on PC3

    EIE |= (1 << 4);    // enable uart0 interrupt
    uart_timer1_baud(CLKSRC_LPXOSC, 9600, 32768000);
    uart0_init(1, 8, 1);    // timer0, 8 bits, 1 stop bit

    //dbglink_writestr("Test at main");

and then define the interrupt like this:

__reentrantb void uart0_irq(void) __interrupt(INT_UART0)
    static char ch;
    ch = uart0_rx();    // read char from fifo
    dbglink_writestr(ch);//and this is empty


I can see a train of square signals coming from the GPS and they make it to the input of the UART discarding the possibility of poor connection

Can anyone help?

Thank you very much


Hi Guillermo, thanks for using our Community Forum.
I cannot quickly tell where is the issue in your code above but have you inspected how our AX8052 drivers (a.k.a. LibMF) look like?
You can find source code in C:\Program Files (x86)\ON Semiconductor\AXSDB\libmf\source and in particular the low level code in the file dbglink.c where you can see how the interrupt is enabled by setting DBGLNKSTAT.

You can also see an actual implementation of the uart/dbglink rx in one of these AX8052 based Sigfox examples downloadable at Sigfox Software Library (

Hi Georgi,

THank you very much for your response. Yes i have checked the code.

However it seems that the UART0 interrupt is not being triggered when it receives data from the GPS module. Does the DEMO code that comes with AX radio lab disable the interrupts?

Is there any code that I could use?


Hi there! I think this post has the solution. Could you check what their solution was?