Mercurial > public > hwos_code
comparison src/adc_lightsensor.asm @ 343:34e2f5bdc5a2
BUGFIX: Rotate button sensitivity with screen (OSTC 2 and cR)
TODO: Fix entry time when dive was during midnight
author | heinrichsweikamp |
---|---|
date | Mon, 20 Jul 2015 12:43:42 +0200 |
parents | 653a3ab08062 |
children | 043890f06bce |
comparison
equal
deleted
inserted
replaced
342:7812ec7ef694 | 343:34e2f5bdc5a2 |
---|---|
437 return | 437 return |
438 | 438 |
439 global piezo_config ; Sets up piezo sensitivity of heinrichs weikamp Piezo buttons (~30ms) | 439 global piezo_config ; Sets up piezo sensitivity of heinrichs weikamp Piezo buttons (~30ms) |
440 piezo_config: ; Settings between 20 and 200 | 440 piezo_config: ; Settings between 20 and 200 |
441 movff opt_cR_button_right,WREG; right button | 441 movff opt_cR_button_right,WREG; right button |
442 btfsc flip_screen ; 180° rotation ? | |
443 movff opt_cR_button_left,WREG ; Yes, left button | |
442 rcall piezo_config_tx | 444 rcall piezo_config_tx |
445 | |
443 movff opt_cR_button_left,WREG ; left button | 446 movff opt_cR_button_left,WREG ; left button |
447 btfsc flip_screen ; 180° rotation ? | |
448 movff opt_cR_button_right,WREG; Yes, right button | |
444 rcall piezo_config_tx | 449 rcall piezo_config_tx |
450 | |
445 movlw .200 ; reserved | 451 movlw .200 ; reserved |
446 rcall piezo_config_tx | 452 rcall piezo_config_tx |
447 movlw .200 ; reserved | 453 movlw .200 ; reserved |
448 rcall piezo_config_tx | 454 rcall piezo_config_tx |
449 return | 455 return |