Skip to main content

Uplift Desk Automation

Message Syntax

Transmit

A transmitted message has the following syntax.

0xF1, 0xF1, <cmd>, 0x00, <crc>, 0x7E
  • 0xF1, 0xF1 indicates the message start
  • cmd is one of:
    • 0x01 - Up
    • 0x02 - Down
    • 0x2B - Stop
    • 0x03 - Save preset 1
    • 0x04 - Save preset 2
    • 0x05 - Recall preset 1
    • 0x06 - Recall preset 2
    • 0x07 - Sync
    • 0x25 - Save preset 3
    • 0x26 - Save preset 4
    • 0x27 - Recall preset 3
    • 0x28 - Recall preset 4
  • crc is the sum of the bytes at index 2 and 3.
  • 0x7E indicates the end of message.

Receive

A received message has the following syntax.

0xF2, 0xF2, <cmd>, <len>, <data...>, 0x0F, <crc>, 0x7E
  • 0xF2, 0xF2 indicates the message start
  • cmd is one of:
    • 0x01 - Height value
    • 0x25 - Preset 1 height
    • 0x26 - Preset 2 height
    • 0x27 - Preset 3 height
    • 0x28 - Preset 4 height
  • len indicates how many messages will be sent next, excluding the CRC and EOT.
  • data will contain the incoming data values, explained for height readings below.
  • 0x0F - Unknown
  • crc will be the sum of bytes at index 2 up to the CRC.
  • 0x7E indicates the end of message.

Example: Received Height Reading

When a new height value comes in, the message will look something like this:

0xF2, 0xF2, 0x01, 0x03, 0x01, 0x1B, 0x0F, 0x2F, 0x7E

In this case, the desk was at 28.3". Here is how we can calculate that.

  1. First off, the command is 0x01, so we know we're about to receive height data.
  2. The next byte tells us to listen for 3 data bytes.
  3. The relevant data comes in as 0x01, 0x1B. This will be converted to a height value later. (Unclear what 0x2F does here)
  4. Then, we add all of the previous bytes (other than the header) to verify the CRC is correct.
    0x01 + 0x03 + 0x01 + 0x1B + 0x0F = 0x2F
  5. The actual height is a two-byte word, so the first number needs to be bitshifted. In this example, we received 0x01, 0x1B, so the height calculation looks like: 0x01 << 8 | 0x1B = 283.
  6. Divide the received value by 10 to convert to inches. The result is 283 / 10.0 = 28.3in.

SourcesReferences

Hardware

  1. "JCP35NBLT Bluetooth Box Teardown Internal Photos Internal Photo ZHEJIANG JIECANG LINEAR MOTION TECHNOLOGY". (2018, January 25). FCC ID. Retrieved January 19, 2021.
  2. Jiecang Bluetooth Dongle Product Listing. Retrieved January 19, 2021.

Images from /u/deadman96385

  1. https://imgur.com/a/MUbXwnM
  2. https://i.imgur.com/DyMf3Ee.jpg
  3. https://i.imgur.com/KtsWpVQ.jpg
  4. https://i.imgur.com/BS62C1E.jpg
  5. https://i.imgur.com/woWoQMe.jpg
  6. https://i.imgur.com/Lta5Nab.jpg

Software

  1. Justintout. (2020, April 16). GitHub - "justintout/uplift-reconnect: A Flutter app to control Uplift desks with Uplift Connect BLE modules installed". GitHub. Retrieved January 19, 2021.
  2. Deadman96385. (2020, March 6). "uplift_desk_controller_app/BluetoothHandler.java at a58bcadfb77ac993751758465f1cf20f71d6d8fd ยท deadman96385/uplift_desk_controller_app". GitHub. Retrieved January 23, 2021.
  3. Phord. (2021, August 12). "phord/Jarvis: Hacking the Jarvis standup desk from fully.com for home automation using an ESP8266 arduino interface". GitHub. Retrieved December 5, 2021.
  4. Ramot, Y. (2015, February 4). "UpLift Desk wifi link". Hackaday.io.
  5. Horacek, L. (2019, April 14). "Standing desk remote control". Hackaday.io.
  6. Hunleth, F. (2019, January 18). "Nerves At Home: Controlling a Desk". Embedded Elixir. Retrieved January 2021.