| поискавой системы для электроныых деталей |
|
MPXM2102AS датащи(PDF) 441 Page - Motorola, Inc |
|
|
|||||||||||||||||||||||||||||
MPXM2102AS датащи(HTML) 441 Page - Motorola, Inc |
|
441 / 670 page ![]() AN1326 3–295 Motorola Sensor Device Data www.motorola.com/semiconductors WTCONV BRCLR ADCTL,X #$80 WTCONV * Wait for completion of conversion flag LDAB ADR2,X * Loads conversion result into Accumulator CLRA STD SENSOUT * Stores conversion as SENSOUT RTS * Subroutine IN_HG * Purpose is to convert the measured pressure SENSOUT, into * units of in–Hg, represented by a hex value of 305–150 * This represents the range 30.5 – 15.0 in–Hg IN_HG LDD POFFSET * Loads maximum offset for subtraction SUBD SENSOUT * RESULT = POFFSET–SENSOUT in hex format STD RESULT * Stores hex result for P, in Hg CMPD #305 BHI TOHIGH CMPD #150 BLO TOLOW LDAB #$80 STAB FLAG BRA END_CONV TOHIGH LDAB #$FF STAB FLAG BRA END_CONV TOLOW LDAB #$00 STAB FLAG END_CONV RTS * Subroutine ERROR * This subroutine sets the display digits to output * an error message having detected an out of range * measurement in the main program from FLAG ERROR LDAB #$00 * Initialize digits 1,4 to blanks STAB DIGIT1 STAB DIGIT4 LDAB FLAG * FLAG is used to determine CMPB #$00 * if above or below range. BNE SET_HI * If above range GOTO SET_HI LDAB #$0E * ELSE display LO on display STAB DIGIT2 * Set DIGIT2=L,DIGIT3=O LDAB #$7E STAB DIGIT3 BRA END_ERR * GOTO exit of subroutine SET_HI LDAB #$37 * Set DIGIT2=H,DIGIT3=1 STAB DIGIT2 LDAB #$30 STAB DIGIT3 END_ERR RTS * Subroutine BCDCONV * Purpose is to convert ALTITUDE from hex to BCD * uses standard HEX–BCD conversion scheme * Divide HEX/10 store Remainder, swap Q & R, repeat * process until remainder = 0. BCDCONV LDAA #$00 * Default Digits 2,3,4 to 0 STAA DIGIT2 STAA DIGIT3 STAA DIGIT4 LDY #DIGIT4 * Conversion starts with lowest digit LDD RESULT * Load voltage to be converted CONVLP LDX #$A * Divide hex digit by 10 IDIV * Quotient in X, Remainder in D STAB 0,Y * stores 8 LSB’s of remainder as BCD digit DEY CPX #$0 * Determines if last digit stored XGDX * Exchanges remainder & quotient BNE CONVLP LDX #REGBASE * Reloads BASE into main program RTS * Subroutine LOOKUP Freescale Semiconductor, Inc. For More Information On This Product, Go to: www.freescale.com |
|
ссылки URL |
| Вашему бизинису помогли Аллдатащит? [ DONATE ] |
Что такое Аллдатащит | реклама | контакт | Конфиденциальность | Ссылка на техническое описание | обмен ссыками | поиск по производителю All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |