Skip to content

TESTING AND DEBUGGING

patience4711 edited this page Sep 21, 2022 · 3 revisions

This system has a lot of debug capabilities. There is an infopage with a variables dump that can indicate where values are wrong. Furtermore there is a log that shows when erroneous events occurred. Via the console we can do various tests and watch the debug info on the screen.

zigbee commands

The zigbee commands have the following format:

  • byte 1 FE
  • byte 2 length of the data
  • byte 3 and 4 the command
  • byte 5 ---> the data
  • last byte(s) checksum When we issue a command via console this only contains the command and the data e.g. '2710AABBCC'. The 'FE', length and checksum are added by the software. look at sendCmd.

Zigbee loopback

To test if the zigbee module is correctly wired, we can issue a zigbee command like '2710AABBCC'. The console shows:

  • running testZigbee.cgi
  • testZigbee running with arg 2710AABBCC
  • wiringPi started
  • initCmd incl. len and crc = 032710AABBCCE9
  • inMessage = FE036710AABBCCA9
  • command processed
  • HTTP:1/1 200 OK In this case the data sent (AABBCC) was returned, so the serial communication is correct.
    When there is 'no answer' insteat of inMessage, there is no response.

polling

We can poll manually to see the issued command and the extracted inverter data. If we want to poll inverter 0 we issue '10;poll=0'

bad zigbee reception

In the journal you can see if polling failed. Also you see the signal quality, when this is low and the polling fails often, you can experiment with the posistion of the ecu to improve this.

error codes

Clone this wiki locally