Want to earn stuff by watching TV? There's now a free app for that.

When you tap the screen, Viggle's software for iPhones and iPads listens to what's on, recognizes what you're watching and gives you credit at roughly 2 points per minute. It even works for shows you've saved on a digital video recorder.

Rack up 7,500 points, and you'll be rewarded with a $5 gift card from retailers such as Burger King, Starbucks, iTunes, Best Buy and CVS, which you can redeem directly from your device.

With some back-of-the-envelope math, you can figure that it would take three weeks of watching TV every night for three hours to earn enough for a latte at Starbucks.

But the company plans to offer bonus points for checking into certain shows such as "American Idol" and 1,500 points for signing up. You can also get extra points for watching an ad on your device. The beta version awarded 100 points for watching a 15-second ad from Verizon Wireless.

"Viggle is the first loyalty program for TV," said Chris Stephenson, president of the company behind Viggle, Function (X). "We're basically allowing people to get rewards for doing something they're doing already and that they love to do."

The idea behind Viggle is that if people have an added reason to watch TV, the size of the audience will increase, allowing makers of shows to earn more money from advertisers. Advertisers such as Burger King, Pepsi and Gatorade have also agreed to pay to have point-hungry users watch their ads on a mobile device.

In exchange, users earn points, which Viggle converts into real value by buying gift cards at a slight discount from retailers.

If the company gets the point-count economy right, it can end up making more money from advertisers and networks than it gives away in rewards.

The app will also give the company valuable insight into who is watching what, because redeeming rewards requires putting in your age, gender, e-mail address and ZIP code.

"It really shows what social TV is going to evolve into," said Michael Gartenberg, a technology analyst at research firm Gartner. "For folks behind the scenes, this is a great way of seeing who really is watching."

The company hopes that user activity will grow by word of mouth, especially by offering a 200-point bonus to people who successfully get their friends to try out the service.

The app made its debut in Apple's app store on Wednesday. Versions for Android devices and computers are in the works.

The company has put in safeguards. You must watch a show at least 10 minutes to earn bonus points. And you can't watch the same ad over and over again to earn more points; there's a one-ad-view-per-person rule.