Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Thank You for your continued support and contributions!

+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  Starting Development and Compiling
| | |-+  fm radio in a plugin
« previous next »
  • Print
Pages: [1]

Author Topic: fm radio in a plugin  (Read 1888 times)

Offline rockboxer45

  • Member
  • *
  • Posts: 3
fm radio in a plugin
« on: November 21, 2008, 02:41:28 PM »


I have installed rockbox on my sansa e250 player and now I am trying to write some plugins. I want to know if it is posible to turn on/off the fm radio from a plugin.

thanks in advance for your help.
Logged

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
Re: fm radio in a plugin
« Reply #1 on: November 23, 2008, 08:32:42 PM »
Not currently. You could possibly add some of the radio functions to the plugin API if needed. but if you just want to have the radio running in your plugin (instead of silence) start the radio in the menu, then start your plugin and it should stay one.
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline rockboxer45

  • Member
  • *
  • Posts: 3
Re: fm radio in a plugin
« Reply #2 on: November 24, 2008, 12:45:18 AM »
Thanks for your answer.

I have added some functions  to the  plugin API but I still can't start the radio from the plugin. For instance, I have added the functions in radio.h (and radio.c) but when i use radio_start(), nothing happens. Then i wrote a line "splash" in the same function (radio_start) in  radio.c  file and i saw the splash text, but the radio doesn't start.

Coclusion: I can add the functions to the plugin API but i don't know exactly which is the function that i need to start the radio and in what is the file where that function is located.

Can you help me about that?

Thanks in advance

Logged

Offline JdGordon

  • Member
  • *
  • Posts: 1817
  • Constantly breaking stuff
Re: fm radio in a plugin
« Reply #3 on: November 24, 2008, 01:03:43 AM »
I dont know the radio code very much so cant really help... best I can suggest is looking at apps/recorder/radio.c and figure out how it starts the radio.
Logged


Using PMs to annoy devs about bugs/patches is not a good way to have the issue looked at.

Offline rockboxer45

  • Member
  • *
  • Posts: 3
Re: fm radio in a plugin
« Reply #4 on: November 24, 2008, 10:08:34 AM »

I've studied the functions and the files related with the fmradio and finally i have found that the function audio_set_input_source() (included in the plugin API :D) is enough to power on or off the FM radio from the plugin. I have used macros like AUDIO_SRC_FMRADIO as arguments to this function and it works nicely.

Thanks for your help
Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  Starting Development and Compiling
| | |-+  fm radio in a plugin
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.064 seconds with 15 queries.