forked from len0rd/rockbox
Second part of FS#8272 - include charger status in Sansa debug menu.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16513 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
fdb5a4b0c2
commit
0449c0ef5d
2 changed files with 7 additions and 2 deletions
|
|
@ -97,6 +97,9 @@
|
|||
#include "debug-target.h"
|
||||
#endif
|
||||
|
||||
#include "i2c-pp.h"
|
||||
#include "as3514.h"
|
||||
|
||||
/*---------------------------------------------------*/
|
||||
/* SPECIAL DEBUG STUFF */
|
||||
/*---------------------------------------------------*/
|
||||
|
|
@ -1180,7 +1183,6 @@ bool dbg_ports(void)
|
|||
adc_read(ADC_REMOTE), adc_read(ADC_SCROLLPAD));
|
||||
lcd_puts(0, line++, buf);
|
||||
#elif defined(SANSA_E200)
|
||||
line++;
|
||||
snprintf(buf, sizeof(buf), "ADC_BVDD: %4d", adc_read(ADC_BVDD));
|
||||
lcd_puts(0, line++, buf);
|
||||
snprintf(buf, sizeof(buf), "ADC_RTCSUP: %4d", adc_read(ADC_RTCSUP));
|
||||
|
|
@ -1207,6 +1209,8 @@ bool dbg_ports(void)
|
|||
lcd_puts(0, line++, buf);
|
||||
snprintf(buf, sizeof(buf), "ADC_VBAT: %4d", adc_read(ADC_VBAT));
|
||||
lcd_puts(0, line++, buf);
|
||||
snprintf(buf, sizeof(buf), "CHARGER: %02X/%02X", i2c_readbyte(AS3514_I2C_ADDR, CHRGR), i2c_readbyte(AS3514_I2C_ADDR, IRQ_ENRD0));
|
||||
lcd_puts(0, line++, buf);
|
||||
#endif
|
||||
lcd_update();
|
||||
if (button_get_w_tmo(HZ/10) == (DEBUG_CANCEL|BUTTON_REL))
|
||||
|
|
|
|||
|
|
@ -53,6 +53,7 @@ extern void audiohw_set_sample_rate(int sampling_control);
|
|||
#define PLLMODE 0x1d
|
||||
|
||||
#define SYSTEM 0x20
|
||||
#define CHRGR 0x22
|
||||
#define DCDC15 0x23
|
||||
#define SUPERVISOR 0x24
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue