diff projects/basic_analog_output/render.cpp @ 5:09f03ac40fcc

API improvements and cleanups. Now all common audio command-line options can be parsed automatically.
author andrewm
date Sat, 08 Nov 2014 16:16:55 +0100
parents 8a575ba3ab52
children a6beeba3a648
line wrap: on
line diff
--- a/projects/basic_analog_output/render.cpp	Thu Nov 06 19:02:48 2014 +0000
+++ b/projects/basic_analog_output/render.cpp	Sat Nov 08 16:16:55 2014 +0100
@@ -62,7 +62,7 @@
 			if(out > MATRIX_MAX)
 				out = MATRIX_MAX;
 
-			matrixOut[n * 8 + channel] = (uint16_t)out;
+			analogWrite(channel, n, out);
 
 			// Advance by pi/4 (1/8 of a full rotation) for each channel
 			relativePhase += M_PI * 0.25;