Arduino Mega 2560

311 views
Skip to first unread message

p1nh0

unread,
Mar 5, 2013, 11:04:34 AM3/5/13
to mozzi...@googlegroups.com
Hi Sensorium. First of all congratulations with this GREAT project! 

I've started using mozzi some weaks ago. Tested Arduinos Diecimila and Duemilanove (both ATMega168 and 328) and everything worked fine. (The 16KHz squeal was successfully removed with the T-notch and low-pass filter). 

So I moved on to an Arduino Mega 2560, as my code was getting bigger. But I can't upload sketches that include the mozzi library, even mozzi examples give me this same error: 

"Error compiling"
~/Documents/Arduino/libraries/Mozzi/mozzi_rand.cpp: In function 'long int longRandom()':
~/Documents/Arduino/libraries/Mozzi/mozzi_rand.cpp:64: error: 'INTERNAL' was not declared in this scope" 
——————————————————————————————————————————————————
This happens even if mozzi_rand.h is not included in the sketch!...

Can anyone help ?  

Mr Sensorium

unread,
Mar 6, 2013, 1:31:38 AM3/6/13
to mozzi...@googlegroups.com
Hi p1nh0,

I see the 2560 uses INTERNAL1V1 or INTERNAL2V56 instead of INTERNAL as a parameter to analogReference()

Try commenting out the line where it appears in mozzi_rand.cpp for now, till I upload a new version.

Glad the filters worked.  I'm trying some options for better quality output in the next week or two.

TIm

p1nh0

unread,
Mar 6, 2013, 9:06:30 PM3/6/13
to mozzi...@googlegroups.com
Thanks ;) I tried deleting mozzi_rand.cpp and its header file, which worked out fine. 
I'll try your tip if I find rand() necessary to this project. 

Better quality output is always great news ;) 

Cheers 
Reply all
Reply to author
Forward
0 new messages