Spanish Italian
8410 Users    

SUCKERmenu

3.8 Configuring a particular dsPIC (R) DSC microcontroller

Microchip produces various versions of the Microchip microcontrollers, each one with different peripherals and memory sizes. To support the heterogeneity of these devices, Microchip offers, through the C30 Compiler toolchain, a set of files which can be used to configure the compiling process.
In particular, for each device, there are four files:
• A linker script, available under the directory Support/gld of the Microchip ASM30 Assembler, which contains the linking information such as the memory sizes, and the available interrupt handlers;
• An Assembler include file, available under the directory Support/inc of the Microchip ASM30 Assembler, which contains the declaration of the device’s register addresses to be used inside assembler programs;
• A C include file, available under the directory support/h of the Microchip C30 Compiler, which contains the declaration of the device’s addresses to be used inside C programs;
• A library, available under the directory lib of the Microchip C30 compiler, which contains a set of libraries for the usage of the microcontroller peripherals. Every Erika Enterprise application which has to be compiled together with the Microchip C30 compiler needs the specification of these four files. To set which files have to be used for the particular device, the user can specify the following lines inside the
OIL file. If the device number is known, and the files to be used are the default files provided by Microchip, then the developer can directly specify the device name in the OIL file, as in the following example:
...
MCU_DATA = PIC30 {
MODEL = PIC33FJ256GP710;
};
...
Currently, Erika Enterprise supports the following values for the MODEL attribute:
• PIC24 devices:
PIC24FJ128GA006, PIC24FJ128GA008,
PIC24FJ128GA010, PIC24FJ32GA002,
PIC24FJ32GA004, PIC24FJ64GA002,
PIC24FJ64GA004, PIC24FJ64GA006,
PIC24FJ64GA008, PIC24FJ64GA010,
PIC24FJ96GA006, PIC24FJ96GA008,
PIC24FJ96GA010, PIC24HJ128GP206,
PIC24HJ128GP210, PIC24HJ128GP306,
PIC24HJ128GP310, PIC24HJ128GP506,
PIC24HJ128GP510, PIC24HJ256GP206,
PIC24HJ256GP210, PIC24HJ256GP610,
PIC24HJ64GP206, PIC24HJ64GP210,
PIC24HJ64GP506, PIC24HJ64GP510.
• PIC30 devices:
PIC30F1010, PIC30F2010,
PIC30F2011, PIC30F2012,
PIC30F2020, PIC30F2021,
PIC30F2022, PIC30F2023,
PIC30F3010, PIC30F3011,
PIC30F3012, PIC30F3013,
PIC30F3014, PIC30F4011,
PIC30F4012, PIC30F4013,
PIC30F5011, PIC30F5013,
PIC30F5015, PIC30F5016,
PIC30F6010, PIC30F6010A,
PIC30F6011, PIC30F6011A,
PIC30F6012, PIC30F6012A,
PIC30F6013, PIC30F6013A,
PIC30F6014, PIC30F6014A,
PIC30F6015.
• PIC33 devices:
PIC33FJ128GP206, PIC33FJ128GP306,
PIC33FJ128GP310, PIC33FJ128GP706,
PIC33FJ128GP708, PIC33FJ128GP710,
PIC33FJ128MC506, PIC33FJ128MC510,
PIC33FJ128MC706, PIC33FJ128MC708,
PIC33FJ128MC710, PIC33FJ256GP506,
PIC33FJ256GP510, PIC33FJ256GP710,
PIC33FJ256MC510, PIC33FJ256MC710,
PIC33FJ64GP206, PIC33FJ64GP306,
PIC33FJ64GP310, PIC33FJ64GP706,
PIC33FJ64GP708, PIC33FJ64GP710,
PIC33FJ64MC506, PIC33FJ64MC508,
PIC33FJ64MC510, PIC33FJ64MC706,
PIC33FJ64MC710.
Please note that we did not have the possibility to directly test all the possible devices produced by Microchip. In general this is not a problem, because the various devices are directly mapped to appropriate compiler flags. The following is the list of devices we tested directly: PIC30F2010, PIC30F6014A, PIC33FJ256GP710, PIC24FJ128GA010, which basically are the devices mounted on the Microchip Evaluation boards supported by Erika Enterprise.
If the device is not supported by the particular version of RT-Druid or if the developer needs to use a custom file, then the four files can be specified separately as in the following example:
...
MCU_DATA = PIC30 {
MODEL = CUSTOM {
LINKERSCRIPT = " p33FJ256GP710. gld ";
DEV_LIB = " libp33FJ256GP710 - elf.a";
INCLUDE_C = " p33FJ256GP710.h";
INCLUDE_S = " p33FJ256GP710.inc ";
};
};
...
As a result of this specification, the correct include files, libraries and linker scripts will be used when compiling an Erika Enterprise application.

Who's new

  • sachingehlot
  • mike1
  • sowdhaminij
  • HiroProtagonist
  • franchesko

Who's online

There are currently 3 users and 143 guests online.

Online users

  • vivek_lalpuri
  • sachingehlot
  • koule