PX4/Firmware — pull request #954 by LorenzMeier (2014-05-14 20:11:11+00:00)
Title: Stack sweep

This PR fixes the stack sizes for a number of modules. The sizes in the modules.mk are only the command line tool stacks and were excessively large, contributing to memory fragmentation during boot. Also shaved slightly off the commander and mavlink application stacks.

Free with 2 MAVLink instances on multicopter and with BlinkM loaded:

```
nsh> free
total used free largest
Mem: 177456 167040 10416 2624
```

And processes:

```
Processes: 21 total, 3 running, 18 sleeping
CPU usage: 48.26% tasks, 0.59% sched, 51.15% idle
Uptime: 53.711s total, 27.202s idle

PID COMMAND CPU(ms) CPU(%) USED/STACK PRIO(BASE) STATE
0 Idle Task 27206 51.150 0/ 0 0 ( 0) READY
1 hpwork 1885 3.489 740/ 2040 192 (192) w:sig
2 lpwork 300 0.519 1156/ 2040 50 ( 50) READY
3 init 429 0.000 1420/ 4088 100 (100) w:sem
122 top 134 4.454 1220/ 2040 100 (100) RUN
52 commander 221 0.222 1996/ 2792 215 (215) w:sig
53 commander_low_prio 17 0.000 604/ 2984 50 ( 50) w:sem
55 px4io 2349 4.528 916/ 2040 240 (240) w:sem
60 mavlink_if0 590 1.113 1028/ 1792 100 (100) w:sig
61 mavlink_rcv_if0 25 0.000 788/ 2992 215 (215) w:sem
76 sensors_task 1903 3.860 876/ 2040 250 (250) w:sem
102 position_estimator_inav 1423 2.746 2388/ 4088 250 (250) w:sem
80 sdlog2 250 0.148 1852/ 2992 70 ( 70) w:sig
83 gps 195 0.371 972/ 2040 220 (220) w:sem
100 attitude_estimator_ekf 11272 21.603 12916/13992 250 (250) w:sem
104 mc_att_control 1998 3.860 1100/ 2040 250 (250) w:sem
106 mc_pos_control 394 0.816 1028/ 2040 250 (250) w:sem
110 dataman 701 0.000 692/ 2040 250 (250) w:sem
120 mavlink_if1 2053 0.000 1124/ 1792 215 (100) w:sem
113 navigator 256 0.519 868/ 2040 250 (250) w:sem
121 mavlink_rcv_if1 4 0.000 1268/ 2992 215 (215) w:sem
```