Skip to content
AWTRIX Flows
Submit flow
MOEX Market shown on an AWTRIX display
Fig. 1 MOEX Market, as Avemer runs it.

MOEX Market

MOEX Market displays prices for Moscow Exchange (MOEX) both stocks and futures.

Specifications
System AWTRIX NG Scripts
Firmware AWTRIX NG
Topic Miscellaneous
Built by Avemer
File 6OxJadW935Wl.ax · 4.4 KB
Icons
Published 10 Aug 2026 · updated 10 Aug 2026

The script is designed to be lightweight and uses the MOEX ISS API to periodically request the current price.

FEATURES

  • Supports Moscow Exchange (MOEX) stocks and futures. You can specify it yourself.
  • Displays the ticker together with the current price
  • Automatic green/red price coloring based on the latest price movement
  • Custom ticker and price colors
  • Adjustable ticker length
  • Adjustable update interval
  • Adjustable spacing between ticker and price
  • Lightweight and suitable for the limited resources of the ULANZI TC001
  • Technically, you can have several such scripts that will rotate each other on the clock display and show data from different tickers.

!!! IMPORTANT NOTE - Data Source & Delay !!!

  • This script uses the free MOEX market data feed to retrieve prices directly on the watch.
  • The free data source has a 15-minute delay, so the displayed price is not real-time. This is a limitation of the free MOEX data access, not of the watch or the script itself.
  • The advantage is that the script runs directly on the watch and does not require Home Assistant, a smart-home server, a PC, or any additional setup. It also would run for everyone and does not require an API token or anything like that.
  • If real-time prices are required, the data source can be replaced with a suitable paid or real-time API, for example:
  1. A paid MOEX market data subscription;
  2. A broker's API;
  3. Another real-time market data provider.
  • In other words, this script prioritizes simplicity and standalone operation over real-time market data.
  • I like the very opportunity to occasionally check the current price of an asset without having to log into a phone or terminal. For more accurate values, I use price notifications in the broker's app.

SETTINGS
In code look for section ====== START OF USER SETTINGS ======
!!! IMPORTANT NOTE - Settings!!!

  • You must specify the asset type. If you specify it incorrectly or do not specify it, the script will not work.
  • TICKER_LETTERS must not exceed the actual length of TICKER.
    For example, if Ticker = "T", set TICKER_LETTERS = 1. Setting it to 2 or higher will cause the script to fail.
    For Ticker = "SBER", you can use any value from 0 to 4. Values 5+ display the full ticker.

1. Market Type
Select the type of instrument:
self.MARKET_TYPE = 0 — MOEX stock
self.MARKET_TYPE = 1 — MOEX futures
Stock examples:
0 → SBER
0 → BSPB
0 → PHOR
Futures examples:
1 → CRU6
1 → SiU6
1 → BRU6

2. Specifying the Ticker
self.TICKER = "CRU6"
Enter the MOEX security ticker.
For stocks:
SBER
T
PHOR
For futures:
CRU6
SiU6
BRU6

3. Adjust Ticker Length
self.TICKER_LETTERS = 2
Controls how many characters of the ticker are displayed:
0 — hide ticker
1 — C
2 — CR
3 — CRU
4 — CRU6
5+ — full ticker
For example:
CRU6 + 2 → CR 123.45
CRU6 + 4 → CRU6 123.45

4. Ticker Name Color
self.TICKER_COLOR = 0xFFFF00
Sets the ticker color using 0xRRGGBB format.
Examples:
0xFFFFFF — White
0xFF0000 — Red
0x00FF00 — Green
0x0000FF — Blue
0xFFFF00 — Yellow
0x00FFFF — Cyan
0xFF00FF — Magenta

5. Price Color Mode
self.PRICE_COLOR_MODE = 2
Controls the price color:
0 — always white
1 — use the custom PRICE_COLOR
2 — automatically use green/red
In automatic mode (Just like it shows in an any broker APP or Terminal):
Green — current price is higher than the previous received price
Red — current price is lower than the previous received price
White — price has not changed
The automatic mode compares the current price with the previous price received by the script, not with the previous day's closing price.

6. Custom Price Color
self.PRICE_COLOR = 0xFFFFFF
Used when:
PRICE_COLOR_MODE = 1
Uses the same 0xRRGGBB color format as the ticker. (See point 4 for examples)

7. Price Update Interval
self.UPDATE_TICKS = 10
Controls how frequently the script requests a new price.
Approximate values:
1 — every ~1 second (can be out of memory on ULANZI TC001)
5 — every ~5 seconds (can be out of memory on ULANZI TC001, but works for me)
10 or more — every ~10 seconds or more (recommended)
Lower values provide more frequent updates but increase CPU, memory and network usage.
For the ULANZI TC001, 10 seconds or more is recommended if you want to minimize resource usage.

8. Text Gap
self.GAP = 2
Controls the distance in pixels between the ticker and the price.
For example:
CR 123.45
The value determines the space between CR and 123.45.

TROUBLESHOOTING
If the script does not work, displays an error, fails to load values, or shows incorrect values (even after accounting for the 15-minute data delay mentioned at the beginning of the description):

  1. Make sure you have selected the correct asset type and saved changes (Ctrl+S) (see Setting 1).
  2. Make sure you have entered the correct ticker symbol and saved changes (Ctrl+S) (see Setting 2).
  3. Check your internet connection.
  4. The watch may be running out of available memory if you have installed many similar or other scripts at the same time. Consider adjusting self.UPDATE_TICKS = to 10 or more so the script will update the data less frequently. Make sure that you saved changes (Ctrl+S) (see Setting 7).
  5. Always consider rebooting the watch. Open the watch's web interface by entering its IP address in your browser, go to System → Maintenance → Reboot, and then press "Sure?". A reboot often resolves temporary glitches, memory-related issues, and other unexpected script behavior.

Vibecoded with ChatGPT, polished by Avemer.

P.S. I wrote this script for myself, and I bought the Ulanzi TC001 watch for this idea. Therefore, I tried to optimize the code as much as possible. My test runtime lasted for 10 hours, without any problems. I hope that it will work well, but if I find errors, I will try to fix them, create similar scripts with different functionality. The code contains explanations, that take some memory to store, if you run into troubles with that, you can always delete them and you can use it as a base for your development. If mistakes occur, do not judge strictly. And I'm a newbie. I hope this script will be useful to someone.

More flows for AWTRIX NG Scripts or Miscellaneous

Something wrong with this flow? Report it.