Skip to content

Commit f4f8728

Browse files
committed
311
- Added power-on behavior attribute - Fixed identify command (minimum time is 3 seconds) - Improved log formatting - Refactored code - Fixed manufacturer code - Added forced value updates 15 seconds after joining the network - Increased forced update interval to 10 minutes - Reworked documentation
1 parent 12f1470 commit f4f8728

30 files changed

+5864
-487
lines changed

.github/FUNDING.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# These are supported funding model platforms
2+
3+
github: xyzroe
4+
patreon: # Replace with a single Patreon username
5+
open_collective: # Replace with a single Open Collective username
6+
ko_fi: # Replace with a single Ko-fi username
7+
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8+
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9+
liberapay: # Replace with a single Liberapay username
10+
issuehunt: # Replace with a single IssueHunt username
11+
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
12+
polar: # Replace with a single Polar username
13+
buy_me_a_coffee: xyzroe
14+
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']

.vscode/settings.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,11 @@
4646
"nvs_flash.h": "c",
4747
"task.h": "c",
4848
"esp_log.h": "c",
49-
"string.h": "c"
49+
"string.h": "c",
50+
"esp_zigbee_zcl_on_off_switch_config.h": "c",
51+
"esp_zigbee_zcl_on_off.h": "c",
52+
"esp_zigbee_type.h": "c",
53+
"esp_ota_ops.h": "c"
5054
},
5155
"editor.formatOnSave": true,
5256
"idf.port": "/dev/tty.usbmodemflip_Elevlox1",

CONTRIBUTE.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
### How to Contribute
2+
3+
We welcome contributions to the ZigUSB C6 project! Here’s how you can get involved:
4+
5+
1. **Development Environment**:
6+
- All development is done using Visual Studio Code (VSCode) with the ESP-IDF extension.
7+
- Ensure you have the ESP-IDF environment set up correctly. You can follow the [ESP-IDF setup guide](https://docs.espressif.com/projects/esp-idf/en/latest/esp32/get-started/index.html) for detailed instructions.
8+
9+
2. **Cloning the Repository**:
10+
- Clone the repository to your local machine using:
11+
```sh
12+
git clone https://github.com/xyzroe/ZigUSB_C6.git
13+
cd ZigUSB_C6
14+
```
15+
16+
3. **Building the Firmware**:
17+
- The firmware is automatically built on GitHub after each commit using the `commit.sh` script.
18+
- To manually build the firmware locally, use the following commands:
19+
```sh
20+
./commit.sh
21+
```
22+
23+
4. **Submitting Changes**:
24+
- Create a new branch for your feature or bug fix:
25+
```sh
26+
git checkout -b feature-name
27+
```
28+
- Make your changes and commit them with a descriptive message:
29+
```sh
30+
git commit -m "Description of your changes"
31+
```
32+
- Push your changes to your forked repository:
33+
```sh
34+
git push origin feature-name
35+
```
36+
- Open a pull request on GitHub, describing the changes you have made and why they should be merged.
37+
38+
5. **Code Reviews**:
39+
- All contributions will be reviewed by the maintainers. Please be responsive to feedback and make any necessary changes.
40+
41+
By following these steps, you can help improve the ZigUSB C6 project and contribute to its success. Thank you for your support!

LICENSE.md

Lines changed: 439 additions & 0 deletions
Large diffs are not rendered by default.

README.md

Lines changed: 3 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,51 +1,6 @@
1-
# ZigUSB C6
1+
# ZigUSB_C6
22

3-
The ZigUSB C6 project is an innovative solution designed to enhance the control and monitoring of USB-powered devices through Zigbee communication. This project aims to provide a seamless integration for smart home enthusiasts and professionals alike, enabling remote control, automation, and monitoring of USB devices in a Zigbee-enabled ecosystem.
3+
### Go to [xyzroe.cc/ZigUSB_C6](https://xyzroe.cc/ZigUSB_C6)
44

5-
## Key Features
65

7-
- **USB Power Control**: Remotely manage the power supply to USB devices, allowing for energy savings and enhanced device management.
8-
- **Zigbee Integration**: Fully compatible with Zigbee networks, facilitating easy integration into existing smart home setups.
9-
- **OTA Updates**: Support for Over-The-Air (OTA) firmware updates, ensuring the device remains up-to-date with the latest features and security enhancements.
10-
11-
## Project Goals
12-
13-
ZigUSB C6 was created with the vision of making smart home automation more accessible and versatile. By providing a bridge between USB devices and Zigbee networks, it opens up new possibilities for device automation and control. Whether you're looking to remotely manage lighting, charge devices on a schedule, or integrate USB devices into complex automation routines, ZigUSB C6 offers the flexibility and reliability needed for modern smart homes.
14-
15-
Stay tuned for updates as we continue to expand the capabilities of ZigUSB C6, and feel free to contribute to the project or suggest new features through our GitHub repository.
16-
17-
## OTA
18-
19-
### homed
20-
21-
1. Put firmware update (.*0ta) file next to config file
22-
2. Run MQTT command on topic homed/command/zigbee
23-
```
24-
{
25-
"action": "otaUpgrade",
26-
"device": "IEEE_OF_DEVICE",
27-
"endpointId": 1,
28-
"fileName": "/config/ZigUSB_C6.ota"
29-
}
30-
```
31-
3. Check update process via log files
32-
33-
### zigbee2mqtt
34-
35-
1. Put firmware update (.*0ta) file next to config file
36-
2. Create `index.json` file:
37-
```
38-
[
39-
{
40-
"url": "ZigUSB_C6.ota",
41-
"force": true
42-
}
43-
]
44-
```
45-
3. Add config option to you zigbee2mqtt configuration.yaml file
46-
```
47-
ota:
48-
zigbee_ota_override_index_location: index.json
49-
```
50-
4. Open OTA tab in z2m and click check update next to your device.
51-
5. Check update process via web UI
6+
<div align="center"><a rel="license" href="http://creativecommons.org/licenses/by-nc-sa/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by-nc-sa/4.0/88x31.png" /></a><br />This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by-nc-sa/4.0/">Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License</a></div>

_config.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
title: ZigUSB_C6
2+
description: Zigbee USB power monitor and switch based on ESP32 C6
3+
4+
5+
avatar: https://avatars.githubusercontent.com/u/6440415?v=4
6+
favicon: https://xyzroe.cc/favicon.ico
7+
url: "https://xyzroe.cc"
8+
remote_theme: sylhare/Type-on-Strap
9+
cookie_consent: true
10+
google_analytics: G-5JP6L4L4DL
11+
color_theme: auto
12+
footer_text: '<a rel="xyzroe" href="http://xyzroe.cc">xyzroe</a> © 2022-2024<br /><a rel="license" href="http://creativecommons.org/licenses/by-nc-sa/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by-nc-sa/4.0/88x31.png" /></a>'
13+
plugins:
14+
- jekyll-remote-theme

_data/menu.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
- xyzroe-blog:
2+
title: "xyzroe's blog"
3+
url: https://xyzroe.cc
4+
position: 1
5+
- git-hub-repo:
6+
title: "GitHub Repo"
7+
url: https://github.com/xyzroe/ZigUSB_C6
8+
position: 2

commit.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,9 @@
11

2-
- Update build workflow to use ESP-IDF 5.3.1
2+
- Added power-on behavior attribute
3+
- Fixed identify command (minimum time is 3 seconds)
4+
- Improved log formatting
5+
- Refactored code
6+
- Fixed manufacturer code
7+
- Added forced value updates 15 seconds after joining the network
8+
- Increased forced update interval to 10 minutes
9+
- Reworked documentation

external_converter/ZigUSB_C6.js

Lines changed: 156 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

hardware/BOM.csv

3.66 KB
Binary file not shown.

0 commit comments

Comments
 (0)