Skip to content

Instantly share code, notes, and snippets.

View psolyca's full-sized avatar

Damien Gaignon psolyca

View GitHub Profile
@psolyca
psolyca / honor_band_4_re.md
Last active April 23, 2024 19:37
Honor Band 4 RE

Introduction

Lots of works have been made to communicate with the Honor Band 3/4 in order to be used with GadgetBridge.
RE is followed in issue 1021 BTW, communication where not complete and the RE was done on BLE LPv2.
A new protocol LPv3 appeared.

Goal

RE the LPv3 BLE protocol and integrate Honor devices in GadgetBridge.

Keys

@psolyca
psolyca / tf101_postmarketos.md
Last active November 19, 2022 17:09
postmarketOS TF101 Asus eepad Transformer
@psolyca
psolyca / Huawei_protocol.lua
Created January 10, 2022 22:31
Wireshark dissector for Huawei band protocol
----------------------------------------
--- Definitions
----------------------------------------
--- Huawei protocol used in Wireshark to dissect packets
--- @class Proto
local huawei_proto = {}
--- @class hpFields
local hpFields = {}
@psolyca
psolyca / RPi3_ALARM_BTLE.md
Last active September 20, 2021 21:03
Raspberry Pi 3 - ArchLinuxARM - BluetoothLE - Huawei LPv2

How-to to install bluetooth and run huawei-lpv2 on the Rapsberry Pi 3B (v1.2).
Read the whole guide before proceeding.

ArchLinux ARM

Installation

Follow this guide to install Arch on a SDCard.

To install it on a USB stick, you need to :

  1. install ArchLinux ARM on a SDCard
  2. install ArchLinux ARM on the stick the same way
@psolyca
psolyca / SPDT_electrodragon.md
Last active May 4, 2020 15:31
Modding Electrodragon SPDT double relay board #nodemcu #esp8266

Some information about Electrodragon SPDT double relay board that is not on the wiki pages

Flashing the board

To be able to flash the board, the serial bitrate should be 9600, 57600 or 115200 baud. btn2 should be push on reset till beginning of flash (blue LED blink on the other side) after it could be released (keep it pushed till the end of flash if trouble).

Access to GPIOs

GPIO4 and GPIO5

On the main pin header, IO4 and IO5 are inverted thus IO4 is GPIO5 of ESP-12F ans IO5 is GPIO4.

@psolyca
psolyca / RollerShutter.md
Last active May 4, 2020 15:31
Roller shutter with Electrodragon SPDT and HLW8012 #nodemcu #esp8266

After modding the Electrodragon SPDT, it is time to use it.

The goal is to make a roller shutter switch. A HLW8012 breakout board (energy meter) made also by Electrodragon will be used as a calibration system to handle percentage opening.

ESPeasy is the firmware of the main board and Domoticz the home automation manager.

Hardware

For security reasons and to avoid both UP and DOWN power lines powered in the same time, one relay is the power relay where as the other one is the direction relay.

Following the modding of the SPDT board:

@psolyca
psolyca / LightsControl.md
Last active May 4, 2020 15:31
Light control with NodeMCU v3 #nodemcu #esp8266

The goal is to control all my lights with Domoticz and my wall switches.

A NodeMCU v3 will be used as the controller, a PCF8574 board to extand I/O, a 4 relays board to switch lights on/off and a mini AC-DC converter.

ESPeasy is the firmware of the main board and Domoticz the home automation manager.

Home configuration

Lights in the home are simple or 3-way switches. By the way, all cables from live, neutral and between switches and lights are gathered in a connecting box as the following: wiring_present

@psolyca
psolyca / video_bitrates_multiplicator_table_live.txt
Last active May 4, 2020 15:31
Video bitrates multiplicator table for live for Yi4k #yi4k
The values in the video bitrate table are stored as 32 bit floating point values :
0x3D4CCCCD #0.05
0x3DCCCCCD #0.1
0x3E19999A #0.15
0x3E4CCCCD #0.2
0x3E800000 #0.25
0x3E99999A #0.3
0x3EB33333 #0.35
0x3ECCCCCD #0.4
@psolyca
psolyca / video_bitrates_base_table_live.txt
Created November 6, 2018 12:58
Video bitrates base table for live for Yi4k #yi4k
0x49742400 #1.00 Mbps
0x49927C00 #1.20 Mbps
0x49989680 #1.25 Mbps
0x49B71B00 #1.50 Mbps
0x49D59F80 #1.75 Mbps
0x49F42400 #2.00 Mbps
@psolyca
psolyca / video_bitrates_addresses_table.md
Last active May 4, 2020 15:30
Video bitrates addresses table for Yi4k #yi4k

This is for the 4k firmware 1.10.9

Res. num. Address NTSC PAL