• 990.012 Programming Example : UART1 remapping and usage

    In the attachments you'll find an example on how to use UART1 peripheral on dsPIC33FJ128GP802 mounted on 990.012 MuIN dsPic. This code also show you how to remap the peripherals.

    Source code is made of 5 files:

    main.c - the main program, simply puts an "Hello World!" string on UART1 connector.
    In order to see the message, you must connect UART1 on your pc using an adapter such as the 990.004 USB to serial micro converter, and then run a terminal program (hyperterminal) by setting it to 57600,8,n,1.

    uart_init.c - setups the UART1 function mode for use with 57600bps, 8 bit data, no parity, 1 stop bit.

    gen_init.c - remaps th UART1 peripheral on pins used by 990.012. Please remember that UARTs have no default pin assigned to them, then you must remap it for using the pins you want (RB5 and RB6 in the case of 990.012). In this code there are some useful remarks will help you to understand this feature.

    common.h - contains some other setups

    osc_init.c - setups the oscillator

    Download: MuIn dsPIC UART HelloWorld.zip