Thank you to anyone who has already donated - your generous donations helped make three months of treatment possible.
My brother Nate continues to fight stage IV Hodgkin's lymphoma. He's just 31, with a wife and baby girl. They have no active income (since he's been unable to return to work), no insurance, and cannot afford the treatment he needs. Nate and his family need your help. Please consider a donation, every dollar helps. Thanks.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 |
diff --git a/firmware/drivers/audio/as3514.c b/firmware/drivers/audio/as3514.c index b7c99f4..7d4c892 100644 /* AMS Sansas based on the AS3525 use the LINE2 input for the analog radio signal instead of LINE1 */ -#if CONFIG_CPU == AS3525 +#if CONFIG_CPU == AS3525 /*|| CONFIG_CPU == AS3525v2*/ #define LINE_INPUT 2 #else #define LINE_INPUT 1 void audiohw_preinit(void) /* Set ADC off, mixer on, DAC on, line out off, line in off, mic off */ /* Turn on SUM, DAC */ - as3514_write(AS3514_AUDIOSET1, AUDIOSET1_DAC_on | AUDIOSET1_SUM_on); + as3514_write(AS3514_AUDIOSET1, AUDIOSET1_DAC_on | AUDIOSET1_SUM_on |(3<<6)); /* Set BIAS on, DITH on, AGC on, IBR_DAC max, LSP_LP on, IBR_LSP min */ as3514_write(AS3514_AUDIOSET2, void audiohw_preinit(void) #endif /* Mute and disable speaker */ - as3514_write(AS3514_LSP_OUT_R, LSP_OUT_R_SP_OVC_TO_256MS | 0x00); - as3514_write(AS3514_LSP_OUT_L, LSP_OUT_L_SP_MUTE | 0x00); +// as3514_write(AS3514_LSP_OUT_R, LSP_OUT_R_SP_OVC_TO_256MS | 0x1f); +// as3514_write(AS3514_LSP_OUT_L, (1<<6) | 0x1f); +// + as3514_clear(0x12, 0x80); /* Set headphone over-current to 0, Min volume */ - as3514_write(AS3514_HPH_OUT_R, - HPH_OUT_R_HP_OVC_TO_0MS | 0x00); - + as3514_write(AS3514_HPH_OUT_R, (0<<7) /* out */ | (1<<5) /* dac */ + | 0x1f /* vol */); /* Headphone ON, MUTE, Min volume */ - as3514_write(AS3514_HPH_OUT_L, - HPH_OUT_L_HP_ON | HPH_OUT_L_HP_MUTE | 0x00); + as3514_write(AS3514_HPH_OUT_L, HPH_OUT_L_HP_ON | 0x1f); #ifdef PHILIPS_SA9200 /* LRCK 8-23kHz (there are audible clicks while reading the ADC otherwise) */ diff --git a/firmware/export/as3514.h b/firmware/export/as3514.h index 5385133..ed55b63 100644 extern void audiohw_set_lineout_vol(int vol_l, int vol_r); #define AS3514_DAC_L 0x0f #define AS3514_ADC_R 0x10 #define AS3514_ADC_L 0x11 +//AFE_DAC_IF 0x12 //NEW #define AS3514_AUDIOSET1 0x14 #define AS3514_AUDIOSET2 0x15 #define AS3514_AUDIOSET3 0x16 extern void audiohw_set_lineout_vol(int vol_l, int vol_r); /* Only has volume control bits */ /* LINE_OUT_L (0x01) */ -#define LINE_OUT_L_LO_SES_DM (0x3 << 6) - #define LINE_OUT_L_LO_SES_DM_MUTE (0x0 << 6) - #define LINE_OUT_L_LO_SES_DM_DF_MO (0x1 << 6) - #define LINE_OUT_L_LO_SES_DM_SE_ST (0x2 << 6) +#define LINE_OUT_L_LO_SES_DM (0x3 << 5) + #define LINE_OUT_L_LO_SES_DM_MUTE (0x0 << 5) + #define LINE_OUT_L_LO_SES_DM_DF_MO (0x1 << 5) + #define LINE_OUT_L_LO_SES_DM_SE_ST (0x2 << 5) /* Use AS3514_VOL_MASK */ /* HPH_OUT_R (0x02) */ extern void audiohw_set_lineout_vol(int vol_l, int vol_r); /* Use AS3514_VOL_MASK */ /* DAC_L (0Fh) */ -#define DAC_L_DAC_MUTE_off (0x1 << 6) +#define DAC_L_DAC_MUTE_off (0x1 << 5) /* Use AS3514_VOL_MASK */ /* ADC_R (10h) */ extern void audiohw_set_lineout_vol(int vol_l, int vol_r); /* Use AS3514_VOL_MASK */ /* ADC_L (11h) */ -#define ADC_L_FS_2 (0x1 << 7) -#define ADC_L_ADC_MUTE_off (0x1 << 6) +#define ADC_L_FS_2 (0x1 << 6) +#define ADC_L_ADC_MUTE_off (0x1 << 5) /* Use AS3514_VOL_MASK */ /* AUDIOSET1 (14h)*/ |