DIY Cosmostreamer For Pocket Osmo

How To Assemble and Configure

Cosmostreamer for DJI Pocket Osmo - Assembling instruction

You can assemble it for free, but you have to buy a license! Go here


Required list

  • Raspberry Pi 3 A+
  • MicroSD card (4Gb min)
  • Custom USB cable (see chapter USB connection)


Basic assembling

1. Download ZIP-archive with microSD card image, here is direct link

2. Extract .img file from downloaded ZIP archive

3. Write .img file to microSD card. Use Win32DiskImager application, or any other, that can write images

3.1 If you already has license key - you can install it on microSD card (how to)

4. Insert microSD card into Raspberry Pi

6. If you have a monitor or TV with HDMI input - plug it to Raspberry Pi.

7. Ok, basic assembly is done. Now power on Raspberry Pi, it must start booting.

8. After boot ended HDMI will show something like this:

"License key file not found" message means license key is absent on microSD. In the bottom left corner message contains Raspberry Pi serial number and Cosmostreamer Pocket application version. DJI Pocket Osmo connection not worked without license key.


License key

For full Cosmostreamer functionality license key is needed. It is a small string stored in file /boot/license.txt on microSD

At the current time there is no automatic key retrieve system. So you need to send e-mail to [email protected]. Please, specify a serial key of you Raspberry Pi (see on HDMI on bottom-left corner) and your PayPal account in this e-mail. I will issue a bill for payment and after payment i will send you a license key for Cosmostreamer Pocket on your Raspberry Pi.

The license key is unique for each Raspberry Pi!

Options for installing a license key

  • Use a CosmoViewer application for Windows.
  • Use a web-interface.
  • Insert microSD with written image into PC/laptop card reader. Operating system will detect a card. If your operating system is Windows - disk with label "boot" will be found. Just copy license.txt from e-mail answer on this disk.


Software update

When i fixing bugs or adding some features to Cosmostreamer Pocket application, i make a special file for update. You not needed to rewrite microSD card, you can just install update file. It is possible from CosmoViewer for Windows application, or from a web interface.

You need to download update file. Direct link: cosmostreamer-pocket.tar.gz. Change log and old versions here.

For update from Windows app:

1. Start a CosmoViewer for Windows

2. Right mouse click on window and select "Box settings" item in menu

3. Open tab "Info"

4. Click "Select file" button near of "Firmware upgrade" label

5. Select downloaded file cosmostreamer-pocket.tar.gz

6. Click "Upload" button. Update file will be send to a Raspberry Pi, after this update begins. After finish, Raspberry Pi will automatically reboot.

For update from web interface:

1. Open web interface:

2. Click gears icon in bottom right corner

3. Open menu item "Info"

3. Click "select file" button. Select downloaded file cosmostreamer-pocket.tar.gz

6. Click "Upload" button. Update file will be send to a Raspberry Pi, after this update begins. After finish, Raspberry Pi will automatically reboot.


USB connection

Pocket Osmo has two USB-C ports - on the side and on the bottom. Each of them can be used for connection, but needed a different types of cable because side connector is Male, but the bottom connector is Female. But each connector must be connected with OTG cable, otherwise Pocket Osmo will be connected as a usual USB drive. But we want to control a Pocket Osmo, not just download a files.

That's why we have to make a custom cable, because i not found a ready cables nowhere in sale, it is a non-standard cable.

Side connector

This connector is used for normal smartphone connection. It is good to use this connector because bottom connector is stands free for external power.

For this connector use we need a cable with USB-C Female connector on one side and USB 2.0 Type A (standard USB connector) - on another side.

I found a USB-C microphone adapter with USB-C Female connector

There is a nice solder points for 3 USB lanes labeled "D+" "D-" and "Gnd". So, we need to take usual USB cable with USB 2.0 Type A connector, cut it and solder this 3 lanes.

  • Black (or blue) wire - Gnd (Ground)
  • Green wire - D+
  • White wire - D-

All done, custom USB-C cable for DJI Pocket Osmo is ready to use! Cable might be a up to 1-2 meters length. Maybe more, i not tested a very long cable yet.

P.S. If connect also a Red wire in USB cable to Vcc pin on connector - Raspberry Pi can be powered by Pocket Osmo via this cable. But the current is not enought, so it can be worked only when RPI internal Wi-Fi is disabled and no additional power consumers (RC receiver, for example).

Bottom connector

This connector usually used for PC connection with standard USB-C Male - USB 2.0 Type A cable (this cable is shipped with a DJI Pocket Osmo), to charge Pocket Osmo and download media files. But also it can be used for smartphone connection with USB-C to USB-C cable. Also it can be used for Cosmostreamer connection, but need to make a custom cable.

First way: take USB-C to USB-C cable and cut. Then solder gree, white and black wires to the same in standard USB 2.0 Type A cable, like cable for the side connector. But i have no USB-C to USB-C cable yet, so i can't make a photos for this.

Second way: take a standard USB-C OTG micro USB adapter and insert into Pocket Osmo bottom connector. (A this one, for example)

Now a dual-sided USB 2.0 Type A cable needed. I made it from two USB 2.0 cables, just solder gree, white and black wires like in cable for side connector.

Last step - just connect this cable to Raspberry Pi USB port and to OTG adapter.

IMPORTANT: if bottom connector used, the side connector must be removed or connected like on photo!

Done! Now Pocket Osmo is connected to Cosmostreamer!


RC receivers connection


One or two RC receivers can be connected at the same time. RC1 can be PWM or PPM. RC2 can be PPM or Sbus. RC mode (PWM, PPM, Sbus) can be switched in web-admin page or in Windows application


For PWM doesn't matter channels connection order. Any hardware channel can be mapped into any function in a web-admin page or in application

At least 3 channels must be connected! Maximum 8 channels supported.




RC receiver SBus output connected to Raspberry Pi UART RX (GPIO15).

Important note: SBus output must be uninverted. But standard SBus output is always inverted, so variants available:


RC configuring

Example for Taranis X9D Plus with X8R receiver

For application know which min, max and center value for channel - need to move all channels (sticks, sliders, triggers) to min, max and center positions. For 2-pos triggers - no center position needed. After that need to move PAN/TILT stick to bottom-left position and QUICKLY release it to center. It means calibration is done and software need to get center positions for all channels. After this step calibration is done and RC is active.




Config file

Cosmostreamer settings saved in file /boot/cosmostreamer.conf. It is a usual text file, which can be edited. You can insert microSD into card-reader and edit this file. Also settings can be changed from Cosmostreamer for Windows.

Config parameters description

Parameter names may be changed in a newer firmware versions
Parameter Description
hdmi_enabled=1 Use HDMI output or TV-out
1 - show video and info via HDMI
0 - show video and info via TV-out
disable_video_stream=0 Do not send video stream to viewer application
1 - do not send 0 - send
video_hflip=0 Horizontal flip video 1 - flip 0 - don't flip
video_vflip=0 Vertical flip video 1 - flip 0 - don't flip
rc_input_enabled=0 0 - do not use RC receiver
1 - use RC receiver
rc_input_mode=mode pwm - PWM mode
ppm - PPM mode
rc2_input_mode=mode sbus - SBus mode
ppm - PPM mode
rc_input_map= RC channels mapping
rc_input_speed_pan=100 Pan speed for RC receiver. From 0% to 100%.
rc_input_speed_tilt=100 Tilt speed for RC receiver. From 0% to 100%.
rc_input_speed_dutch=100 Dutch speed for RC receiver. From 0% to 100%.
rc_input_inverse_pan=0 Inverse pan 1 - inverse 0 - normal
rc_input_inverse_tilt=0 Inverse tilt 1 - inverse 0 - normal
rc_input_inverse_dutch=0 Inverse dutch 1 - inverse 0 - normal
rc_input_exp=1 Use exponential for RC 1 - exponential 0 - normal
ap_iface=wifi0 For internal Raspberry Pi 3's Wi-Fi.
wifi0 - Use Raspberry Pi internal Wi-Fi as an access point
empty - don't use
ap_ssid="Cosmostreamer" For internal Raspberry Pi 3's Wi-Fi.
Network SSID for Wi-Fi access point
ap_psk="1234512345" For internal Raspberry Pi 3's Wi-Fi.
Password for Wi-Fi access point
ap_mode=2 For internal Raspberry Pi 3's Wi-Fi.
Wi-Fi Access Point mode. 2 - 2.4GHz, 5 - 5GHz
ap_country=00 For internal Raspberry Pi 3's Wi-Fi.
Wi-Fi Access Point country code. 00, CN, US
ap_channel=7 For internal Raspberry Pi 3's Wi-Fi.
Channel number for access point
wifi_iface=wifi0 For internal Raspberry Pi 3's Wi-Fi.
wifi0 - Use Raspberry Pi internal Wi-Fi as a client for Wi-Fi network
empty - don't use
wifi_ssid="wifi-ssid" For internal Raspberry Pi 3's Wi-Fi.
Wi-Fi network name (SSID) for connecting to
wifi_psk="wifi-pass" For internal Raspberry Pi 3's Wi-Fi.
Wi-Fi network password for connecting to
osd_enabled=1 1 - show OSD on HDMI out
0 - do not show
osd_border_width=0 Set the width of left and right black borders below telemetry on HDMI
osd_border_height=50 Set the height of top and bottom black borders below telemetry on HDMI
osd_top_offset=20 Set the vertical top offset 20 pixels for top-sided text labels on HDMI
osd_bottom_offset=20 Set the vertical bottom offset 20 pixels for bottom-sided text labels on HDMI
internal_camera_enabled=0 Enable RPI internal camera output as course camera
0 - disable
1 - enable
internal_camera_fullscreen=0 Enable RPI internal camera fullscreen output
0 - disable
1 - enable


Network access

If your Raspberry Pi configured as a Wi-Fi access point (by default) - you can connect to it and open url in browser http://my.cosmostreamer.com or

Wi-Fi network name (SSID) - "cosmostreamer". Default password - 1234512345

In other case, you need to enter your Raspberry Pi' ip in browser. For example,

If you using a Mac, Ipad or Iphone (or Windows with iTunes installed) - you can open web interface by the link http://cosmostreamer.local

But most simple way - just run CosmoViewer application (only for Windows) and it will auto discover your Cosmostreamer box, but only if your PC connected to the same Wi-Fi network.