STM32F103 Documentation

Ollie
Sat Jun 04, 2016 3:56 am
I have observed that the ST Microelectronics documentation is very detailed and is distributed in large number of PDF files. Sometimes the relevant information can be difficult to find even when the right section of a document is available. Typical case is to find the pin numbers for an alternative function or the available DMA streams for peripheral devices.

For that reason, I did some processing to make this info available in an easier form. First I converted the pin assignment tables in Excel worksheets, saved those in CSV files, and then converted them into HTML files. The results can be browsed at

http://htmlpreview.github.io/?https://g … tList.html
http://htmlpreview.github.io/?https://g … tName.html
http://htmlpreview.github.io/?https://g … igh64.html
http://htmlpreview.github.io/?https://g … gh100.html
http://htmlpreview.github.io/?https://g … gh144.html
http://htmlpreview.github.io/?https://g … Med48.html
http://htmlpreview.github.io/?https://g … Med64.html
http://htmlpreview.github.io/?https://g … ed100.html

Cheers, Ollie


RogerClark
Mon Jun 06, 2016 12:40 am
Thanks Ollie

Perhaps we can put this information in the Wiki.

BTW. At the moment if I click on those links, I can’t get back (back button just reloads the page again) – but this may be a Firefox only problem.


Ollie
Mon Jun 06, 2016 1:52 am
Roger,

That is a challenge in GitHub that HTML pages are stored as text. To get then rendered, you have to copy the content in an external HTML editor and view them there. The htmlpreview.github.io is a crude workaround and could have restrictions – such as those you observed with Firefox.

I will store the CVS files in GitHub (https://github.com/OliviliK/STM32F103) as an alternative documentation. This could be quite popular for those who are designing their system wiring with Excel.

Soon, I will add the design tables for DMA allocations. In F1, this is still easy, but with F4 there are more challenges due to lack of available streams. In that sense, ST has not done as good job as some other Cortex M3/M4/M7 vendors, who have very little restrictions in DMA usage. In those cases, you can have DMA channels/streams in a pool where they are allocated on demand. With F4, I have been forced to do static DMA allocations. That is a robust method for real-time control, but causes some extra design effort.

When you are saying that we can add this info in Wiki, do you have a recommendation who will do it? I have done some Wiki development (http://www.emblocks.org/wiki/tutorials/f401_f429_disco) and could help, but before that I would like to learn about the style and practices used in wiki.stm32duino.

Cheers, Ollie


RogerClark
Mon Jun 06, 2016 3:37 am
Ollie

I found a page that website that converts HTML tables into Wiki format, but I’ve forgotten the URL. I will see if I can find it again


ddrown
Tue Jun 07, 2016 3:39 am
Ollie wrote:I have observed that the ST Microelectronics documentation is very detailed and is distributed in large number of PDF files. Sometimes the relevant information can be difficult to find even when the right section of a document is available. Typical case is to find the pin numbers for an alternative function or the available DMA streams for peripheral devices.

For that reason, I did some processing to make this info available in an easier form. First I converted the pin assignment tables in Excel worksheets, saved those in CSV files, and then converted them into HTML files. The results can be browsed at

http://htmlpreview.github.io/?https://g … tList.html
http://htmlpreview.github.io/?https://g … tName.html
http://htmlpreview.github.io/?https://g … igh64.html
http://htmlpreview.github.io/?https://g … gh100.html
http://htmlpreview.github.io/?https://g … gh144.html
http://htmlpreview.github.io/?https://g … Med48.html
http://htmlpreview.github.io/?https://g … Med64.html
http://htmlpreview.github.io/?https://g … ed100.html

Cheers, Ollie


RogerClark
Tue Jun 07, 2016 3:57 am
Thanks Dan

Just one small thing (which I can change myself)…

On http://wiki.stm32duino.com/index.php?ti … F1xx_48pin

The last column, labeled “Baite”, should really be “Maple mini” as Baite are just the manufacturer, and they make other boards.

I think the Baite Maple mini follows the same pin arrangement as the original Maple mini and also is the same as the other Maple Mini clone (which seems to be made by another, unknown, Chinese company)


Ollie
Sat Jun 25, 2016 9:19 pm
I have extended the F103 documentation describing the vendors and manufacturers I have been using. The following link has a summary table for the boards I have been using. The links on the left most column, open detail pages organized by the processor types.

https://github.com/OliviliK/STM32F103/b … /README.md

For comments or questions, use this forum or post them in https://github.com/OliviliK/STM32F103/issues

Cheers, Ollie


RogerClark
Sat Jun 25, 2016 9:26 pm
Thanks @ollie

Would it be Ok of I used some of the images and schematics etc in the wiki

wiki.stm32duino.com

Thanks

Roger


Ollie
Sat Jun 25, 2016 11:33 pm
Roger,

I can give you permission to use the F103 pictures I have taken. All the schematics are created by 3rd parties and I am just linking them in my repository. In that sense, I am not authorized to give a permission about their usage. I am not aware of anything that would prevent you to use them, just like I did.

Cheers, Ollie

PS. I have not yet started to do the essential parts of my F103 tutorial. I am still evaluating about the run-time model. A collection of cooperative tasks sharing a single stack and doing Run To Completion (RTC) actions based on external or internal events.

On other hand the popularity gained by Micrium µC/OS III could change my mind to do the tutorial with the classic multi stack model.

Any recommendations?


RogerClark
Sun Jun 26, 2016 1:47 am
Ollie wrote:Roger,

I can give you permission to use the F103 pictures I have taken. All the schematics are created by 3rd parties and I am just linking them in my repository. In that sense, I am not authorized to give a permission about their usage. I am not aware of anything that would prevent you to use them, just like I did.


Ollie
Mon Jun 27, 2016 4:07 pm
Thanks Roger,

Your earlier comments about my consideration to create another SPL replacement, helped me to decide to use libopencm3 as a proven and well documented library.

For the synchronization and task management, my conclusion is that a preemptive systems take too much resources and are creating a lot of bugs that are difficult to detect. The basic Adam Dunkels’ protothreads is preferred solution. The complete Contiki is proven solution for real life communication systems, but is way too large for a small F103.

Now I will continue with my Wiki at https://github.com/OliviliK/STM32F103/wiki using only a part of the Contiki core system. In https://github.com/contiki-os/contiki/t … r/core/sys are all the PT features and other useful library solutions for synchronization and task management.

Cheers, Ollie


RogerClark
Mon Jun 27, 2016 8:58 pm
Ollie

libopencm3 is a good choice.

Having looked at the Cube and HAL recently, I can see the attraction of libopencm3, and I must find some time to get more acquainted with it myself.


Ollie
Fri Jul 01, 2016 7:48 pm
Roger,

If you are using Windows, there are some issues in LibOpenCM3 installation. I have written a Blog Post addressing those issues. Using the recommended steps, it takes around 10 minutes to install the library.

The post can be found at http://olliesworkshops.blogspot.com/201 … ation.html

Cheers, Ollie


RogerClark
Fri Jul 01, 2016 8:55 pm
Thanks Ollie

Yes. I mainly use Windows 7.

I will remember to read your blog when I get around to installing it


Slammer
Sat Jul 02, 2016 1:15 pm
Opencm3 is very nice, intuitive and compact. I like it….
It is sad to see very low activity around it lately… but for most of projects must be OK, at least for stm32 family.
Me and Vassilis we made a repo trying to make an arduino stm32 core based on opencm3, nothing is ready, nothing to announce, just a playground to make some tests, and to have fun with opencm3., https://github.com/Serasidis/arduino_opencm3

RogerClark
Sat Jul 02, 2016 9:37 pm
Thanks guys

I will try it today.

Edit.

Perhaps you should post this to a new thread.


zmemw16
Mon Jul 04, 2016 11:46 am
just found this link
https://github.com/esden/stm32-datasheets

the files are dated at 1yr, so you’ll need to check latest version. the st document number is in the file name.

for the STM32F103x8-STM32F103xB-CD00161566.pdf, it’s rev 16, st is at rev 17

may be useful for a quick lookup?

stephen


Ollie
Thu Jul 07, 2016 2:51 am
If you are interested about some examples of libopencm3 usage for GPIO with STM32F103, take a look at https://github.com/OliviliK/STM32F103/w … rial3_GPIO.

This tutorial has the following demo programs

  • Led driven by a button
  • LED blinking speed controlled by button using DWT
  • Using interchangeable macros to speed up I/O access by 18 fold

For the I/O configuration, there are detailed explanations of the configuration options and the illustrations of button bounce impacts on falling and rising edges.

For performance measurements, it shown how the nano second level measurements are done with DWT and how those are verified with logic analyzer. The GNU C Compiler optimization settings are described.


Vassilis
Thu Jul 07, 2016 8:03 pm
Ollie wrote:If you are interested about some examples of libopencm3 usage for GPIO with STM32F103, take a look at https://github.com/OliviliK/STM32F103/w … rial3_GPIO.

This tutorial has the following demo programs

  • Led driven by a button
  • LED blinking speed controlled by button using DWT
  • Using interchangeable macros to speed up I/O access by 18 fold

For the I/O configuration, there are detailed explanations of the configuration options and the illustrations of button bounce impacts on falling and rising edges.

For performance measurements, it shown how the nano second level measurements are done with DWT and how those are verified with logic analyzer. The GNU C Compiler optimization settings are described.


Leave a Reply

Your email address will not be published. Required fields are marked *