Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4084748
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T18:28:46+00:00 2026-05-20T18:28:46+00:00

I’m building an application that has a media player in it (I’m using iOS

  • 0

I’m building an application that has a media player in it (I’m using iOS SDK 4.2). While a given song is playing, I can access pretty much every one of the properties, but I can not access MPMediaItemPropertyBeatsPerMinute.

It returns null every time.

The Apple doc states:

The number of musical beats per minute for the media item, corresponding to the “BPM” field in the Info tab in the Get Info dialog in iTunes. Value is an NSNumber object representing an NSUInteger data type.

Available in iOS 4.0 and later.

Declared in MPMediaItem.h.

Please note that the songs I am using DO have the BPM data in the BPM field. I know it is not set by default.

The code I have been trying is:

MPMusicPlayerController *musicPlayer = [MPMusicPlayerController applicationMusicPlayer];
// ...
MPMediaItem *currentItem = [musicPlayer nowPlayingItem];
if (currentItem != NULL) {
  NSLog([NSString stringWithFormat:@"%@", [currentItem valueForProperty:MPMediaItemPropertyBeatsPerMinute]]);
}

The code above spits out “(null)” for every song.

Since I was able to access every other property of the current song this way, I believe this could be a bug in the SDK.

So, my question is slightly two-fold.

  1. Am I doing this wrong, or is this a known bug in the SDK?
  2. How else could I go about retrieving the BPM data on the song?
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T18:28:47+00:00Added an answer on May 20, 2026 at 6:28 pm

    I’ve tested this issue with iOS SDK 4.3 and can confirm that it works. Your code looks okay however.

    It might be a bug in the 4.2 SDK that has been fixed in 4.3. I can also imagine that older versions of iTunes do not sync the BPM property correctly.

    You could try to use the string @"beatsPerMinute" instead of MPMediaItemPropertyBeatsPerMinute (works in iOS 4.3), but I guess that won’t resolve your problem.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

No related questions found

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.