tag:blogger.com,1999:blog-2322291048042453151.post2701221012706847345..comments2022-03-30T19:26:28.939-07:00Comments on Hands On - Arduino: Project 12 - Piezo Sounder Melody PlayerJames Floyd Kelly (Jim)http://www.blogger.com/profile/13876934942928389738noreply@blogger.comBlogger3125tag:blogger.com,1999:blog-2322291048042453151.post-64187407515548184072011-12-31T14:53:35.602-08:002011-12-31T14:53:35.602-08:00I needl Help ! I get errors on this code. First o...I needl Help ! I get errors on this code. First one: for (int x=0; x tone(8, tune[x]));<br />delay (1500*duration[x]);<br /><br />I guess there is something wrong on the book because I put it just like its written.<br />Thanks,<br />FernandoFernandohttps://www.blogger.com/profile/16835162556532817636noreply@blogger.comtag:blogger.com,1999:blog-2322291048042453151.post-86793980626297580622011-04-13T13:50:31.819-07:002011-04-13T13:50:31.819-07:00This is a mistake in the book. The "sizeof(tu...This is a mistake in the book. The "sizeof(tune)" gives 52 , so the "length" is equal to 26 and not 13.<br />You can check it out, if you put "Serial.print (length)" in the program.Alonhttps://www.blogger.com/profile/07283139303162870175noreply@blogger.comtag:blogger.com,1999:blog-2322291048042453151.post-4905883876676211382011-04-09T11:37:21.069-07:002011-04-09T11:37:21.069-07:00This is a mistake in the book, the "sizeof(tu...This is a mistake in the book, the "sizeof(tune)" gives the value of 52, so the value of "length" is 26 and not 13.<br />You can see it if you use the Serial.print(length) command.Alonhttps://www.blogger.com/profile/07283139303162870175noreply@blogger.com