SMF - Just Installed!

Main Menu

Arduino basics

Started by charliesays, January 05, 2015, 04:29:01 PM

Previous topic - Next topic


General question on hacking - looks like there's quite a lot of resources for learning Arduino coding, any advice or pointers on getting started where it would be relevant to the Atmegatron? I've never used C or Arduino before but had some experience with SQL etc...


There's probably 2 approaches if you don't know any C.
1)  Work from the ground up. 
Buy an Arduino Uno kit (e.g. ) and then start to work through the examples, starting with Blink
As you get more and more use to Arduino and C, more and more of the Atmegatron projects will make sense.
This page is vital for understanding the basic C functions: ]].

2)  Reverse engineer the current Atmegatron projects. 
Start with simple things, e.g.  goto Waveforms tab and replace a waveform with your own.  They must be 32 samples long and only contain numbers from -128 to 127.
Then have a go at writing your own functions.  If you look at a simple function like Amplitude_Process (in Ampltiude tab), you'll see that the basic structure is:
Cycle through all 32 samples
Get the sample using: Wave_Get_Process(i)
manipulate sample
Return it using: Wave_Let_Process(i)
Then add your new function to Wave_Process() in Waveforms tab
If it has a parameter controlled by a control, do this in the Hardware tab.  Hardware_Let_Ctrl() for the knobs and Hardware_Adjust_Value() for the function/value dials.

You could try doing both methods 1 and 2 together as well!
Once you're confident with the programmer you'll probably want to move on to using Atmel Studio 6, rather than the Arduino software, as this makes navigating the code much easier.


Great, thanks for the advice, that's really helpful!