Hi,
I'm currently working on one of my projects on the TMS320C6713 DSK on Code Composer Studio v3.3 and I want to make some of the functions functionnal by using the DSP/BIOS configuration files. Until now, I made the interrupts with the configuration file and I want to do the same with the the general purpose Input/output and a timer. I am currently using registers to set them:
intTemp = *(unsigned int *)GPEN;
intTemp = intTemp|0x07B;
*(unsigned int*)GPEN = intTemp; //Active le GPIO 3(la pin 15 sur le connecteur HPI) (activating GPIO)
intTemp = *(unsigned int *)GPDIR;
intTemp = intTemp & 0xFFFFFFFF;
intTemp = intTemp | 0x0000000B; //Sélectionne la pin 3 comme sortie (choosing input/output settings)
*(unsigned int*)GPDIR = intTemp;
*(unsigned int *) PRD1 = 3516; // On configure le timer1 à 8 KHz (8KHz timer)
*(unsigned int *) CTL1 = 0x3C7; // Configure le timer1 en osc interne (Sortira sur la pin 49 du connecteur EPI) (Timer output)
(Just a part of the code)
I would like to know if it is possible to select the general purpose input/output and code a timer with its output. And if its possible, does it makes my code cleaner? And if someone has already done it, could he show me how he did it?
I am reading through the DSP/BIOS user guide, but I dont see any good example to back me up on this.
Thank you for your time,
Vincent