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
|-+  Support and General Use
| |-+  User Interface and Voice
| | |-+  Auto config loading or theme loading on mode switch...
« previous next »
  • Print
Pages: 1 [2]

Author Topic: Auto config loading or theme loading on mode switch...  (Read 6189 times)

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Auto config loading or theme loading on mode switch...
« Reply #15 on: September 04, 2007, 08:06:18 PM »
Yes, it's rather obvious that a car adapter is a type of charger, and you must have a player that charges before you can have a player with car adapters, so it's going to be wrapped in #ifdef CONFIG_CHARGING. This is common sense.

All car adapters (by Rockbox's definition of the device) are chargers, not all chargers are car adapters... I don't see why you still seem to think they're identical.

It's not #ifdef CONFIG_CAR_ADAPTER, it's #ifdef CONFIG_CHARGING...

Is it so hard to merely say "Sorry, I'll be more explicit in future posts" or do you honestly think the variables were given intentionally misleading names, and they really meant to say CONFIG_CAR_ADAPTER and SYS_CAR_ADAPTER_CONNECTED?
Logged

Offline yegods

  • Member
  • *
  • Posts: 71
Re: Auto config loading or theme loading on mode switch...
« Reply #16 on: September 04, 2007, 09:31:51 PM »
Quote
Is it so hard to merely say "Sorry, I'll be more explicit in future posts" or do you honestly think the variables were given intentionally misleading names, and they really meant to say CONFIG_CAR_ADAPTER and SYS_CAR_ADAPTER_CONNECTED?

i don't know why you feel the need to nitpick everything i say.  i had a need to load a config file for while i was plugged into the car, and i satisfied that need by using a "car adapter mode" detection function that ALREADY existed... so why don't you go and complain to the original author of that function, if you don't think it's named properly??  please get off my back.  you're giving me a real distaste for this "community".
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Auto config loading or theme loading on mode switch...
« Reply #17 on: September 04, 2007, 11:27:09 PM »
I didn't say the function was named improperly. But the function doesn't do "detection". The function is named "processing", as in "it's what is processed when a charger is detected if the player has car adapter mode enabled."

The function itself doesn't do the detection, so I still don't understand why you insist on thinking it's a detection function. I never once said that the "processing" function was poorly named, now did I? All I said was that you referred to something that didn't exist, and that you need to be clearer and more precise.

Yes, I'm being nitpicky, but yes it's also important that you actually call things either what they are, or what they're named. The function does not "sense" a "car adapter" so there is no "car adapter mode sensor". I don't see why you have to be so stubborn as to be unwilling to just admit you called it something other than what it is, and confused someone.

It's not an issue of "community", it's an issue of "these are technical forums, and technical accuracy is important." My point is merely that if you go around making up names for things, you will confuse people. If you're going to respond to just one thing in this post, tell me why you think it's not important people call things by the right name in a forum where other people might search for information and actually know the right name when typing in search terms?

So, are you arguing that there is in fact something that senses *just* car adapters, or is there no car adapter sensor, and you called it something it is not?
« Last Edit: September 04, 2007, 11:29:08 PM by Llorean »
Logged

Offline yegods

  • Member
  • *
  • Posts: 71
Re: Auto config loading or theme loading on mode switch...
« Reply #18 on: September 05, 2007, 01:30:45 PM »
Quote
these are technical forums, and technical accuracy is important

okay, i'll give you that point.

my argument was more along the lines of... the SYS_CHARGER_CONNECTED event detects a charger, and the car adapter mode processing function is called as a result of that event.  the adapter processing function will never be called unless the SYS_CHARGER_CONNECTED event is detected.   therefore the effect of the event is also to detect whatever makes up the car adapter mode... QED.

i really don't think i'm being technically inaccurate.  it's just the definition of what "car adapter mode" is, that is fuzzy.
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Auto config loading or theme loading on mode switch...
« Reply #19 on: September 05, 2007, 02:14:58 PM »
"Car adapter mode" is a change in functionality to occur when any charger (car adapter or not) is unplugged (or plugged) and car adapter mode is enabled in the settings.

The effect of the event is to detect a charger. Car adapter mode occurs when a charger is plugged in at which point 'charger' related actions will always happen, while 'car adapter' actions may or may not happen depending on whether car adapter mode is enabled. Which is why I was making the distinction. There will always be charger events on a charger insert, while car adapter mode has a setting, and you *need* to distinguish the two, because if you treat "SYS_CHARGER_CONNECTED" as if it's only a car adapter thing, people plugging their players into the wall with car adapter mode disabled are still going to get affected by functionality that shouldn't happen.
Logged

Offline yegods

  • Member
  • *
  • Posts: 71
Re: Auto config loading or theme loading on mode switch...
« Reply #20 on: September 05, 2007, 02:33:03 PM »
Quote
because if you treat "SYS_CHARGER_CONNECTED" as if it's only a car adapter thing, people plugging their players into the wall with car adapter mode disabled are still going to get affected by functionality that shouldn't happen.

i don't do that.  all functionality for the "car adapter mode" config swap is located in the car adapter mode processing function, _after_ it checks for the global.car_adapter_mode setting.
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Auto config loading or theme loading on mode switch...
« Reply #21 on: September 05, 2007, 02:42:40 PM »
I didn't say you did do that, I said that it shouldn't be done, and differentiating between the sensing (which detects a charger insertion) and the action (the car adapter processing) keeps it clear where you're adding your code, and what is being done. And prevents confusion among other people.
Logged

Offline yegods

  • Member
  • *
  • Posts: 71
Re: Auto config loading or theme loading on mode switch...
« Reply #22 on: September 05, 2007, 06:19:32 PM »
i've uploaded my patch.  i've been testing it for the last week, and it seems to work rather well.  here is the patch link:

http://www.rockbox.org/tracker/task/7716
Logged

  • Print
Pages: 1 [2]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  User Interface and Voice
| | |-+  Auto config loading or theme loading on mode switch...
 

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

Page created in 0.067 seconds with 16 queries.