Posted on Leave a comment

How To Use MewPro and Its Application

We will show you how to use a first time MewPro. Basics to control GoPro camera will be explained. No external sensors involved (Maybe in following posts, we can show you some examples of sensor usages).


Prerequisites

In order to use MewPro as a GoPro controller you need the following hardwares:

GoPro Hero 3+ Black
Neither previous editions nor Hero 3+ Silver work with MewPro. Hero 4 Black will be expectedly supported but we don’t promise this. (Update: Hero 4 Black/Silver are supported by MewPro 2/Cable. Please refer recent posts for them.)
MewPro
SMD parts, Herobus connector and Arduino Pro Mini 3.3V 8MHz are soldered. If you want to use a higher performance microcontroller then Teensy 3.1 and GR-KURUMI are supported by the MewPro application.
Arduino Pro Mini Temporary FTDI Header
If you buy a MewPro from our shop the header is included in the package.
Sparkfun FTDI Basic Breakout – 3.3V and USB cable
Use 3.3V version of the breakout board. Any compatible board should work.


Remark: If you use Teensy 3.1 in the place of Arduino Pro Mini then you don’t need Temporary FTDI Header and/or Sparkfun FTDI board; and please consider to buy our Arduino Pro Mini / Teensy 3.1 Conversion Board.

Teensy Warning: If you use Teensy 3.1 with MewPro, please cut the PCB pattern between VUSB and VIN (On the a-lot-of-pad-side of Teensy board there is the special slit between pads to do so). Because MewPro uses RAW input from GoPro battery (about 3.8V). So if you connect VUSB (5V) to MewPro’s RAW then GoPro’s battery pin will become 5V. This will destroy your GoPro.

Softwares:

Arduino IDE 1.5.7 beta or newer
Older versions of Arduino IDE have bugs in Wire library that cause MewPro unusable.
MewPro Application
This is an open source software (MIT license). You can modify and distribute it as you like.


Remark: If you use Teensy 3.1 or GR-KURUMI, you must be a wizard or witch so maybe you know what is required a kind of softwares instead of above mentioned Arduino IDE.


Connection

Install Arduino IDE on your PC and launch it. In Arduino IDE [File]→[Open...]→ then open MewPro.ino.

Remark: MewPro.ino contains the following files as tabs; a_Queue.ino, b_TimeAlarms.ino, c_I2C.ino, d_BacpacCommands.ino, e_Shutter.ino, f_Switch.ino,g_IRremote.ino, h_LightSensor.ino, i_PIRsensor.ino, and j_VideoMotionDetect.ino. If you like to see what will be happen inside of your Arduino Pro Mini you could read any of them.

Connect MewPro to your PC w/ FTDI board and the temporary header.
IMG_5942
Then connect them to GoPro Hero 3+ Black.
IMG_5943

In Arduino IDE application, select [Tools]→[Board]→[Arduino Pro or Pro Mini], [Tools]→[Processor]→[ATmega328 (3.3V, 8MHz)], and [Tools]→[Port]→[(the port where you connected the FTDI cable)]. Then “Verify” the MewPro sketch and “Upload” it to Arduino Pro Mini board.

Remark: If you are using Teensy 3.1 c_I2C.ino will fail to compile. Just change the first four lines to
#if defined(__MK20DX256__) // Teensy 3.1
#include <i2c_t3.h> // *** please comment out this line if __MK20DX256__ is not defined ***
#else // Arduino Pro Mini
//#include <Wire.h> // *** please comment out this line if __MK20DX256__ is defined ***


Control GoPro

Open “Serial Monitor” in Arduino IDE window (click the the top right “magnifier” icon). Set [57600 baud] using the bottom right pulldown, [Newline] the middle pulldown, [Autoscroll] the left box checked.

11.57
Type ‘@‘ (one letter representing at sign) in the input area of Serial Monitor, and hit return key.

12.00
The message “camera power on” is shown and your GoPro Hero 3+ Black turned its power on.

The messages on “Serial Monitor” shows communication details between Arduino and GoPro. If this is the first time to connect your MewPro to GoPro then repeated erroneous “>01 08” is shown again and again. This is because the I²C EEPROM on the MewPro board is not properly initialized yet. So let’s type another one letter command ‘!’ (exclamation mark) in the input area of Serial Monitor, and hit return key.

12.001

Then other messages come from GoPro.
12.002
“role change” means that the role as a BacPac™ has been changed. This time the role is “master” (to understand the roles and modes of Dual Hero BacPac™ please refer our previous post).

In “master” role, we can’t push the shutter botton. But we can get composite video signal out of Herobus connector by using “VO1” command, which “master” MewPro automatically send to GoPro as shown in messages of above screenshot.

Next change the role to “slave”. To do this, type the one letter command ‘!’ again. The command ‘!’ toggles the role between “master” and “slave”.
12.003
12.010

You can see in the above screenshot various information is obtained from GoPro camera.

Now I²C EEPROM on your MewPro board is properly set to “slave” role. In the role we can push the shutter button of GoPro as usual. So we recommend using MewPro in this role.

Now we almost do every thing on GoPro from Arduino. Details of I²C commands are listed in our earlier post.

Try typing “SY1”. Then “SY0”. (Start recording! Stop recording!!)

If you finished type “PW0”. (This should power off your GoPro.)

Enjoy!


Final Note: “SY1” command fails if the mode is different to the mode when GoPro is power on. That is if you change camera’s mode manually by using mode/power button of the camera body or “CM” (SET_CAMERA_MODE) command, then “SY” command will fail. This is due to GoPro firmware so please don’t blame MewPro. In order to workaround this restriction, use “DM” (SET_CAMERA_DEFAULT_MODE) command and set your camera to desired mode and “PW0” (power off). After this, try ‘@‘ (power on) and “SY1“.

Posted on Leave a comment

GoPro Hero 3+ Black slave mode

GoPro Hero 3+ Black can be controlled by Dual Hero BacPac™. In this post the protocol among two Blacks and the BacPac™, which is called “Smarty”, is roughly explained.

There are three devices involved:

  1. Master Camera
  2. Slave Camera
  3. Smarty

Role of a camera, Master or Slave is determined by the camera reading the first byte of I²C EEPROM located inside of Dual Hero BacPac™ connected; if the content of address 0 is 4 or 5 then the camera will play Master or Slave respectively.

After a camera knew its future role, it sends “vs” (GET_BACPAC_PROTOCOL_VERSION) command to Smarty (Please refer the other post about the detail of I²C commands).

Then Smarty respond to both “vs”s as OKs then each camera enters to each role; Master send the configuration of the camera (mode, pixels, upside-down and so on) to Smarty; and Smarty send the heard info to Slave; …

It is not so obvious that Master or Slave has two modes:

  1. 3d_SYNC_MASTER: Route DSP sync signals to CCD sensor
  2. 3d_SYNC_SLAVE: Route Dual Hero BacPac™ generated sync signals to CCD sensor

Just after a Dual Hero BacPac™ has been connected, both Master and Slave camera are in the 3d_SYNC_MASTER mode. But after the negotiation of camera configuration etc. is finished, they both go into the 3d_SYNC_SLAVE mode. This way 3d video is “genlocked” by Smarty (NOT by Master).


You are now understand the basics. Then what we can do? Maybe almost all of us don’t need “genlock”. Because many of us have only ONE GoPro Hero 3+ Black, don’t we?

MewPro don’t choose the way of generating a “genlock” signal. Instead MewPro interfere the negotiation of two cameras and leave both of them in the 3d_SYNC_MASTER state. So we don’t worry about the precision of a “genlock” signal but we can easily control all of the functionalities of GoPro Hero 3+ Black as if MewPro were a Smarty.


Tomorrow I’ll post some demonstrations or screenshots using MewPro and Arduino Pro Mini.

Posted on Leave a comment

Herobus pinout of GoPro Hero 3+ Black

There is a receptacle on the back of newer GoPro cameras.

The model number of the receptacle is JAE DD1R030HA1R1300 or JAE DD1R030JA7R1300. The receptacle mates male connectors DD1B030HA1R500, DD1B030VA1, and DD1P030MA1. (cf. JAE documentations)

The connectors look very similar ones that are used by Apple’s iPods or older iPhones, but they have different keys and can’t pair.

MewPro uses a compatible connector to DD1P030MA1 and, for some technical reasons, the footprint on the PCB is designed for non-genuine one. You can buy this non-genuine but compatible connector from Ridax store where the product name is “DOCK CONNECTOR FOR PCB HOLE MOUNTING FOR SANDISK/GOPRO”, or you can order us a variation of MewPro that already includes a Herobus connector soldered.

Below is a list of pins on the connector.

Note: Pin numbering is in the reverse order to, for example, Ridax’s breakout PCB or some GoPro forum posts. According to JAE’s documents they are wrong and the reverse order to them IS correct. Thus from now on our site and our products shall adopt the JAE’s pin order.