I have a Lishui Controller .lsh firmware file lets mod it

bluepyzel

10 µW
Joined
Sep 21, 2022
Messages
5
I was able to get a Lishui controller firmware file. Controller: LSW1408-18E

This is a .LSH file which is uploaded to the controller via Lishui Controller USB stick FPS2 using the LS Controller Update software from Lishui website.

Who here can build a program that allows this firmware to be modified in a user friendly GUI?

Note: When you open the Lishui Controller Programmer (from their website) I found out if you click the "Clear Info" button multiple times it opens a "secret" menu called File Conversion. All I can tell is that new tab allows you to convert hex to .LSH files which can be uploaded to the controller. Secret menu https://pasteboard.co/bfIVsS8ZCglf.png

Firmware file proof : https://pasteboard.co/6PaUIn5wRmVS.png


Controller working with firmware: https://pasteboard.co/fuZBFDNRFDBH.jpg
 

Attachments

  • LSH FIle.png
    LSH FIle.png
    499.2 KB · Views: 538
  • secret.png
    secret.png
    38.2 KB · Views: 538
  • IMG_0179.jpg
    IMG_0179.jpg
    596.1 KB · Views: 537
bluepyzel said:
Who here can build a program that allows this firmware to be modified in a user friendly GUI?
You can do a basic setting of max current and undervoltage limit directly in the Lishui tool by unchecking the "Keep Current Settings" box.

There is an open source firmware for this kind of Lishui-Controllers. The lsh file can simply be generated at github by editing the configuration file. The lsh is provided as an artifact. A user friendly GUI exists also, but in this case you can't flash via the display connector but via a STLink V2...

regards
stancecoke

68747470733a2f2f7777772e706564656c6563666f72756d2e64652f77696b692f6c69622f6578652f66657463682e7068703f63616368653d266d656469613d656c656b74726f746563686e696b3a677569626173696373657474696e67732e706e67
 
Hey man! Thanks for responding! I actually downloaded the open source firmware a couple days before I got the OEM firmware because I could not find how to connect to the TO the open source app. I have the cable that connects directly to the display as well as the cable that connects USB from my PC to the controller. Do I have to open the controller and probe the board?

I keep getting “No ST-Link” detected
 
stancecoke said:
bluepyzel said:
Who here can build a program that allows this firmware to be modified in a user friendly GUI?
You can do a basic setting of max current and undervoltage limit directly in the Lishui tool by unchecking the "Keep Current Settings" box.

There is an open source firmware for this kind of Lishui-Controllers. The lsh file can simply be generated at github by editing the configuration file. The lsh is provided as an artifact. A user friendly GUI exists also, but in this case you can't flash via the display connector but via a STLink V2...

regards
stancecoke

68747470733a2f2f7777772e706564656c6563666f72756d2e64652f77696b692f6c69622f6578652f66657463682e7068703f63616368653d266d656469613d656c656b74726f746563686e696b3a677569626173696373657474696e67732e706e67


The picture that I attached….. is this an earlier version of the open source project or is this a factory app?? I can’t find this app anywhere just the “firmware updater” Lishui has on their website.
 

Attachments

  • 60F32BB1-28B3-49D8-932C-F7623EC43AAC.png
    60F32BB1-28B3-49D8-932C-F7623EC43AAC.png
    3.9 MB · Views: 468
bluepyzel said:
Do I have to open the controller and probe the board?
Some older controllers have the programming port as a separate connector (white 4 pin female) routed out of the housing.

index.php

index.php


The newer ones have the bootloader preinstalled and can be flashed via the Display-connector with the tool you described in the first post.

If you want to flash the newer ones via the STLink V2, you have to open the housing, remove the potting and solder in the 4 wires for GND, +3.3V, SWDIO and SWCLK.

bluepyzel said:
or is this a factory app??
Yes, but it is no longer available from the official Lishui page. You can find an older version on the german pedelecforum.

But you need a certain firmware version, that is compatible with this tool. Most controllers are not compatible. I only know this single source for controllers with the suitable firmware.

regards
stancecoke
 
stancecoke said:
The newer ones have the bootloader preinstalled and can be flashed via the Display-connector with the tool you described in the first post.

I tried modifying the Inc/config.h by just increasing the speed from 25 to 60. Then took that generated .LSH file and tried the following:

- Connected my display to computer via the APT develop adapter. (this adapter cable has a female green port to USB). I then opened the Lishui controller programmer from their website and I get the error " Error connection time out". My COM port is open and good. but it wont connect with my display powered off or on. Displays used" 850C TFT JJL2.0 V1.3DW and then a 850C TFT QB2.0 5S"

I then tried the same firmware file (again only changed the speed using the config file output to lsh). This time I used the Lishui Controller USB Stick FPS2 HOWEVER, this USB stick has a Male connect to USB. So this time using that I connect the adapter directly to the Female controller green cable.

The Lishui controller detects it, writes the file (almost instantly), since it writes that fast I have to assume that it sent the config.h file but I do not see a change on the ebike at all.

Am I getting the following correct? I SHOULD be able to use the . LSH file via github where i increased the speed and install it to my bike by using the APT Display to USB adapter while using the Lishui Controller Programmer to push that new .LSH to the DISPLAY??
 
bluepyzel said:
using the Lishui Controller Programmer to push that new .LSH to the DISPLAY??
?! The open source firmware has to be flashed to the controller of course, not to the display :shock:

850 displays are Bafangs normally, they have different pinouts and a different male/female logic on the connector.
eggrider_v2_display_pinout.jpeg


regards
stancecoke
 
Yeah that’s what I thought to flash the controller. The issue is that the Lishui USB to controller programming cable isn’t being read by any program only the Lishui provided firmware updater
 
bluepyzel said:
The issue is that the Lishui USB to controller programming cable isn’t being read by any program only the Lishui provided firmware updater

?! The Lishui programming cable is a simple FTDI USB to UART converter.
 
Back
Top