Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide
translations



Rockbox mail archive

Subject: Re: source suggestings (was missing win32 file)

Re: source suggestings (was missing win32 file)

From: Björn Stenberg <bjorn_at_haxx.se>
Date: Wed, 12 Jun 2002 11:43:07 +0200 (MET DST)

Greg Haerr wrote:

> #define BUTTON_UP APP_PLAY

That would add application knowledge to the firmware library, which means
mixing layers. I'm trying to avoid that.

Check out the latest tree.c in CVS. I added TREE_NEXT etc definitions at
the top so now the switch is much cleaner. I'll do the same to the menu
code.

> An idea here would be to not require any firmware/*.c code in the
> simulator, except for some very basic init_xxx() functions, which would
> be defined in both firmware/ and uisimulator/ directories, suited for
> either target, x11, or win32 init. So in other words, the code in
> apps/main.c:init() would be moved to say, firmware/kernel.c

The idea with the division of firmware and apps is that firmware is a
library that can be used to write a variety of applications, not just the
mp3 player we're writing now. (Which, somewhat confusingly, is located in
the 'apps' directory.)

Not every application will need the file system, for example, so it would
be unwise to require every app to initialize it (and thus force it to link
the code for it). By letting the application choose which parts of the
firmware library to use/initialize, we give more freedom to application
programmers.

-- 
Björn
Received on 2002-06-12

Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy