Skip to main content
DMega.1
Associate II
April 29, 2023
Solved

how can i compute flash crc for STM8AF5288 MCU with STVD IDE & Cosmic compiler ?

  • April 29, 2023
  • 4 replies
  • 4222 views

..

    This topic has been closed for replies.
    Best answer by Tesla DeLorean

    If you're doing functional safety likely going to need to understand MCU and surrounding tools, and implement your own methods.

    S19 with be Motorola HEX format. Tools like SRecords exist, but the formats are not particularly complicated. This and object files should be covered at college level.

    I think SRecords has CRC / Checksum options, IAR tool chain had some too. Don't use STM8/Cosmic so don't know specifics, would imagine there's docs and tutorials. Materials don't have to be tool specific if done as a post-link, user or batch file step.

    If you can read memory via a pointer you should be able to implement target side code to sum, or CRC that content, and confirm integrity. ie data built on host matches materials running on target.

    Writing packaging and signing tools should be with the scope of team responsibilities.

    4 replies

    Tesla DeLorean
    Guru
    April 29, 2023

    In the worst case you'd likely need to do as a post-link step over .BIN or .HEX content

    Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
    DMega.1
    DMega.1Author
    Associate II
    April 30, 2023

    i have an *.s19 from the STVD IDE ? is it something i should use ?

    or is there a standard procedure to accomplish this check in STM8 ?

    Tesla DeLorean
    Tesla DeLoreanBest answer
    Guru
    April 30, 2023

    If you're doing functional safety likely going to need to understand MCU and surrounding tools, and implement your own methods.

    S19 with be Motorola HEX format. Tools like SRecords exist, but the formats are not particularly complicated. This and object files should be covered at college level.

    I think SRecords has CRC / Checksum options, IAR tool chain had some too. Don't use STM8/Cosmic so don't know specifics, would imagine there's docs and tutorials. Materials don't have to be tool specific if done as a post-link, user or batch file step.

    If you can read memory via a pointer you should be able to implement target side code to sum, or CRC that content, and confirm integrity. ie data built on host matches materials running on target.

    Writing packaging and signing tools should be with the scope of team responsibilities.

    Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
    Tesla DeLorean
    Guru
    April 30, 2023
    Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
    DMega.1
    DMega.1Author
    Associate II
    May 1, 2023

    @Community member​ thanks for your inputs. I will try the cosmic checksum feature on the STM8AF52XX MCU & post an update over here.