summaryrefslogtreecommitdiff
path: root/apps/recorder
diff options
context:
space:
mode:
Diffstat (limited to 'apps/recorder')
-rw-r--r--apps/recorder/pcm_record.c10
-rw-r--r--apps/recorder/peakmeter.c4
-rw-r--r--apps/recorder/recording.c8
3 files changed, 11 insertions, 11 deletions
diff --git a/apps/recorder/pcm_record.c b/apps/recorder/pcm_record.c
index da4e9b7255..dbbc6901ec 100644
--- a/apps/recorder/pcm_record.c
+++ b/apps/recorder/pcm_record.c
@@ -24,7 +24,7 @@
24#include "logf.h" 24#include "logf.h"
25#include "thread.h" 25#include "thread.h"
26#include <string.h> 26#include <string.h>
27#include "ata.h" 27#include "storage.h"
28#include "usb.h" 28#include "usb.h"
29#include "buffer.h" 29#include "buffer.h"
30#include "general.h" 30#include "general.h"
@@ -162,7 +162,7 @@ static bool pcm_buffer_empty; /* all pcm chunks processed? */
162static int low_watermark; /* Low watermark to stop flush */ 162static int low_watermark; /* Low watermark to stop flush */
163static int high_watermark; /* max chunk limit for data flush */ 163static int high_watermark; /* max chunk limit for data flush */
164static unsigned long spinup_time = 35*HZ/10; /* Fudged spinup time */ 164static unsigned long spinup_time = 35*HZ/10; /* Fudged spinup time */
165static int last_ata_spinup_time = -1;/* previous spin time used */ 165static int last_storage_spinup_time = -1;/* previous spin time used */
166#ifdef HAVE_PRIORITY_SCHEDULING 166#ifdef HAVE_PRIORITY_SCHEDULING
167static int flood_watermark; /* boost thread priority when here */ 167static int flood_watermark; /* boost thread priority when here */
168#endif 168#endif
@@ -731,7 +731,7 @@ static void pcmrec_end_file(void)
731 */ 731 */
732static void pcmrec_refresh_watermarks(void) 732static void pcmrec_refresh_watermarks(void)
733{ 733{
734 logf("ata spinup: %d", ata_spinup_time); 734 logf("ata spinup: %d", storage_spinup_time());
735 735
736 /* set the low mark for when flushing stops if automatic */ 736 /* set the low mark for when flushing stops if automatic */
737 low_watermark = (LOW_SECONDS*4*sample_rate + (enc_chunk_size-1)) 737 low_watermark = (LOW_SECONDS*4*sample_rate + (enc_chunk_size-1))
@@ -755,7 +755,7 @@ static void pcmrec_refresh_watermarks(void)
755 755
756 logf("flood at: %d", flood_watermark); 756 logf("flood at: %d", flood_watermark);
757#endif 757#endif
758 spinup_time = last_ata_spinup_time = ata_spinup_time; 758 spinup_time = last_storage_spinup_time = storage_spinup_time();
759 759
760 /* write at 8s + st remaining in enc_buffer - range 12s to 760 /* write at 8s + st remaining in enc_buffer - range 12s to
761 20s total - default to 3.5s spinup. */ 761 20s total - default to 3.5s spinup. */
@@ -816,7 +816,7 @@ static void pcmrec_flush(unsigned flush_num)
816 if (!is_recording) 816 if (!is_recording)
817 return; 817 return;
818 818
819 if (ata_spinup_time != last_ata_spinup_time) 819 if (storage_spinup_time() != last_storage_spinup_time)
820 pcmrec_refresh_watermarks(); 820 pcmrec_refresh_watermarks();
821 821
822 /* enough available? no? then leave */ 822 /* enough available? no? then leave */
diff --git a/apps/recorder/peakmeter.c b/apps/recorder/peakmeter.c
index ce0974a084..422b138020 100644
--- a/apps/recorder/peakmeter.c
+++ b/apps/recorder/peakmeter.c
@@ -26,7 +26,7 @@
26#include "thread.h" 26#include "thread.h"
27#include "kernel.h" 27#include "kernel.h"
28#include "settings.h" 28#include "settings.h"
29#include "ata.h" 29#include "storage.h"
30#include "lcd.h" 30#include "lcd.h"
31#include "scrollbar.h" 31#include "scrollbar.h"
32#include "gwps.h" 32#include "gwps.h"
@@ -1343,7 +1343,7 @@ int peak_meter_draw_get_btn(int action_context, int x[], int y[],
1343 * is active, it must not draw too much CPU power or a buffer overrun can 1343 * is active, it must not draw too much CPU power or a buffer overrun can
1344 * happen when saving a recording. As a compromise, poll only once per tick 1344 * happen when saving a recording. As a compromise, poll only once per tick
1345 * when the disk is active, otherwise spin around as fast as possible. */ 1345 * when the disk is active, otherwise spin around as fast as possible. */
1346 bool highperf = !ata_disk_is_active(); 1346 bool highperf = !storage_disk_is_active();
1347#endif 1347#endif
1348 bool dopeek = true; 1348 bool dopeek = true;
1349 1349
diff --git a/apps/recorder/recording.c b/apps/recorder/recording.c
index d29db390c7..5a2aa096db 100644
--- a/apps/recorder/recording.c
+++ b/apps/recorder/recording.c
@@ -65,7 +65,7 @@
65#include "errno.h" 65#include "errno.h"
66#include "talk.h" 66#include "talk.h"
67#include "sound.h" 67#include "sound.h"
68#include "ata.h" 68#include "storage.h"
69#include "splash.h" 69#include "splash.h"
70#include "screen_access.h" 70#include "screen_access.h"
71#include "action.h" 71#include "action.h"
@@ -298,7 +298,7 @@ static bool read_peak_levels(int *peak_l, int *peak_r, int *balance)
298 peak_valid_mem[peak_time % 3] = *peak_l; 298 peak_valid_mem[peak_time % 3] = *peak_l;
299 if (((peak_valid_mem[0] == peak_valid_mem[1]) && 299 if (((peak_valid_mem[0] == peak_valid_mem[1]) &&
300 (peak_valid_mem[1] == peak_valid_mem[2])) && 300 (peak_valid_mem[1] == peak_valid_mem[2])) &&
301 ((*peak_l < 32767) || ata_disk_is_active())) 301 ((*peak_l < 32767) || storage_disk_is_active()))
302 return false; 302 return false;
303 303
304 if (*peak_r > *peak_l) 304 if (*peak_r > *peak_l)
@@ -1034,7 +1034,7 @@ bool recording_screen(bool no_source)
1034 rec_status = RCSTAT_IN_RECSCREEN; 1034 rec_status = RCSTAT_IN_RECSCREEN;
1035 1035
1036#if (CONFIG_LED == LED_REAL) && !defined(SIMULATOR) 1036#if (CONFIG_LED == LED_REAL) && !defined(SIMULATOR)
1037 ata_set_led_enabled(false); 1037 storage_set_led_enabled(false);
1038#endif 1038#endif
1039 1039
1040#if CONFIG_CODEC == SWCODEC 1040#if CONFIG_CODEC == SWCODEC
@@ -1905,7 +1905,7 @@ rec_abort:
1905 reload_directory(); 1905 reload_directory();
1906 1906
1907#if (CONFIG_LED == LED_REAL) && !defined(SIMULATOR) 1907#if (CONFIG_LED == LED_REAL) && !defined(SIMULATOR)
1908 ata_set_led_enabled(true); 1908 storage_set_led_enabled(true);
1909#endif 1909#endif
1910 1910
1911#if CONFIG_TUNER 1911#if CONFIG_TUNER