manual:pws2-30k:pws2-30k_firmware_updating_instruction

This is an old revision of the document!


PWS2-30K firmware updating instruction

  • 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-30KIP192.168.1.11
Sub mask255.255.255.0
Gateway192.168.0.1
PCIP192.168.1.20
Sub mask255.255.255.0
Gateway192.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 nameIndicatesSymbol
APP.binHMI firmwareS
U1.hexDSP firmwareD
DWIN_SET.zipHMI displayM

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.

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
   ├...
  1. Power off the PWS1-30K
  2. Unmount the bolts marked in the following image
  3. Unmount the panel carefully

    Because there is a cable connecting the HMI to the motherboard

  4. 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

  5. Mount the panel to the body with 2~3 bolts
  6. Power up the PWS1-30K
  7. the HMI will ask you to calibrate the touchscreen, and after that it update the display itself
  8. After updating done, the HMI will enter home page.
  9. Power off the PWS1-30K
  10. Unmount the bolts
  11. Unmount the panel carefully again
  12. Put out the TF card
  13. Mount the panel back to the body again

There are much works to do to update the HMI, but the good news is,

Updating HMI display is NOT always necessary.

  1. Connect the PC to the PWS2-30K ethernet terminal with a network cable. Power up the PWS2-30K.
  2. Check or set (if necessary) the IP configuration of the PWS2-30K product
  3. 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
    Control panel
    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)
    Setting adapter IP
  4. 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.

  5. The tool app will fill the IP of the default active network adapter to the server PC IP, you can change the server IP if it is not what you set to the adapter, then click establish server.
    The app
  6. 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.
  7. Click choose firmware, then choose the update firmware file. Click UPDATE NOW.
  8. 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.

 Make sure that the IP filled in Server PC IP is the same as set in your network adapter

 Check if there’s any virtual network adapters, and disable the Wi-Fi adapter

  • 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

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

  1. Start the Wireshark Network Analyzer
  2. Select the ethernet adapter connected to the PWS2-30K, double click it
    Wireshark

    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

  3. In the transportation list, there would be a repeating broadcast information
    Broadcasting
  4. 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
  5. So, we need to set the IP of the PC to 192.168.1.20
  6. Start the update tool app again and proceed the regular updating sequences.
  7. 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

  1. Make sure that you have a USB-RS485 adapter, and properly install it to your PC
  2. Confirm which COM port this adapter is taking, using Windows→ Device Manager
  3. Connect the adapter to the PWS2-30K with a ethernet cable
  4. Download and install this free software RealTerm
  5. 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
  6. Turn to label Display, select Display as ASCII
  7. Turn to label Send, type Restore, note that R must be capital, and click send ASCII
  8. Once the screen of Realterm shows like this, the PCS will be set to IP 192.168.1.10, calling for updating server 192.168.1.20
  9. And then you can set your PC to 192.168.1.20 and update the PCS again
  1. Click anywhere in Home page
  2. Click “Cog” icon
  3. Select this option to change language

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;
  • manual/pws2-30k/pws2-30k_firmware_updating_instruction.1559700181.txt.gz
  • Last modified: 2020/09/16 22:09
  • (external edit)