Tell us about yourself!

  • Ultrasonic Sensor with MSP430 and IAR/CCS

    I don't understand what this interrupt do, can you explain to me ? sorry, for my bad english.#pragma vector=PORT1_VECTOR__interrupt void Port_1(void){if(P1IFG&0x04) //is there interrupt pending? { if(!(P1IES&0x04)) // is this the rising edge? { TACTL|=TACLR; // clears timer A miliseconds = 0; P1IES |= 0x04; //falling edge } else { sensor = (long)miliseconds*1000 + (long)TAR;//calculating ECHO lenght }P1IFG &= ~0x04;//clear flag}}

    View Instructable »