Skip to content

Commit

Permalink
Modified the root README.MD file heavily - Added images - Created new…
Browse files Browse the repository at this point in the history
… subfolder "documentation" - Changed location for images in the MD - Moved hardware description folders and other to the documentation folder - Modified README.MD in the pre-build-images subfolder - Added photos of Elekstube IPS Gen1 and Gen2 and PunkCyber IPS
  • Loading branch information
Martinius79 committed Nov 18, 2024
1 parent 1aa6b5b commit 2e34849
Show file tree
Hide file tree
Showing 102 changed files with 773 additions and 179 deletions.
31 changes: 24 additions & 7 deletions EleksTubeHAX_pio/src/_USER_DEFINES - empty.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,30 @@
#define GEOLOCATION_API_KEY "__enter_your_api_key_here__"

// ************* MQTT config *************
// #define MQTT_ENABLED // enable after creating an account, setting up the Thermostat device on www.smartnest.cz and filling in all the data below:
// #define MQTT_HOME_ASSISTANT // enable if you want Home Assistant support
// #define MQTT_HOME_ASSISTANT_DISCOVERY
// #define MQTT_HOME_ASSISTANT_DISCOVERY_DEVICE_MANUFACTURER "EleksMaker"
// #define MQTT_HOME_ASSISTANT_DISCOVERY_DEVICE_MODEL "Elekstube IPS PR2"
// #define MQTT_HOME_ASSISTANT_DISCOVERY_SW_VERSION "0.8 Home Assistant Edition"
// #define MQTT_HOME_ASSISTANT_DISCOVERY_HW_VERSION "2.3.04"
// #define MQTT_ENABLED // enable general MQTT support

// --- MQTT Home Assistant settings ---
// You will either need a local MQTT broker to use MQTT with Home Assistant (e.g. Mosquitto) or use an internet-based broker with Home Assistant support.
// If not done already, you can set up a local one easily via an Add-On in HA. See: https://www.home-assistant.io/integrations/mqtt/
// Enter the credential data into the MQTT broker settings section below accordingly.

// #define MQTT_HOME_ASSISTANT // Uncomment if you want Home Assistant (HA) support (MQTT_ENABLED must be also enabled)
// all following MQTT_HOME_ASSISTANT_* settings require MQTT_HOME_ASSISTANT to be enabled
// #define MQTT_HOME_ASSISTANT_DISCOVERY // Uncomment if you want HA auto-discovery
// #define MQTT_HOME_ASSISTANT_DISCOVERY_DEVICE_MANUFACTURER "EleksMaker" // Name of the manufacturer shown in HA
// #define MQTT_HOME_ASSISTANT_DISCOVERY_DEVICE_MODEL "Elekstube IPS" // Name of the model shown in HA
// #define MQTT_HOME_ASSISTANT_DISCOVERY_SW_VERSION "1.0 Home Assistant Edition" // Firmware version shown in HA
// #define MQTT_HOME_ASSISTANT_DISCOVERY_HW_VERSION "2.3.04" // Hardware version shown in HA

// --- MQTT broker settings ---
// NOTE: If Home Assistant is not enabled, the MQTT support is very limited in the moment!
// You can still use MQTT to control the clock, but only via direct sent MQTT messages, sent from a MQTT client like MQTT Explorer or similar.
// The actual pure MQTT implementation is "emulating" a temperature sensor, so you can use "set temperature" commands to control the clock.
// This is a workaround to have a basic MQTT support.
// For pure MQTT support you can either use any internet-based MQTT broker (i.e. smartnest.cz or HiveMQ) or a local one (i.e. Mosquitto).
// If you choose an internet based one, you will need to create an account, (maybe setting up the device there) and filling in the data below then.
// If you choose a local one, you will need to set up the broker on your local network and fill in the data below.

#define MQTT_BROKER "smartnest.cz" // Broker host
#define MQTT_PORT 1883 // Broker port
#define MQTT_USERNAME "__enter_your_username_here__" // Username from Smartnest
Expand Down
5 changes: 0 additions & 5 deletions Hardware modification/README.md

This file was deleted.

Binary file removed Photos/PunkCyber_ips_clock.jpg
Binary file not shown.
804 changes: 662 additions & 142 deletions README.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion TO-DO.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
- MQTT transmissions in a single block.
- Temperature sensor readout in a single block.
- Limit IP Geolocation to every Sunday (copy code from the fork)
- Add static zime zone data if IP Geo is disabled (copy code from the fork)
- Add static time zone data if IP Geo is disabled (copy code from the fork)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
File renamed without changes
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#### PunkCyber IPS clock: No CH340 chip soldered on PCB of newer editions

See the "Hardware modifications" section in the `README.md` in the root of this repo.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes
Binary file added documentation/ImagesMD/EleksTube_Gen2_PCB.jpg
File renamed without changes
File renamed without changes
File renamed without changes
Binary file added documentation/ImagesMD/GitHubActionsOverview.png
Binary file added documentation/ImagesMD/HAMQTTBackLightDetails.png
Binary file added documentation/ImagesMD/HAMQTTMainLightDetails.png
Binary file added documentation/ImagesMD/IPSTUBE_H401_PCB.jpg
Binary file added documentation/ImagesMD/IPSTUBE_H402_PCB.jpg
File renamed without changes
Binary file added documentation/ImagesMD/PlatformIOBuild.png
Binary file added documentation/ImagesMD/PlatformIOBuildOutput.png
Binary file added documentation/ImagesMD/PlatformIOUploadOutput.png
File renamed without changes
File renamed without changes.
File renamed without changes.
107 changes: 83 additions & 24 deletions pre-built-firmware/README.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,92 @@
# EleksTubeHAX - An aftermarket custom firmware for the desk clock
![EleksTube IPS clock](/Photos/Clock1.jpg)

Supported hardware models:
### "EleksTube IPS clock", "SI HAI IPS clock", "NovelLife SE clock", "PunkCyber clock", "RGB Glow Tube DIY clock"
## 1. Pre-built firmware files

In this folder you can find pre-built firmware images that you can upload to your clock.
In this folder you can find pre-built firmware image files that you can directly upload/flash to your clock.

Note that these firmwares may have limited functionality.
These firmwares may have limited functionality compared to a self-built firmware, because not all available features are enabled or can be configured.

## Enabled functions:
- WPS connectivity (press WPS button on your router for WiFi setup).
- DEBUG_OUTPUT - it will produce diagnostic messages on the serial port.
- DCORE_DEBUG_LEVEL=5 - it will produce diagnostic messages from the operating system.
- Night time from 22h in the evening to 7h in the morning.
- No geolocation (time zone & DST must be set manually).
- No MQTT (without remote control).
- No thermometer.
- Image files are fixed and can't be changed without development tools.
The image files (clock faces) are fixed and can't be changed without building your own firmware file with the development tools (see README.md)!

### Select appropriate .bin file that fits your hardware and upload it using the `_ESP32 write flash.cmd` file.
Available files:
- original Elekstube clock - `FW_Elekstube_HAX_1.0_original.bin`
- original Elekstube clock Gen2.1 (ESP32 Pico D4 Chip) - `FW_Elekstube_HAX_1.0_Gen2-1.bin`
- SI HAI copy of the clock - `FW_SI_HAI_CLOCK_HAX_1.0.bin`
- NovelLife SE version (non-SE not tested) - `FW_NovelLife_SE_HAX_1.0.bin`
- PunkCyber / RGB Glow tube / PCBway clock - `FW_PunkCyber_Glow_PCBway_HAX_1.0.bin`
### 1.1 Pre-configured functionality

Make sure to edit it and write correct COM port and file name into it before running.
Enabled:

## Save your original firmware using the `_ESP32 save flash 4MB.cmd` before tinkering.
- WiFi connectivity via WPS (While clock is in boot phase, press WPS button on your router for WiFi setup).
- Night time dimming enabled - from 22:00h (10 pm) in the evening to 07:00h (7 am) in the morning.

## There is no warranty of any type.
Disabled:

- IP-based geolocation disabled - time zone & DST must be set manually via the menu.
- MQTT disabled - no 'remote control'. Because of this, also no Home Assistant support!
- Debug Outputs via serial interface is disabled

General:

- 6 different sets of clock faces present. See [data](https://github.com/SmittyHalibut/EleksTubeHAX/tree/main/EleksTubeHAX_pio/data).
- BMP mode active for the given clock faces
- CORE_DEBUG_LEVEL=5 - This produces diagnostic messages from the ESP32 "operating system" in case of an error over the serial interface.

## 2. Backup your original firmware

**Always backup YOUR clock firmware version as first step!**

Save your original firmware using the `_ESP32 save flash 4MB.cmd` by changing the COM port to the number, your clock uses.

Rename and store the `backup1.bin` on a save location.

See also the section "Backup first" and following in the `README.MD` file in the root.

## 3. Available image files

In this folder (```pre-build-firmwares```) you will find the flashable files.
They are updated from time to time in the repository, so version number may vary.

| clock model | firmware image file |
|--|--|
| EleksTube IPS - Orginal Version | `FW_Elekstube_HAX_1.0_original.bin` |
| EleksTube IPS - Gen2 models | `FW_Elekstube_HAX_1.0_Gen2-1.bin` |
| SI HAI IPS | `FW_SI_HAI_CLOCK_HAX_1.0.bin` |
| NovelLife SE version | `FW_NovelLife_SE_HAX_1.0.bin` |
| PunkCyber/RGB Glow Tube DIY | `FW_PunkCyber_Glow_PCBway_HAX_1.0.bin` |

Note: All "Original" EleksTube clocks, sold after July 2022 are "Gen2" versions. See [Note on EleksTube website](https://elekstube.com/blogs/news/instructions-on-elekstube-clock-for-gen2-systems). But always check the PCB version of your clock!

## 4. Write the EleksTubeHAX firmware file

- Choose the right pre-built firmware file for your clock.
- Edit the file `_ESP32 write flash.cmd` with an editor.
- Write the correct COM port of your clock.
- Write the correct firmware file name for your clock.
- Run the CMD file.

The CMD file should look like this:

```esptool --port COM5 --baud 921600 write_flash --erase-all 0x0000 FW_Elekstube_HAX_1.0_Gen2-1.bin```

Note: Most clocks will go into to the "download mode" automatically when esptool is trying to write to it.
Some clocks needs a button pressed while the powering phase (plugging the USB cable) to enter this mode.

## 5. Download the newest firmware files

Everytime a commit is done to the main branch of this repo, a GitHub action is triggered and a workflow run builds all firmware files.

All workflow runs of the GutHub action can be found under [EleksTubeHAX generate firmware files]("https://github.com/SmittyHalibut/EleksTubeHAX/actions/workflows/pio-build-and-publish-all-firmware-files.yml")

Should look like:

![GitHub Actions Overview](../documentation/ImagesMD/GitHubActionsOverview.png)

The first entry is always the newest.

If you click on the workflow run, you will be able to donwload either all firmwares at once, by downloading the `all-firmware-vX.X.X`, or the file for your clock seperately.

![GitHub Actions Artifact view](../documentation/ImagesMD/GitHubActionsArtifactView.png)

The downloaded firmware file can be flashed to the clock modifing the existing CMD file or using the esptool directly.

## 6. There is no warranty of any type

Use at your own risk!

If you mess-up your clock, it's only your fault!

0 comments on commit 2e34849

Please sign in to comment.