3D Led Cube Controller by Arduino Mega

Hi,

I need your help.
Can i use Arduino mega to control 3D Led Cube 16X16X8? I only have 28 i/o pin Available of arduino board. I want to know if i can use:
8 pins in two 4-16 decoder and 3 pins in one 3-8 decoder to control the cube?

also need to control 2D Servo Cube 8x8, can i use?
6 pins in two 3-8 decoder for select the servo and 1 PWM Pin for signal?

I just need one led and one servo at a time.
what decoder i need?, i need any other component?

thanks,

You can charlieplex the LEDs which will reduce the required number of pins to a minimum (while making the entire matrix a bit unsafe and prone to burn).

For servos you will need to control a precisely times pulse so your decoder needs to be fast enough.

You will need LED drivers, or shift registers. In either case you will find the getting the individual parts is more expensive than getting a single Rainbowduino which can drive many LEDs and also includes an Arduino.

See the Rainbowduino in action below as it drives an RGB LED cube:
[video=youtube;-zgh6amwbM]http://www.youtube.com/watch?v=-zgh6amwbM