95 {
96
98
99 int num_leds =
args.num_leds;
100 float leds_per_turn =
args.leds_per_turn;
101 float width_cm =
args.width_cm;
102
103
104 const float circumference = leds_per_turn;
105 const float radius = circumference / (2.0 *
PI);
106 const float angle_per_led = 2.0 *
PI / leds_per_turn;
107 const float height_per_turn_cm = width_cm;
108 const float height_per_led =
109 height_per_turn_cm /
110 leds_per_turn * 1.3;
111
112
113
114 for (int i = 0; i < num_leds; i++) {
115 float angle = i * angle_per_led;
116 float r = radius + 10 + i * height_per_led;
117
118
119 float x = r * cos(angle);
120 float y = r * sin(angle);
121
122
124 }
125
127
128
131}
HeapVector< T, Allocator > vector