Turn your LoctekMotion/FlexiSpot standing desk into a smart desk!

I can have a look after the weekend, but perhaps it is interesting to create a group to discuss some where. Another user on GitHub with an ESP32 did request something similar: Update Arduino / C++ sample · Issue #3 · iMicknl/LoctekMotion_IoT · GitHub.

I’ve got one of these on the way and am hoping your hack will work.

Will post results as I go…

hi what an awesome project thanks for sharing!

unfortunately i only have a flexispot with a basic keypad that only does up and down and has no RJ45 port. has anybody ever looked into making one of those smart?
could be a matter of just closing certain circuits depending on which direction you want to go?

image

1 Like

Can anyone explain what the switch “Virtual Screen” is meant to do?

Thanks

I have this exact same controller, but mine is officially broken. Sorry this is probably not the correct thread, but there isn’t much information out there on these Loctek controllers.

Has anyone been able to replace, or rebuild one?

Hi I‘m looking for some help. My desk seems to be different to the desks that have already been posted here. Therefore I opened a new topic. So if anyone is willing and able to help, I would really appreciate it! Thanks :blush:

Thanks for this awesome work Mick!

I managed to get this working really quickly thanks to your instructions along with comments of others regarding different boards etc.

I have a question regarding automations…what sort of automations are people using once this is integrated? For example, if you wanted to enforce a stand position after X amount of time sitting, how are you doing this?

In my case, my office is a log cabin, so i generally power down all plugs as part of my office alarm enabling script, which means when i start work the next day, the power to the desk comes back on and as such HA doesn’t know the position of the desk until I press a position button, however i rarely do until i want to stand again.

Just after some ideas on how to benefit from this integration and how you’ve achieved them - automation yaml examples would be greatly appreciated :slight_smile:

Thanks in advance

Hi will it also work with an hs13b-1 (E7) ?

1 Like

Hey there @KrX , just got some first functionality on that board. The signal order on the rj45 is different and so far I can only activate the presets, not move it up and down and the height sensor readout isn’t working either.
I’m using the code from the HS13A-1 so if anyone has an idea which parts to change for the HS13B-1 please chime in.

This is the cable order I’m using right now for RX, TX, PIN 20 and +5V/GND (sorry for low quality handwritten notes, just wanted to post it here before I might forget to continue on this for the next couple weeks haha)

Hi, i forgot to reply here.

Meanwhile is solved it and also got it extended with more commands:

EDIT: here i used the wire config for HS01B-1

1 Like

Hello everyone, anyone is getting error e7 or e8 when using this? When I have esp connected to my desk everything works fine but after night when my server is being turned off I’m getting one of these errors without it I do not have it so it is not problem with desk or motors. I’m using CB38M2L(IB)-1 unit with HS11A-1 panel connected like HS03

Passing over this thread i think i know why you were thinking that the order is reversed in the contributor table.
if you look at both columns they are in the exact reverse order like in a mirror
it’s because it’s what is happening if you use a RJ45 connector, RJ45 cables and plug must be reversed (we call it crossed cables) in order to work as expected

But my question for @imick is why in 1st do you used a RJ45 connector ? won’t have it worked using dupont connectors straight to the ESP32 corresponding pins ?

I have a HS13A1 model and i will try to setup such an integration

I’m really keen to get my FlexiSpot EQ5 desk into HA, but not having any luck so far. I posted about my desk in the issues on the github repo mentioned here, but I wondered if anyone on this forum has managed to achieve this with a similar desk/motor model as I have?

My control box has a second ethernet port available, thus it does not make sense to directly plug in with dupont connectors. I use RJ45 ethernet connector on one side, on the other side I use dupont cables directly to my ESP32.

I didn’t made myself explicit enough sorry
By directly i was meaning exactly what you are refering. Direct from the output of the cut ethernet cable
I was confused by the photos that show à white rj45 box.

So i will follow the same setup as you thanxs for the clarification.

I own a Fezibo brand standing desk. The control box does have the RJ45 but unclear if my box is the same as yours or similar. Would love some guidance as this project has been the goal since purchase :grin:

1 Like

/smacks forehead

Of course, that makes sense!

Thank you very much for this great tutorial! I replicated it with my Flexispot/Sanodesk Unit and it works like a charm!

@pb2731 Hi, which FlexiSpot / Sanodesk model do you have? I’m hoping to open up my EQ5 desk control box (CB38M2D(PB)-2) to see what board is inside

Hi, I am stuck with the configuration in ESPHome. The two files are in the ESPHome directory. I took the config from the example, but get all sorst of errors whes trying to install the the yaml file. This goes on for pages…

Can someone tell me what I am doing wrong?

In file included from src/main.cpp:118:
src/desk_height_sensor.h:74:56: error: stray '\302' in program
   <title>LoctekMotion_IoT/desk_height_sensor.h at main · iMicknl/LoctekMotion_IoT</title>
                                                        ^
src/desk_height_sensor.h:74:57: error: stray '\267' in program
   <title>LoctekMotion_IoT/desk_height_sensor.h at main · iMicknl/LoctekMotion_IoT</title>
                                                         ^
In file included from src/main.cpp:118:
src/desk_height_sensor.h:229:10: warning: missing terminating ' character
     <!-- '"` --><!-- </textarea></xmp> --></option></form><form class="js-site-search-form" role="search" aria-label="Site" data-scope-type="Repository" data-scope-id="344620646" data-scoped-search-url="/iMicknl/LoctekMotion_IoT/search" data-owner-scoped-search-url="/users/iMicknl/search" data-unscoped-search-url="/search" data-turbo="false" action="/iMicknl/LoctekMotion_IoT/search" accept-charset="UTF-8" method="get">
          ^
src/desk_height_sensor.h:229:10: error: missing terminating ' character
     <!-- '"` --><!-- </textarea></xmp> --></option></form><form class="js-site-search-form" role="search" aria-label="Site" data-scope-type="Repository" data-scope-id="344620646" data-scoped-search-url="/iMicknl/LoctekMotion_IoT/search" data-owner-scoped-search-url="/users/iMicknl/search" data-unscoped-search-url="/search" data-turbo="false" action="/iMicknl/LoctekMotion_IoT/search" accept-charset="UTF-8" method="get">
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/desk_height_sensor.h:286:75: error: stray '\342' in program
       <span aria-hidden="true" class="d-inline-block ml-1 v-align-middle">↵</span>
                                                                           ^
src/desk_height_sensor.h:286:76: error: stray '\206' in program
       <span aria-hidden="true" class="d-inline-block ml-1 v-align-middle">↵</span>
                                                                            ^
src/desk_height_sensor.h:286:77: error: stray '\265' in program
       <span aria-hidden="true" class="d-inline-block ml-1 v-align-middle">↵</span>
                                                                             ^
src/desk_height_sensor.h:291:56: error: stray '\342' in program
       <span class="d-inline-block ml-1 v-align-middle">↵</span>
                                                        ^
src/desk_height_sensor.h:291:57: error: stray '\206' in program
       <span class="d-inline-block ml-1 v-align-middle">↵</span>
                                                         ^
src/desk_height_sensor.h:291:58: error: stray '\265' in program
       <span class="d-inline-block ml-1 v-align-middle">↵</span>
                                                          ^
src/desk_height_sensor.h:333:75: error: stray '\342' in program
       <span aria-hidden="true" class="d-inline-block ml-1 v-align-middle">↵</span>
                                                                           ^
src/desk_height_sensor.h:333:76: error: stray '\206' in program
       <span aria-hidden="true" class="d-inline-block ml-1 v-align-middle">↵</span>
                                                                            ^
src/desk_height_sensor.h:333:77: error: stray '\265' in program
       <span aria-hidden="true" class="d-inline-block ml-1 v-align-middle">↵</span>
                                                                             ^
src/desk_height_sensor.h:338:56: error: stray '\342' in program
       <span class="d-inline-block ml-1 v-align-middle">↵</span>
                                                        ^
src/desk_height_sensor.h:338:57: error: stray '\206' in program
       <span class="d-inline-block ml-1 v-align-middle">↵</span>
                                                         ^