Coder Social home page Coder Social logo

jgibbon / yikes Goto Github PK

View Code? Open in Web Editor NEW
6.0 3.0 4.0 163 KB

yi action camera application for sailfish os

License: GNU General Public License v2.0

QML 89.44% Python 6.25% Shell 0.68% QMake 1.31% JavaScript 2.31%
sailfishos yi-action-camera yi-4k qml python

yikes's Introduction

yikes

yikes-logo yikes is an unofficial, bare-bones Sailfish OS application to interface with Yi Action Cameras. It is primarily targeted towards the Yi 4k Action Camera, but with at least some features working on other models. For example, recording Video or Photos with the Yi Discovery work, as does downloading media from the camera. Other models may or may not work and are generally untested.

yikes is not an official product from or in any way related to Yi Technology.

video mode screen shot photo mode screen shot

Limitations

  • The Yi Action Camera API is not publicly documented, so all features may stop working completely in edge cases
  • Only the "most basic" use case is supported, at all. For example, you will only be able to connect with the camera in "hot spot mode" with the standard IP address.
  • Most camera models are totally untested. You may get in touch with the authors of this application to sponsor other models which might help us to debug them. No promises on actual progress, though. ;)
  • The "Live" mode of newer firmware versions is and will remain unsupported.

Features

Model Modelname Basic connection Viewfinder stream taking Photos recording Videos Media preview read Settings write Settings
Xiaomi Yi Action Camera drawing Needs testing Needs testing Needs testing Needs testing Needs testing Needs testing Needs testing
YI 4K Action Camera drawing YES YES YES YES YES YES YES
YI 4K+ Action Camera drawing Needs testing Needs testing Needs testing Needs testing Needs testing Needs testing Needs testing
YI Lite Action Camera drawing Needs testing Needs testing Needs testing Needs testing Needs testing Needs testing Needs testing
YI Discovery Action Camera drawing YES NO YES YES YES Needs testing YES

Installation

from source

You may clone this repository, open it in the Sailfish OS SDK and deploy it to your device. Keep in mind that you have to pull the python API, as well:

git clone --recurse-submodules https://github.com/jgibbon/yikes.git

packaged

yikes is not ready for general use, yet. For now you can find builds that may or may not be current on Nokius' OBS repository. Other release channels may follow.

Acknowledgements

This is a QML/Python application, using the fabulous PyOtherside for Python/Qt bindings.

It would not be possible to without existing work at Yi4kAPI, which we forked and misused a bit for this.

yikes's People

Contributors

jgi-comspace avatar jgibbon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

yikes's Issues

Yi Action Camera 1 compatibility

As with #15, @clausmichele offered to check if yikes did anything with the first Yi action camera. Thanks so much for the offer!

I hope some of the tests are possible with just one minute of wifi connectivity. You should be able to just leave the application open while restarting the camera/reconnecting to its wifi. :)

A Pre-release is available here:
https://github.com/jgibbon/yikes/releases/tag/0.1-1

Things to test (mostly copy/paste from the release info):

  1. Connection: Manually connect to the camera via wifi. Does the application recognise a connection? (It should hide the "trying to connect" screen and enter the normal interface.)
  2. Does the cameras video stream get shown?
  3. Change between video and photo: Please test if changing the switch (top of the interface) changes the mode on the camera, as well.
  4. Sub modes: There should be buttons on the left side of the interface if the camera advertises them as supported. They should differ between video and photo mode. Are those buttons visible? If so, do they change the mode on the camera, as well?
  5. Shutter: The big button should start a recording/take a photo. Does it?
  6. Options: Enter the camera options via pulley menu. Are there any settings visible? Are any of those advertised as "changeable" (white text, tapping them goes to a sub menu to change them)? Does changing them work?
  7. Existing files: In the main interface, there should be an indicator for existing files on the camera if there are any files on its SD card. Is it there? Does tapping it go to an overview interface for existing files? Do they load?
  8. File transfer: Try to transfer a single file (pulley after tapping on a media entry) to the phone. Does it work? If you have enough space in your home partition: Try downloading all files from the media overview pulley. (Files should land in "Pictures/Yi"). Do "raw" photos get transfered (if the camera supports them)?

If some of the steps do not work, it may be helpful to start the application via ssh and save the terminal output. Beware: There may be a lot of output for the current version. Also, there may be more or less sensitive information in it (like file names on the sd card in your camera).

The command to start it is sailfish-qml yikes (there is no binary as of yet). You'll have to connect via usb because wifi is obviously used by the camera connection.

Again, thank you!

[Yi Discovery] Support file Preview

To make the pictures downloadable for the Discovery a adjusted is needed in

qml/lib/CameraFilePreviewItem.qml:                source: 'http://192.168.42.1/DCIM/100MEDIA/'+src
qml/lib/CameraFilePreviewItem.qml:                source: 'http://192.168.42.1/'+src

Media Files: Latest thumbnail on main view optional

The newest thumbnail should only be downloaded and shown when it's explicitly wanted by the user.
Reason:
Photos don't have thumbnails (on Yi 4k at least) and are possibly huge. This puts avoidable stress on the network and both devices.

set date and time with first connect

It would be really helpful if yikes could set the correct time and date (provided from the phone) on the cam. Currently the cam as a random date and time.

Openrepos release

Hey @jgibbon, just wondering if you plan to release Yikes on openrepos.net. I know it's still missing some features, but could already be useful, and Yi cameras are not outdated yet.

I needed to connect to my Yi 4k yesterday, after a long time not using it. I had to search the official Android app everywhere since it didn't seem to be on the Play store (using Aurora). Finally found it on a dedicated Xiaomi website. Installed it. Connected to the Yi WiFi hotspot. Could not pair with it (adhoc WiFi issue with apks?).

Then I remembered I beta tested Yikes years ago. Downloaded the rpm from here, paired instantly, voilà. I would probably have remembered it earlier if it had been released officially, and I'm sure many users don't know about it.

[Yi Discovery] cam details

product-name: YI Discovery Action Camera

getSettings:

{'support_iso': 'on', 'rec_mode': 'record', 'precise_self_remain_time': '0', 'precise_selftime': '3s', 'sta_ssid': 'YDXJ_sta', 'led_mode': 'on', 'rec_audio_support': 'on', 'iq_video_ev': '0', 'iq_video_wb': 'auto', 'iq_photo_shutter': 'auto', 'timelapse_video_resolution': '3840x2160 20P 16:9', 'stamp_enable': 'on', 'hw_version': 'YDXJ2_V11YB', 'burst_capture_number': '3 p / s', 'photo_sharpness': 'high', 'buzzer_ring': 'off', 'iq_photo_ev': '0', 'support_auto_low_light': 'off', 'support_wb': 'on', 'app_status': 'vf', 'timelapse_video_duration': '6s', 'video_photo_resolution': '3840x2160 20P 16:9', 'video_stamp': 'off', 'wifi_country': 'US', 'restore_wifi': 'on', 'sw_version': 'J22_1.3.32_201804201604', 'product_name': 'YI Discovery Action Camera', 'meter_mode': 'center', 'wifi_password': '1234567890', 'video_resolution': '3840x2160 20P 16:9', 'dewarp_support_status': 'off', 'precise_cont_time': '3s', 'support_sharpness': 'on', 'camera_clock': '2017-01-01 00:23:12', 'restore_factory_settings': 'on', 'sd_card_status': 'insert', 'precise_cont_capturing': 'off', 'video_loop_resolution': '3840x2160 20P 16:9', 'eis_support_status': 'off', 'dev_functions': '8967', 'slow_motion_resolution': '1080P/2X', 'timelapse_video': '0.5', 'wifi_ssid': 'YDXJ_34120f', 'wifi_mode': 'ap', 'system_default_mode': 'last used mode', 'restore_bt': 'on', 'photo_stamp': 'off', 'record_photo_time': '0', 'rc_button_mode': 'mode_shutter', 'iq_photo_wb': 'auto', 'serial_number': 'J22V11xxxxxxxxxxx', 'ev_enable': 'on', 'timelapse_photo_shutter': 'auto', 'iq_video_iso': 'auto', 'iq_eis_enable': 'off', 'video_quality': 'S.Fine', 'capture_mode': 'burst quality', 'precise_self_running': 'off', 'system_mode': 'capture', 'protune': 'off', 'sdcard_need_format': 'no-need', 'video_volume_set': 'on', 'dual_stream_status': 'on', 'video_sharpness': 'high', 'sta_password': '1234567890', 'piv_enable': 'off', 'loop_rec_duration': '5 minutes', 'photo_size': '16M', 'auto_power_off': 'off', 'sta_connect_password': '1234567890', 'screen_auto_lock': 'off', 'iq_photo_iso': 'auto', 'sta_ip': '192.168.43.1', 'video_standard': 'NTSC', 'streaming_status': 'off', 'wifi_country_editable': 'off'}

Yi 2 (4k) compatibility

Quite a while ago, @Kabouik offered to check if yikes did… well, anything with the Yi 2 camera.

I now had the time to fix some small things and prepare a build to check with.
https://github.com/jgibbon/yikes/releases/tag/0.1-1

Things to test (copy/paste from the release info):

  1. Connection: Manually connect to the camera via wifi. Does the application recognise a connection? (It should hide the "trying to connect" screen and enter the normal interface.)
  2. Does the cameras video stream get shown?
  3. Change between video and photo: Please test if changing the switch (top of the interface) changes the mode on the camera, as well.
  4. Sub modes: There should be buttons on the left side of the interface if the camera advertises them as supported. They should differ between video and photo mode. Are those buttons visible? If so, do they change the mode on the camera, as well?
  5. Shutter: The big button should start a recording/take a photo. Does it?
  6. Options: Enter the camera options via pulley menu. Are there any settings visible? Are any of those advertised as "changeable" (white text, tapping them goes to a sub menu to change them)? Does changing them work?
  7. Existing files: In the main interface, there should be an indicator for existing files on the camera if there are any files on its SD card. Is it there? Does tapping it go to an overview interface for existing files? Do they load?
  8. File transfer: Try to transfer a single file (pulley after tapping on a media entry) to the phone. Does it work? If you have enough space in your home partition: Try downloading all files from the media overview pulley. (Files should land in "Pictures/Yi"). Do "raw" photos get transfered (if the camera supports them)?

If some of the steps do not work, it may be helpful to start the application via ssh and save the terminal output. Beware: There may be a lot of output for the current version. Also, there may be more or less sensitive information in it (like file names on the sd card in your camera).

The command to start it is sailfish-qml yikes (there is no binary as of yet).

Thank you!

About page

Make an about page and link to it from a settings pulley.

Media Files: RAW image handling

Handling of RAW files is neither implemented nor tested at this point.

Implementation plan:

  • Implement filter + new attribute in file handling logic (parallel to preview files – RAW files should not be their own entity)
  • Implement global setting to download JPG or RAW if RAW is available. Has to be considered in #4

Media Files: Detail View

"Something" should happen when tapping on an item in the media overview grid.
It may or may not be a swipeable full screen view.

better download management

The current media selection + downloads are (purposefully) really bare bones.
For a wider release this should be made a bit nicer:

  • make media selectable in overview and download only selected
  • download only videos
  • download only photos (raw handling: we could just download all variants)

Main view: Only show supported sub modes

Currently all sub modes (like loop, slowmo for video) are displayed for the selected main mode. We need to check if the camera advertises them as available. If they are not, their buttons should be hidden.

Media Files: Downloads

Currently there's no download function for single or all media files.
Downloads should be started from media overview (long press for single download, pulley for all) and detail view, which to be started in #3

Best case would include checking available disk space & possibility to cancel transfer, but this can follow in other issues.

first readme

create a first readme for interested users on:

  • how to build/install it
  • how to use it/supported cameras
  • how to support development
  • what is used in the background (credit original author)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.