summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBjörn Stenberg <bjorn@haxx.se>2002-05-27 14:28:44 +0000
committerBjörn Stenberg <bjorn@haxx.se>2002-05-27 14:28:44 +0000
commit6365d0e6ccd891da7812c6c7d7b0f8eadf414b30 (patch)
treedb6abf51539f7c0399907de2c44c579e82206657
parent872e3521dde6866e77277cb7931c821824b91344 (diff)
downloadrockbox-6365d0e6ccd891da7812c6c7d7b0f8eadf414b30.zip
rockbox-6365d0e6ccd891da7812c6c7d7b0f8eadf414b30.tar.gz
rockbox-6365d0e6ccd891da7812c6c7d7b0f8eadf414b30.tar.bz2
rockbox-6365d0e6ccd891da7812c6c7d7b0f8eadf414b30.tar.xz
devcon
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@753 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--www/devcon/IMG_4083.JPGbin0 -> 739023 bytes
-rw-r--r--www/devcon/IMG_4084.JPGbin0 -> 744194 bytes
-rw-r--r--www/devcon/IMG_4085.JPGbin0 -> 807416 bytes
-rw-r--r--www/devcon/IMG_4086.JPGbin0 -> 626454 bytes
-rw-r--r--www/devcon/IMG_4087.JPGbin0 -> 904011 bytes
-rw-r--r--www/devcon/IMG_4088.JPGbin0 -> 1012372 bytes
-rw-r--r--www/devcon/IMG_4089.JPGbin0 -> 1006566 bytes
-rw-r--r--www/devcon/bildtext.txt5
-rw-r--r--www/devcon/img4083.jpgbin0 -> 67794 bytes
-rw-r--r--www/devcon/img4083t.jpgbin0 -> 12444 bytes
-rw-r--r--www/devcon/img4084.jpgbin0 -> 80091 bytes
-rw-r--r--www/devcon/img4084t.jpgbin0 -> 16550 bytes
-rw-r--r--www/devcon/img4085.jpgbin0 -> 90051 bytes
-rw-r--r--www/devcon/img4085t.jpgbin0 -> 10035 bytes
-rw-r--r--www/devcon/img4086.jpgbin0 -> 56036 bytes
-rw-r--r--www/devcon/img4086t.jpgbin0 -> 12220 bytes
-rw-r--r--www/devcon/img4087.jpgbin0 -> 79846 bytes
-rw-r--r--www/devcon/img4087t.jpgbin0 -> 8665 bytes
-rw-r--r--www/devcon/img4088.jpgbin0 -> 112641 bytes
-rw-r--r--www/devcon/img4088t.jpgbin0 -> 11368 bytes
-rw-r--r--www/devcon/img4089.jpgbin0 -> 101347 bytes
-rw-r--r--www/devcon/img4089t.jpgbin0 -> 18188 bytes
-rw-r--r--www/devcon/index.t132
-rwxr-xr-xwww/devcon/show.cgi96
24 files changed, 233 insertions, 0 deletions
diff --git a/www/devcon/IMG_4083.JPG b/www/devcon/IMG_4083.JPG
new file mode 100644
index 0000000..d6ed305
--- /dev/null
+++ b/www/devcon/IMG_4083.JPG
Binary files differ
diff --git a/www/devcon/IMG_4084.JPG b/www/devcon/IMG_4084.JPG
new file mode 100644
index 0000000..fedff94
--- /dev/null
+++ b/www/devcon/IMG_4084.JPG
Binary files differ
diff --git a/www/devcon/IMG_4085.JPG b/www/devcon/IMG_4085.JPG
new file mode 100644
index 0000000..d592852
--- /dev/null
+++ b/www/devcon/IMG_4085.JPG
Binary files differ
diff --git a/www/devcon/IMG_4086.JPG b/www/devcon/IMG_4086.JPG
new file mode 100644
index 0000000..758c6ad
--- /dev/null
+++ b/www/devcon/IMG_4086.JPG
Binary files differ
diff --git a/www/devcon/IMG_4087.JPG b/www/devcon/IMG_4087.JPG
new file mode 100644
index 0000000..15846b5
--- /dev/null
+++ b/www/devcon/IMG_4087.JPG
Binary files differ
diff --git a/www/devcon/IMG_4088.JPG b/www/devcon/IMG_4088.JPG
new file mode 100644
index 0000000..53c760d
--- /dev/null
+++ b/www/devcon/IMG_4088.JPG
Binary files differ
diff --git a/www/devcon/IMG_4089.JPG b/www/devcon/IMG_4089.JPG
new file mode 100644
index 0000000..00dacfc
--- /dev/null
+++ b/www/devcon/IMG_4089.JPG
Binary files differ
diff --git a/www/devcon/bildtext.txt b/www/devcon/bildtext.txt
new file mode 100644
index 0000000..f8869f8
--- /dev/null
+++ b/www/devcon/bildtext.txt
@@ -0,0 +1,5 @@
+4083: Comparison between Recorder and Player
+4084: Contest: Spot the development box!
+4086: A stack of "virgins"!
+4087: A pre-4.50 player (left) and a post-4.50 player (right).
+4089: There's lots of fun to be had with these things!
diff --git a/www/devcon/img4083.jpg b/www/devcon/img4083.jpg
new file mode 100644
index 0000000..e26cb18
--- /dev/null
+++ b/www/devcon/img4083.jpg
Binary files differ
diff --git a/www/devcon/img4083t.jpg b/www/devcon/img4083t.jpg
new file mode 100644
index 0000000..b615af2
--- /dev/null
+++ b/www/devcon/img4083t.jpg
Binary files differ
diff --git a/www/devcon/img4084.jpg b/www/devcon/img4084.jpg
new file mode 100644
index 0000000..9dbd59a
--- /dev/null
+++ b/www/devcon/img4084.jpg
Binary files differ
diff --git a/www/devcon/img4084t.jpg b/www/devcon/img4084t.jpg
new file mode 100644
index 0000000..31c2b6e
--- /dev/null
+++ b/www/devcon/img4084t.jpg
Binary files differ
diff --git a/www/devcon/img4085.jpg b/www/devcon/img4085.jpg
new file mode 100644
index 0000000..376a8f3
--- /dev/null
+++ b/www/devcon/img4085.jpg
Binary files differ
diff --git a/www/devcon/img4085t.jpg b/www/devcon/img4085t.jpg
new file mode 100644
index 0000000..52f3afe
--- /dev/null
+++ b/www/devcon/img4085t.jpg
Binary files differ
diff --git a/www/devcon/img4086.jpg b/www/devcon/img4086.jpg
new file mode 100644
index 0000000..051361c
--- /dev/null
+++ b/www/devcon/img4086.jpg
Binary files differ
diff --git a/www/devcon/img4086t.jpg b/www/devcon/img4086t.jpg
new file mode 100644
index 0000000..18736fe
--- /dev/null
+++ b/www/devcon/img4086t.jpg
Binary files differ
diff --git a/www/devcon/img4087.jpg b/www/devcon/img4087.jpg
new file mode 100644
index 0000000..2c047ba
--- /dev/null
+++ b/www/devcon/img4087.jpg
Binary files differ
diff --git a/www/devcon/img4087t.jpg b/www/devcon/img4087t.jpg
new file mode 100644
index 0000000..89ed228
--- /dev/null
+++ b/www/devcon/img4087t.jpg
Binary files differ
diff --git a/www/devcon/img4088.jpg b/www/devcon/img4088.jpg
new file mode 100644
index 0000000..f2cb22f
--- /dev/null
+++ b/www/devcon/img4088.jpg
Binary files differ
diff --git a/www/devcon/img4088t.jpg b/www/devcon/img4088t.jpg
new file mode 100644
index 0000000..5200231
--- /dev/null
+++ b/www/devcon/img4088t.jpg
Binary files differ
diff --git a/www/devcon/img4089.jpg b/www/devcon/img4089.jpg
new file mode 100644
index 0000000..a21385f
--- /dev/null
+++ b/www/devcon/img4089.jpg
Binary files differ
diff --git a/www/devcon/img4089t.jpg b/www/devcon/img4089t.jpg
new file mode 100644
index 0000000..b344367
--- /dev/null
+++ b/www/devcon/img4089t.jpg
Binary files differ
diff --git a/www/devcon/index.t b/www/devcon/index.t
new file mode 100644
index 0000000..8f0e1d7
--- /dev/null
+++ b/www/devcon/index.t
@@ -0,0 +1,132 @@
+#define _PAGE_ Rockbox Developer Conference 2002
+#include "head.t"
+
+<table align="right"><tr><td><a href="show.cgi?img4083.jpg"><img src="img4083t.jpg" alt="photo" border=0 width=200 height=150></a><br><small><i>Comparison of Recorder and Player</i></small></td></tr></table>
+
+<p>Well, almost. :-) Björn, Linus, Daniel and Kjell sat down at Linus' house
+friday night (2002-04-19) with our Archoses and had a long and fruitful discussion about software design.
+Here are a few things that we discussed:
+
+<h2>Application Programming Interfaces</h2>
+
+<p>We want to try to stick to POSIX where these exist and are practical. The
+reason is simply that many people already know these APIs well. Here are a
+few which haven't already been defined in the code:
+
+<h3>File operations</h3>
+<ul>
+<li>open
+<li>close
+<li>read
+<li>write
+<li>seek
+<li>unlink
+<li>rename
+</ul>
+
+<table align="right"><tr><td><a href="show.cgi?img4084.jpg"><img src="img4084t.jpg" alt="photo" border=0 width=200 height=150></a>
+<br><small><i>Contest: Spot the development box!</i></small></td></tr></table>
+
+<h3>Directory operations</h3>
+<ul>
+<li>opendir
+<li>closedir
+<li>readdir
+</ul>
+
+<h3>Disk operations</h3>
+<ul>
+<li>readblock
+<li>writeblock
+<li>spindown
+<li>diskinfo
+<li>partitioninfo
+</ul>
+
+<p>We also decided that we will use the 'newlib' standard C library,
+replacing some functions with smaller variants as we move forward.
+
+<h2>Multitasking</h2>
+
+<p>We spent much time discussing and debating task scheduling, or the lack
+thereof. First, we went with the idea that we don't really need "real"
+scheduling. Instead, a simple "tree-task" system would be used: A
+main-loop, a timer tick and a "bottom half" low-priority interrupt, each
+with an event queue.
+
+<p>Pretty soon we realized that we will want to:
+
+<ol style="a">
+<li> Use a timer tick to poll disk I/O (assuming we can't get an interrupt)
+<li> Perform slow disk operations in both the MP3->DAC feeder and the user
+ interface, sometimes at the same time.
+<li> Not lock up the user interface during I/O.
+</ol>
+
+<table align="right"><tr><td><a href="show.cgi?img4086.jpg"><img src="img4086t.jpg" alt="photo" border=0 width=200 height=150></a>
+<br><small><i>A stack of "virgins"!</i></small></td></tr></table>
+
+<p>At the same time, we agreed that we should not walk into the common trap
+of engaging in "job splitting". That is, to split up jobs in small chunks
+so they don't take so long to finish. The problem with job splitting is
+that it makes the code flow very complex.
+
+<p>After much scratching our collective heads over how to make a primitive
+"three-task" system be able to do everything we wanted without resorting
+to complex job splitting, we finally came to the conclusion that we were
+heading down the wrong road:
+
+<p><blockquote>
+ <b>We need threading.</b>
+</blockquote>
+
+<p>Even though a scheduler adds complexity, it makes the rest of the code so
+much more straight-forward that the total net result is less overall
+complexity.
+
+<p>To keep it simple, we decided to use a cooperative scheduler. That is, one
+in which the threads themselves decide when scheduling is performed. The
+big gain from this, apart from making the scheduler itself less complex,
+is that we don't have to worry as much about making all code "multithread
+safe".
+
+<p>Affording ourselves the luxury of threads, we soon identified four basic
+threads:
+
+<ul>
+<li>Disk thread, performing all disk operations
+<li>UI thread, handling the user interface
+<li>MP3 feed thread, making sure the MAS is fed with data at all times
+<li>I2C thread, handling the sometimes very relaxed timing of the I2C bus
+</ul>
+
+<p>Threads use message passing between them and each have a message queue
+associated to it.
+
+<table align="right"><tr><td><a href="show.cgi?img4089.jpg"><img src="img4089t.jpg" alt="photo" border=0 width=200 height=150></a>
+<br><small><i>There's much fun to be had with these things!</i></small></td></tr></table>
+
+<p>In addition to the threads, we need a timer interrupt with the ability to
+send messages to threads at specific intervals. This will also be used to
+scan the keys of the jukebox and handle key repeat detection (when a key
+has been pressed for a number of ticks).
+
+<p>None of these things are, of course, written in stone. Feel free to
+comment, discuss and argue about them!
+
+<p>We are currently 89 subscribers to this list. If you want to get more
+deeply involved in what's going on, I encourage you to:
+
+<ul>
+<li>Subscribe to the rockbox-cvs list, to see all code that goes in.
+<li>Join the #rockbox channel on irc.openprojects.net. There are always a
+couple of us in there.
+</ul>
+
+<p>I have written a set of guidelines for contributing code to the project.
+Take a look at them in CVS or here:
+<a href="http://bjorn.haxx.se/rockbox/firmware/CONTRIBUTING">CONTRIBUTING</a>
+
+<p>/Björn
+
+#include "foot.t"
diff --git a/www/devcon/show.cgi b/www/devcon/show.cgi
new file mode 100755
index 0000000..c8123b3
--- /dev/null
+++ b/www/devcon/show.cgi
@@ -0,0 +1,96 @@
+#!/usr/bin/perl
+
+use File::Basename;
+
+$cgi = basename $0;
+
+print "Content-Type: text/html\n\n";
+
+$image = $ARGV[0];
+
+$image =~ /img(\d+)/;
+
+print "<html><head><title>Rockbox - Photo $1</title></head>\n";
+print "<body bgcolor=black text=white link=white vlink=gray>\n";
+
+if ($image eq "" ) {
+ print "<p>No image specified\n";
+ exit;
+}
+
+print "<h1>&nbsp;</h1><div align=center><img src=$image>\n";
+
+# compressed image
+if ( $image =~ /img(\d+).jpg/ ) {
+ $num = $1;
+ for $i ( 1 .. 10 ) {
+ $prev = sprintf("%04d",$num-$i);
+ last if ( -f "img$prev.jpg" );
+ }
+ if ( $prev == $num-10 ) {
+ undef $prev;
+ }
+
+ for $i ( 1 .. 20 ) {
+ $next = sprintf("%04d",$num+$i);
+ print "<!-- Trying $next -->\n";
+ last if ( -f "img$next.jpg" );
+ }
+ if ( $next == $num+20 ) {
+ undef $next;
+ }
+
+ if ( -f "bildtext.txt" ) {
+ open FILE, "<bildtext.txt";
+ @txt = <FILE>;
+ close FILE;
+ @match = grep /^$num: /, @txt;
+ if ( $match[0] =~ /^$num: (.*)/ ) {
+ print "<p><i>$1</i>\n";
+ }
+ }
+
+
+ print "<p>\n";
+ print "<a href=$cgi?img$prev.jpg>&lt; Previous</a> &nbsp; \n" if ( $prev );
+ print "<a href=.>Index</a>\n";
+ if ( -f "IMG_$num.JPG" ) {
+ $size = int( (stat("IMG_$num.JPG"))[7] / 1024 );
+ print " &nbsp; <a href=IMG_$num.JPG>Fullsize ($size kB)</a>\n";
+ }
+
+ print " &nbsp; <a href=$cgi?img$next.jpg>Next &gt;</a>\n" if ( $next );
+
+}
+
+# showing fullsize already
+elsif ( $image =~ /IMG_(\d+).JPG/ ) {
+ $num = $1;
+ for $i ( 1 .. 10 ) {
+ $prev = sprintf("%04d",$num-$i);
+ last if ( -f "IMG_$prev.JPG" );
+ }
+ if ( $prev == $num-10 ) {
+ undef $prev;
+ }
+
+ for $i ( 1 .. 20 ) {
+ $next = sprintf("%04d",$num+$i);
+ print "<!-- Trying $next -->\n";
+ last if ( -f "IMG_$next.JPG" );
+ }
+ if ( $next == $num+20 ) {
+ undef $next;
+ }
+
+ print "<p>\n";
+ print "<a href=$cgi?IMG_$prev.JPG>&lt; Previous</a> &nbsp; \n" if ( $prev );
+ print "<a href=.>Index</a>\n";
+ if ( -f "img$num.jpg" ) {
+ $size = int( (stat("img$num.jpg"))[7] / 1024 );
+ print " &nbsp; <a href=img$num.jpg>Small ($size kB)</a>\n";
+ }
+
+ print " &nbsp; <a href=$cgi?IMG_$next.JPG>Next &gt;</a>\n" if ( $next );
+}
+print "</div></body></html>\n";