【正文】
V DSP實驗箱l 熟悉GPIO模塊的功能原理l 會利用SPRC097中的工程環(huán)境建立或打開工程l 實現(xiàn)GPIO模塊的驅(qū)動編程4. 實驗內(nèi)容(1) 安裝硬件驅(qū)動到C:\ti。sdefine EXAMPLE2 0 // Use SET/CLEAR registers to toggle I/O39。s// Prototype statements for functions found within this file.void delay_loop(void)。void Gpio_example1(void)。void Gpio_example3(void)。 // Step 2. Initalize GPIO: // This example function is found in the file and// illustrates how to set the GPIO to it39。 // Skipped for this example // For this example use the following configuration: Gpio_select()。// Initialize PIE control registers to their default state.// The default state is all PIE interrupts disabled and flags// are cleared. // This function is found in the file. InitPieCtrl()。 IFR = 0x0000。 // Step 4. Initialize all the Device Peripherals:// This function is found in // InitPeripherals()。s Gpio_example1()。s Gpio_example1()。s Gpio_example3()。 for (i = 0。 i++) {}}void Gpio_example1(void){ // Example 1: // Toggle I/Os using DATA registers // Note: When using the DATA reigsters, input values // may be lost. If there are inputs on the port then // use the CLEAR/SET/TOGGLE registers instead. while(1) { =0xAAAA。 =0x0022。 =0xAAAA。 delay_loop()。 =0x5555。 // Four I/Os only =0x0005。 =0x0010。 }}void Gpio_example2(void){ // Example 2: // Toggle I/Os using SET/CLEAR registers while(1) { =0xAAAA。 =0xAAAA。 =0x0022。 // Four I/Os only =0x0002。 // ThreeI/Os only =0xAAAA。 =0x0020。 // Two I/Os only delay_loop()。 =0x5555。 =0x5555。 =0x0041。 =0x0005。 =0x5555。 =0x0010。 }}void Gpio_example3(vo