Introduction: SunPak Brain Transplant

About: I'm a fabricator, Maker, Modder and music lover.

The Sunpak AP-200 is a pan-tilt head that uses a I.R remote to control its functions. it has a automated feature but it is also enabled by the remote. On the device there is really not much there as there is only one button and its only function is to turn the device on.

After many failed attempts to find a replacement remote I decided to try and "hack" the I.R signal/code. I tried to use an arduino script that would send codes and detect if the device had reacted to the signal but that did not work. So i decided to open it up and what i found was what seemed to be a simple device. a single MCU. I then thought to myself, Could i replace it? and so it began.

Step 1: Tool and Materials

We do not need much but we will need the following things.

  • Arduino Leonardo (or any board compatible with Arduino I.D.E)
  • Cables (I used thin stranded wire)
  • Computer PC/Mac with Arduino I.D.E installed
  • Phillips Screw-Driver
  • Soldering Iron / Solder

Step 2: Lets Identify

The Sunpak AP-200 only has 2 screws that hold the case together. they are located next to the tripod mount (see picture above). Once the bottom is removed we will need to remove the "motherboard" from the case.

we can see that the "motherboard" only uses a single MCU. we search for the MCU datasheet as a NEC - 17135A. we search for the datasheet and we can find the pin-outs for this MCU.

Flipping the "motherboard" over we can see the 2 H-bridges. If we take a closer look we can identify them as Toshiba TA-8409S, a quick google search gives us the datasheet we need.

Step 3: Follow the Traces

Since we have identified each chip we are going to be working with we will use our multi-meter with the continuity setting. Placing a probe on pin 1 of the NEC chip (I use the Black probe) we will us the free probe (Red for me) and follow where the trace of pin 1 takes us. Doing this for each pin on the NEC chip we will find which pins control the 2 H-Bridges and other sensors(limit switches and I.R receivers). We must write all of our data down . We will end up with a list . (see picture above)

Step 4: We Need Some Solder

Now that we know what each pin controls, we need to solder a cable to each of the pins that we need.

  • vcc
  • gnd
  • moto-1-enable
  • moto-2-enable
  • limit-up
  • limit-down
  • limit-left
  • limit-right
  • I.R 1/2
  • pwr-LED

Making sure that the solder joint do not get bridged we solder each cable to its proper pin and label each cable as to not get confused later.

Step 5: Getting Everything Connected and Testing

Now here is where the real fun stuff happens. take out your arduino of choice ( I am using a Leonardo). Since we have our cables labeled, this part should be fairly easy. for our testing purposes We will connect the following cables:

• vcc to pin vcc
• gnd to gnd
• moto-1-enable to pin 9
• moto-2-enable to pin 8
• limit-up to pin 3
• limit-down to pin 2
• pwr-LED to pin 13
• Motor - 1/2 enable (this enables power to both motors) to pin 10

Now we need to make an Arduino sketch. I got this code to work. take a look.


// set pin numbers:
const int sw2 = 2; // Down limit
const int sw3 = 3; // Up Limit
const int ledPin = 13; // Pwr L.E.D
const int ic1_2 = 8; // TA8409S IN2
const int ic1_1 = 9; // TA8409S IN1
const int enable = 10; // TA8409S Enable (motor)

boolean sw2State = HIGH; // Down Limit State
boolean sw3State = HIGH; // Up Limit State

void setup() {
// Setting L.E.D and Motor In, Enable pins as an output:
pinMode(ic1_1, OUTPUT);
pinMode(ic1_2, OUTPUT);
pinMode(enable, OUTPUT);
pinMode(ledPin, OUTPUT);
// Setting limit switches pins as inputs
pinMode(sw2, INPUT_PULLUP);
pinMode(sw3, INPUT_PULLUP);
// Enables motor
digitalWrite(enable, 1);
//Starts program down

void loop() {
// reads the state of the limit switches
//Serial.print("Reading SW2 State\n");
sw2State = digitalRead(sw2);
//Serial.print("Reading SW3 State\n");
sw3State = digitalRead(sw3);

if(debounce_sw3(sw3State) == LOW && sw3State == HIGH)
Serial.println("Up Limit Reached\n Going Down\n");
sw3State = LOW;

if(debounce_sw2(sw2State) == LOW && sw2State == HIGH)
Serial.println("Down Limit Reached\n Going Up\n");
sw2State = LOW;

boolean debounce_sw2(boolean state)
boolean stateNow = digitalRead(sw2);
stateNow = digitalRead(sw2);
return stateNow;


boolean debounce_sw3(boolean state)
boolean stateNow = digitalRead(sw3);
stateNow = digitalRead(sw3);
return stateNow;


void up() {
Serial.println("Up started\n");
digitalWrite(ic1_1, LOW);
digitalWrite(ic1_2, HIGH);

void down() {
Serial.println("Down started\n");
digitalWrite(ic1_1, HIGH);
digitalWrite(ic1_2, LOW);

void err() {
digitalWrite(enable, LOW);
digitalWrite(ic1_1, LOW);
digitalWrite(ic1_2, LOW);

Now all we do is compile this test Sketch and we should get the following result. lets take a look at the video.

And that is it. Now we can make any automation sketch we want. we can add the I.R features back simply by coding them in, this is something that i will try to get working. Hope that this was helpful and let me now in the comments.

-Daniel Frausto

Arduino Contest 2016

Participated in the
Arduino Contest 2016