• Status Closed
  • Percent Complete
  • Task Type Bugs
  • Category Operating System/Drivers
  • Assigned To No-one
  • Operating System Coldfire-based
  • Severity Low
  • Priority Very Low
  • Reported Version Daily build (which?)
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by misarm - 2007-08-02
Last edited by linusnielsen - 2007-08-04

FS#7520 - frame_period bug in coldfire's pcm_calculate_peaks

Maybe in “firmware/target/coldfire/pcm-coldfire.c” procedure pcm_calculate_peaks(int *left, int *right) should be:
frame_period = (3*period + period) » 2;
instead of
frame_period = (3*frame_period + period) » 2;

Closed by  linusnielsen
2007-08-04 10:55
Reason for closing:  Not a Bug
Additional comments about closing:   Warning: Undefined array key "typography" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 371 Warning: Undefined array key "camelcase" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 407

False alarm.

I’ve taken a quick look at the code (which definitely doesn’t look right).
At the moment frame_period = (period) » 2;, but what it LOOKS like it’s trying to is frame_period = period;, however I don’t know understand the code enough to make any changes. (Note that (3*period + period) » 2; is the same as period.)

Project Manager

The current code surely looks right to me. It calculates a running average of the time between the calls to pcm_calculate_peaks(). Remember that sample_period is a static variable.

I’m sorry, (3*period + period) » 2 is really same as period. I inly didn’t understand frame_period = (3*frame_period + period) » 2; when frame_period is initialized to 0. I want to do simple frequency spectrum analyzer plugin. Which way is the best to get playing/recording samples? When I was thinking about it, I found this (maybe) mistake.(Sorry for my bad English).

Project Manager

Again, note that frame_period is a *static* variable. This is not a bug.

As far as getting help for your spectrum analyzer plugin, seek help on the mailing list, IRC or the forums.


Available keyboard shortcuts


Task Details

Task Editing