Skip to main content
komp
Associate
December 9, 2019
Question

How to distinguish stm8s005 from stm8s105 from inside the controller?

  • December 9, 2019
  • 5 replies
  • 1782 views

..

    This topic has been closed for replies.

    5 replies

    Cristian Gyorgy
    Associate II
    December 17, 2019

    You could try to read the unique ID bytes ($48CD:$48D8. They are only present on STM8S105, so here you will read real values, different form 0x00, while trying to read the option bytes on STM8S005, where they are not available, you should only get zeroes, 0x00.

    komp
    kompAuthor
    Associate
    December 18, 2019

    No, it's not. In stm8s005c6 at the specified addresses are not zeros.

    komp
    kompAuthor
    Associate
    December 18, 2019

    No, it's not. In stm8s005c6 at the specified addresses are not zeros.

    Cristian Gyorgy
    Associate II
    December 18, 2019

    It was my only idea. Usually, when trying to read a reserved/unavailable memory space in 90% of cases I get 0x00.

    You could try to read addresses $5206 and $5207 (registers SPI_RXCRCR, SPI_TXCRCR), as the datasheet states that these registers are 0xFF after reset on STM8S105 and 0x00 on STM8S005 - but I would say it's rather an error in the datasheet.

    Tesla DeLorean
    Guru
    December 18, 2019

    You're going to have to probe the registers, looking for differences, and stuck at zero/one settings of given parts.

    If you want support from ST staff, I would suggest calling your local sales office, and support engineer (FAE) assigned to your account.

    Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..