Re-purposing the code for a digital potentiometer?

I took a look at the code here: http://arduino.cc/en/Tutorial/SPIDigitalPot

I notice that they use an arduino uno and they said " * CS - to digital pin 10 (SS pin) * SDI - to digital pin 11 (MOSI pin) * CLK - to digital pin 13 (SCK pin)"

I need to use this with an arduino mega, so how would I wire it differently and how would I code it differently? Do I just use the same digital pins at described, or are the SS, MOSI, and SCK pins different on the arduino Mega? Thanks!

try this... http://forum.arduino.cc/index.php?topic=125908.0. Second entry on the Microcontrollers page...

Doc

The equivalent pins on the Mega are

51 (MOSI) 52 (SCK) 53 (SS)

See http://arduino.cc/en/Main/ArduinoBoardMega2560

I have not looked at the link to the code for the Uno but it should just be a matter of substituting the Mega pin numbers for the equivalent Uno ones in the code.

Okay, Thanks! I just want to check though, I do not have to change anything else in the code, do I?

You should only need to change the pin numbers to match the Mega, not the code.