comparison src/i2c.asm @ 498:e8351dd7bb90

compass1 full scale gain test
author heinrichsweikamp
date Wed, 19 Apr 2017 12:54:00 +0200
parents 6ca155fc1509
children dd28d4efd4d2
comparison
equal deleted inserted replaced
497:3710c8abb81b 498:e8351dd7bb90
494 movlw b'00000000' ; CTRL4 494 movlw b'00000000' ; CTRL4
495 rcall I2C_TX 495 rcall I2C_TX
496 movlw b'01100100' ; CTRL5 HIGH res, 6,25Hz 496 movlw b'01100100' ; CTRL5 HIGH res, 6,25Hz
497 rcall I2C_TX 497 rcall I2C_TX
498 init_compass1_common: 498 init_compass1_common:
499 ;movlw b'01100000' ; CTRL6 Full scale (+/-12 Gauss -> 2730LSB/Gauss) 499 movlw b'01100000' ; CTRL6 Full scale (+/-12 Gauss -> 2730LSB/Gauss)
500 ;movlw b'00000000' ; CTRL6 (+/-2 Gauss) 500 ;movlw b'00000000' ; CTRL6 (+/-2 Gauss)
501 movlw b'00100000' ; CTRL6 (+/-4 Gauss) 501 ;movlw b'00100000' ; CTRL6 (+/-4 Gauss)
502 rcall I2C_TX 502 rcall I2C_TX
503 movlw b'00000000' ; CTRL7 Continuous Mode 503 movlw b'00000000' ; CTRL7 Continuous Mode
504 rcall I2C_TX 504 rcall I2C_TX
505 bsf SSP1CON2,PEN ; Stop condition 505 bsf SSP1CON2,PEN ; Stop condition
506 rcall WaitMSSP 506 rcall WaitMSSP