Author Topic: Ebay STM32F103C8 board reports more memory than it should  (Read 6110 times)

0 Members and 1 Guest are viewing this topic.

Offline miceuzTopic starter

  • Frequent Contributor
  • **
  • Posts: 387
  • Country: lt
    • chirp - a soil moisture meter / plant watering alarm
Ebay STM32F103C8 board reports more memory than it should
« on: February 18, 2015, 01:26:10 pm »
Does anyone have one of these cheap ebay STM32 boards?



The thing I have reports that it has 128k of flash. Datasheet says "C8" at the end means 48pin 64k flash device. Can anyone try on their board?

Offline lukier

  • Supporter
  • ****
  • Posts: 634
  • Country: pl
    • Homepage
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #1 on: February 18, 2015, 01:57:10 pm »
I think I've read somewhere that people managed to force JTAG/ISP programmer to use different model number (or they were using IAP Flash programming - I don't remember) and they were able to access the memory beyond what it should be based on the part number.

It seems that ST is binning these MCUs according to the usable flash amount (e.g. if they find corrupted bits), or maybe, there is one silicon design and memory limits are imposed more or less artificially for marketing reasons. These are not 14 nm Intel CPUs, is the yield that low that they have to resort to binning based on which parts are broken?
 

Offline elgonzo

  • Supporter
  • ****
  • Posts: 688
  • Country: 00
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #2 on: February 18, 2015, 01:58:20 pm »
Are you sure that your board has a STM32F103C8, and not a STM32F103CB?
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #3 on: February 18, 2015, 03:01:08 pm »
Quote
The thing I have reports that it has 128k of flash.

How did it do that? From the bottom of its lung?

Yes, they indeed have far more than what's specified in the datasheet.
================================
https://dannyelectronics.wordpress.com/
 

Offline miceuzTopic starter

  • Frequent Contributor
  • **
  • Posts: 387
  • Country: lt
    • chirp - a soil moisture meter / plant watering alarm
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #4 on: February 18, 2015, 03:53:23 pm »
Are you sure that your board has a STM32F103C8, and not a STM32F103CB?

Yes, I'm absolutely positive  ;)

Offline miceuzTopic starter

  • Frequent Contributor
  • **
  • Posts: 387
  • Country: lt
    • chirp - a soil moisture meter / plant watering alarm
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #5 on: February 18, 2015, 04:05:26 pm »
Quote
The thing I have reports that it has 128k of flash.

How did it do that? From the bottom of its lung?

Yes, they indeed have far more than what's specified in the datasheet.

$ stm32flash -w main.bin -g 0 /dev/ttyUSB0
stm32flash 0.4

http://stm32flash.googlecode.com/

Using Parser : Raw BINARY
Interface serial_posix: 57600 8E1
Version      : 0x22
Option 1     : 0x00
Option 2     : 0x00
Device ID    : 0x0410 (Medium-density)
- RAM        : 20KiB  (512b reserved by bootloader)
- Flash      : 128KiB (sector size: 4x1024)
- Option RAM : 16b
- System RAM : 2KiB
Write to memory
Erasing memory
Wrote address 0x0800216c (100.00%) Done.

.. also via GDB:

(gdb) monitor flash probe 0
device id = 0x20036410
flash size = 128kbytes
flash 'stm32f1x' found at 0x08000000



Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #6 on: February 18, 2015, 07:09:10 pm »
I have never ran into a C6 chip that reads back at 128KB.

So you could have a genuine CB chip (128KB), or the software is mis-reading the chip size.

However, I have  never ran into a C6 chip that doesn't have more than 64KB flash.
================================
https://dannyelectronics.wordpress.com/
 

Offline Brutte

  • Frequent Contributor
  • **
  • Posts: 614
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #7 on: February 18, 2015, 07:22:41 pm »
However, I have  never ran into a C6 chip that doesn't have more than 64KB flash.
does not have more than 64kB == has 64 kB or less (in 2^N world)
Isn't it that all C6 chips "have 64kB or less" (typically 32kB)?

Readout of a signature does not mean the uC has 128kiB of flash physically present. Execute a 128kB application at 105degC, 72MHz and let us watch.
 

Offline andersm

  • Super Contributor
  • ***
  • Posts: 1198
  • Country: fi
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #8 on: February 18, 2015, 08:29:05 pm »
Note that the stm32flash tool gets the memory sizes from a hardcoded table rather than reading them off the device, and as near as I can tell all the medium-density devices are lumped into one. The table in the referenced application note (p. 125) does not list flash size as a parameter. Try reading the flash size register (F_SIZE, 0x1FFFF7E0) directly instead.

Online langwadt

  • Super Contributor
  • ***
  • Posts: 4427
  • Country: dk
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #9 on: February 18, 2015, 08:38:00 pm »
I think I've read somewhere that people managed to force JTAG/ISP programmer to use different model number (or they were using IAP Flash programming - I don't remember) and they were able to access the memory beyond what it should be based on the part number.

It seems that ST is binning these MCUs according to the usable flash amount (e.g. if they find corrupted bits), or maybe, there is one silicon design and memory limits are imposed more or less artificially for marketing reasons. These are not 14 nm Intel CPUs, is the yield that low that they have to resort to binning based on which parts are broken?

it is also possible that they want to have a part an a particular range to compete with others and as long as they aren't sold
it sufficient number they won't bother making a new part, they'll just sell a bigger part at a lower margin 

I've worked at place that was bitten by that once, a product by accident used memory that weren't supposed to be there but it
was because it was really a bigger part.  When the production got really big the manufacturer of the IC made a new part that
only had the memory it was supposed to and  everything stopped working



 

Offline true

  • Frequent Contributor
  • **
  • Posts: 329
  • Country: us
  • INTERNET
Re: Ebay STM32F103C8 board reports more memory than it should
« Reply #10 on: February 18, 2015, 11:58:38 pm »
This is common. This specific model is marked as 64K everywhere in the datasheets but all samples I have seen, traceable or otherwise, have had 128K accessible flash.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf