Changeset c7325dd6 in mainline
- Timestamp:
- 2011-09-26T09:57:01Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 050d4fa
- Parents:
- b3f36d2
- Location:
- uspace/drv/audio/sb16
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/audio/sb16/mixer.c
rb3f36d2 rc7325dd6 114 114 void mixer_load_volume_levels(sb16_regs_t *regs, mixer_type_t type) 115 115 { 116 /* Default values are ok for now */ 116 /* Set Master to maximum */ 117 if (!mixer_get_control_item_count(type)) 118 return; 119 unsigned levels = 0, channels = 0, current_level; 120 const char *name = NULL; 121 mixer_get_control_item_info(type, 0, &name, &channels, &levels); 122 unsigned channel = 0; 123 for (;channel < channels; ++channel) { 124 current_level = 125 mixer_get_volume_level(regs, type, 0, channel); 126 ddf_log_note("Setting %s channel %d to %d (%d).\n", 127 name, channel, levels - 1, current_level); 128 129 mixer_set_volume_level(regs, type, 0, channel, levels - 1); 130 131 current_level = 132 mixer_get_volume_level(regs, type, 0, channel); 133 ddf_log_note("%s channel %d set to %d.\n", 134 name, channel, current_level); 135 } 136 117 137 } 118 138 /*----------------------------------------------------------------------------*/ 119 139 void mixer_store_volume_levels(sb16_regs_t *regs, mixer_type_t type) 120 140 { 121 /* Default values are ok for now*/141 /* No place to store the values. */ 122 142 } 123 143 /*----------------------------------------------------------------------------*/ -
uspace/drv/audio/sb16/sb16.c
rb3f36d2 rc7325dd6 100 100 return ret; 101 101 } 102 mixer_load_volume_levels(drv->regs, drv->mixer); 102 103 ddf_log_note("Initialized mixer: %s.\n", mixer_type_to_str(drv->mixer)); 103 104
Note:
See TracChangeset
for help on using the changeset viewer.