1.1 --- a/stage2/example.c Sun Apr 24 16:19:49 2016 +0200
1.2 +++ b/stage2/example.c Sun Apr 24 17:06:08 2016 +0200
1.3 @@ -35,15 +35,24 @@
1.4 }
1.5 }
1.6
1.7 +void plot_value(u32 value)
1.8 +{
1.9 + unsigned short x, y;
1.10 + for (y = 0; y < panel_info.vl_row; y++)
1.11 + {
1.12 + for (x = 0; x < panel_info.vl_col; x++)
1.13 + {
1.14 + set_pixel(x, y, get_bitmap_value(x, value));
1.15 + }
1.16 + }
1.17 +}
1.18 +
1.19 /* Tasks. */
1.20
1.21 void plot_pattern(unsigned short pixel_type, unsigned short x, unsigned short y)
1.22 {
1.23 while (1) {
1.24 - if (pixel_type)
1.25 - test_pixel(x, y, pixel_type);
1.26 - else
1.27 - clear_pixel(x, y);
1.28 + test_pixel(x, y, pixel_type);
1.29 next_pixel(&x, &y);
1.30 udelay(100);
1.31 }
1.32 @@ -51,7 +60,7 @@
1.33
1.34 void start_plot_pattern(unsigned short task)
1.35 {
1.36 - u32 args[] = {task, 0, (task - 1) * 60};
1.37 + u32 args[] = {task, 0, ((task - 1) * (panel_info.vl_row / 4)) % panel_info.vl_row};
1.38
1.39 start_task(task, (void (*)()) plot_pattern, args, 3);
1.40 }