This is an old revision of the document!
PWS2-30K firmware updating instruction
What you need
- One Microsoft Windows OS PC, windows 10 recommend.
- One CAT5 or higher category network cable
In this instruction, the example network configuration is as following table.
Make changes in YOUR SITE.
PWS2-30K | IP | 192.168.1.11 |
Sub mask | 255.255.255.0 | |
Gateway | 192.168.0.1 | |
PC | IP | 192.168.1.20 |
Sub mask | 255.255.255.0 | |
Gateway | 192.168.0.1 |
The subnet mask of the PC and the PWS2-30K should be the same, typically 255.255.255.0, and the IP of the PC and the PWS2-30K should be in a same segment of network.
for more information about subnet, refer to https://en.wikipedia.org/wiki/Subnetwork
99% of the failures to update are caused by these issues.
- Not setting the PCS and the PC to the same subnet
- Not turning off the firewall
- Not connecting the PC to the PCS directly but with ethernet switch
- Not disabling unnecessary adapters
File names of the firmwares
File name | Indicates | Symbol |
---|---|---|
APP.bin | HMI firmware | S |
U1.hex | DSP firmware | D |
DWIN_SET.zip | HMI display | M |
updating the bottom firmware of the HMI doesn’t request a hard reboot. It’s recommended to update the HMI bottom firmware before updating the DSP firmware.
Updating HMI display is NOT always necessary.
Updating HMI display (PWS1-30K only)
Unzip the DWIN_SET.zip to the root folder a TF card not exceeding 16GB. A non-fast-format for fat32 is recommended before doing that.
A TF card bigger than 16GB may NOT be recognized by the HMI, though in the market, 32GB is the smallest that can be bought.
The structure of the files in the TF card should be like:
Root └DWIN_SET ├0.bmp ├1.bmp ├2.bmp ├3.bmp ├...
- Power off the PWS1-30K
- Unmount the panel carefully
Because there is a cable connecting the HMI to the motherboard
- Insert the TF card to the HMI.
According to some feedbacks from sites, some WD40 is recommended to use to the slot, incase of slot contactor oxygenated, making the HMI cannot read the card
- Mount the panel to the body with 2~3 bolts
- Power up the PWS1-30K
- the HMI will ask you to calibrate the touchscreen, and after that it update the display itself
- After updating done, the HMI will enter home page.
- Power off the PWS1-30K
- Unmount the bolts
- Unmount the panel carefully again
- Put out the TF card
- Mount the panel back to the body again
Procedures
- Connect the PC to the PWS2-30K ethernet terminal with a network cable. Power up the PWS2-30K.
- Check or set (if necessary) the IP configuration of the PWS2-30K product
- Configurate the IP of the PC to an available one.
Press windows key, type control and start the control panel, address to Control Panel → All Control Panel Items → Network and Sharing Center, select change adapter settings
Select and right-click the active adapter, edit properties, select TCP/IPv4, edit the IP configurations.(Please DO record the server IP in case of update failed, and It’s strongly recommended to disable the Wi-Fi of the PC before updating operation)
- Open the update tool app. If Windows firewall appears, please DO NOT block the app.
Make sure Firewall is NOT blocking this app! Otherwise there will be unpredictable connection problem.
- Input the PCS IP read from or set to the PWS2-30K, and input the updating password: IAP888888, then click send password. The HMI will slide to an updating page, and then the updating MUST BE continued and completed, otherwise the HMI will NOT return functional.
- Click choose firmware, then choose the update firmware file. Click UPDATE NOW.
- Wait for the completion of updating. The HMI will reboot and enter home page after updating completed. Power off and power up the PWS2-30K shall be implemented to apply the new firmware.
Updating firmware may cause previous settings lost.
- re-set the setting after firmware updating.
- for multiple units updating, to save time on setting, refer to optionalbatch_parameter_setting
Exception procedures
Failed to establish server
Make sure that the IP filled in Server PC IP is the same as set in your network adapter
Strange IP filled in the Server PC IP
Check if there’s any virtual network adapters, and disable the Wi-Fi adapter
Stuck at the booting screen, lost connection
- A hard reboot to the PWS2-30K is recommended.
- Start the app again and proceed again, never mind the timeout warning after sending password
- As long as a log shows 192.168.1.11 joined, it means the connection regained
Updating interrupted and forgot the former PC IP
Once the updating starts, the HMI will enter bootloader, a reboot will not make it enter the core program and always trying to connect the IP who activated the bootloader.
In our experiences, many customers will change their PC IP once they meet some issue in the updating procedure, without noticing that the PWS2-30K has already entered bootloader, and worse, the former IP which they used to activate the bootloader is forgotten, in that case, the PC can never connect to the PWS2-30K. and the PWS2-30K is stuck in the bootloader.
To solve this mobius ring, follow these steps: Install a free software, Wireshark Network Analyzer, download from https://www.wireshark.org/#download
- Start the Wireshark Network Analyzer
- Select the ethernet adapter connected to the PWS2-30K, double click it
If wireshark indicates, No available interface found, you need to install WinPcap, (You must have missed it when installing Wireshark) https://www.winpcap.org/install/bin/WinPcap_4_1_3.exe
- In this example, we can read that the PWS2 with an IP of 192.168.1.11, who is in the bootloader, lost the connection to the previous PC who has an IP of 192.168.1.20
- So, we need to set the IP of the PC to 192.168.1.20
- Start the update tool app again and proceed the regular updating sequences.
- There would be a timeout warning after sending the password, but it does NOT matter, as long as a log shows, e.g. 192.168.1.11 joined, it means the connection regained
In previous version of updating tools, there's a bug that even with an IP from another subnet, it can trigger the PWS2-30K into bootloader, and PWS2-30K will be calling a server IP not in its subnet, and stuck on the bootloader screen.
To solve this issue, please follow these steps
- Make sure that you have a USB-RS485 adapter, and properly install it to your PC
- Confirm which COM port this adapter is taking, using Windows→ Device Manager
- Connect the adapter to the PWS2-30K with a ethernet cable
- Download and install this free software RealTerm
- Open Realterm, turn to label Port, select the COM port the adapter is taking, and the baud rate 19200, Parity to None, and click open and change
- Turn to label Display, select Display as ASCII
- Turn to label Send, type Restore, note that R must be capital, and click send ASCII
- And then you can set your PC to 192.168.1.20 and update the PCS again
The language became Chinese
Optional: Batch parameter setting
Batch parameter setting can be implemented after updating. Writing the preset register values of the PWS2-30K to prevent repeated setting.
Clicking the Batch parameter setting button to start setting, conforming to the register recorded in the script file: default.ini in the same folder with the updating tool .exe file(if it doesn't exist, create it with an empty tex file.).
To change the preset parameters, edit the config document default.ini with text editor software. And follow the format rules to edit the register address and values. Refer to the communication protocol for the register mapping and value range.
Format rules
- The number left of the equal-sign is the register address, a line break must be following the equal-sign.
- The value shall be under the register address.
- A semicolon shall be put in the end, as indicator of one register setting.
- All the numbers, including the register address and value are decimal-based.
This example shows how to edit a default.ini Assume we want to set the following parameters to these values:
- Max charging current →80A
- Max discharging current →80A
- Lower voltage limit of battery protection → 220V
- Upper voltage limit of battery protection → 700V
According to the protocol,
- Max charging current, address is 811 in decimal, magnification is 10, so this register shall be set to 800
- Max discharging current, address is 812 in decimal, magnification is 10, so this register shall be set to 800
- Lower voltage limit of battery protection, address is 813 in decimal, magnification is 10, so this register shall be set to 2200
- Upper voltage limit of battery protection, address is 814 in decimal, magnification is 10, so this register shall be set to 7000
default.ini shall be written in this way
811= 800; 812= 800; 813= 2200; 814= 7000;