as3525v2-usb: define number of enpoints correctly, write interrupt handler
[kugel-rb.git] / docs / CONTRIBUTING
blob83f0aa655e552373c1da08c1c311984eeb6cf2ba
1 $Id$
3                __________               __   ___.
4      Open      \______   \ ____   ____ |  | _\_ |__   _______  ___
5      Source     |       _//  _ \_/ ___\|  |/ /| __ \ /  _ \  \/  /
6      Jukebox    |    |   (  <_> )  \___|    < | \_\ (  <_> > <  <
7      Firmware   |____|_  /\____/ \___  >__|_ \|___  /\____/__/\_ \
8                        \/            \/     \/    \/            \/
9                                  Contribution Policies
12 In order for the project to run as smoothly as possible, it's best if all
13 contributors adhere to a few simple source code conventions:
15 Exceptions
16 ----------
17 This project borrows and imports quite a lot of code from other free software
18 projects. We do not change style of such code unless we really have to, even
19 though they might be using style very different from others.
21 Language
22 --------
23 Write all code in C. Sometimes assembly is faster, but C is always more
24 readable and maintainable.
26 Language features
27 -----------------
28 Write normal C code. Keep it simple. Don't redefine the language. No new types
29 (structs are structs, not typedefs). No C++isms or Javaisms. No code in .h
30 files or #defines.
32 Identifiers
33 -----------
34 We do not want mixed case identifiers.
35 Variables and function names should be all lower case.
36 Struct and enum names should be all lower case.
37 Preprocessor symbols and enum constants should be all upper case.
39 Comments
40 --------
41 We only use plain old /* C standard comments */.
42 If you want to comment out large blocks containing other comments, use #if 0.
44 Style
45 -----
46 When changing code, follow the code style of the file you are editing.
48 When writing new files, you may use the brace placement style of your choice.
50 Braces for function declarations are put in a new line under the name, as in:
52   int foo(char *name)
53   {
54      return FOO_NAME:
55   }
57 Always indent your code with four spaces. Don't use TAB characters, as that
58 will mess up code display in CVS, printing, and a zillion other places.
60 Keep lines below 80 columns length. Use whitespace and newlines to make the
61 code easy to browse/read.
63 Text format
64 -----------
65 Use "unix style" line feeds: "LF" only. Do not use "CR+LF".
67 Use UTF-8 character set, but try to refrain from using any non-ascii
68 letters as they will only appear weird in some camps no matter what.
70 Patches
71 -------
72 Create a patch using 'svn diff > mychanges.patch
73 Trim your patches so they only contain relevant changes.
75 Submit your patch to the project via our patch tracker:
76 http://www.rockbox.org/tracker/index.php?type=4
78 Credits
79 -------
80 We believe in crediting all contributors by name. Before committing a patch to
81 SVN, we ask that you give us your full real name (no pseudonyms or nicknames)
82 for adding to the credits list.