zha-ng / EZSP-Firmware

EZSP Firmware
GNU General Public License v3.0
25 stars 19 forks source link

Adding manufacture tokens in the firmware file. #9

Open MattWestb opened 3 years ago

MattWestb commented 3 years ago

If making one file with this information:

MFG_STRING                    : "IKEA of Sweden"
MFG_BOARD_NAME                : "Billy EZSP by MW"
MFG_MANUF_ID                  : 0x110C

And flashing it with:

.\commander.exe flash --tokengroup znet --tokenfile .\tokens-MW.txt -d EFR32MG1P132F256IM32
WARNING: The string for token MFG_BOARD_NAME (Billy EZSP by MW) fills all 16 bytes of the token space. The string will not be zero terminated.
Writing 2048 bytes starting at address 0x0fe00000
Comparing range 0x0FE00000 - 0x0FE007FF (2 KB)
Erasing range 0x0FE00000 - 0x0FE007FF (1 sector, 2 KB)
Programming range 0x0FE00000 - 0x0FE001FF (512 Bytes)
Programming range 0x0FE00200 - 0x0FE003FF (512 Bytes)
DONE

I is getting from belows:

Manufacturer: IKEA of Sweden
Board name: Billy EZSP by MW
EmberZNet version: 6.9.0.0 build 178

The same file can being used and adding the information to the chip user data that is not being erased then doing one flash erase but with chip erase is deleting it or writing on new or "erase" as data.

Also possible adding in one new firmware with the commands:

$ commander convert blink.s37 --tokengroup znet --tokenfile tokens.txt --device EFR32MG1P --outfile blink.hex Converts blink.s37 to hex format, while simultaneously defining the tokens defined in tokens.txt and on the command line.

I have not testing the convert but it shall working its only having the s37 file as input and one other as out put file. Also GBL shall working.

Way not adding somthing like this in the ZHA-NG firmware: ??

MFG_STRING                    : "ZHA-NG Made"
MFG_BOARD_NAME                : "Code Master"

Tube0013 is on the way implanting it in one or other way in his devices.

Also serial number can being written but bellows is not using it for the moment but it can coming later ;-))