EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

Missing volatile qualifiers in MCU vendor header files?

Started by Dave Nadler April 5, 2020
On 9/4/20 6:49 am, Stephen Pelc wrote:
> On Wed, 08 Apr 2020 14:58:08 +0100, Chris <xxx.syseng.yyy@gfsys.co.uk> > wrote: > >> Had a look at the ST code examples and their obscure header file >> mess for cortex years ago. Our way or the highway and unusable >> as presented. Code examples were rubbish as well. May be better >> now, but still useless if you have a house standard for form and function... > > We agree. In the end we wrote a (sort of) parser for ARM's SVD file > format to produce our header file equivalents. Several others have > gone down this route too.
Tell me more. what are these SVD files and where can I get some? Clifford Heath.
On Wednesday, April 8, 2020 at 7:39:05 PM UTC-4, Clifford Heath wrote:
> On 9/4/20 6:49 am, Stephen Pelc wrote: > > We agree. In the end we wrote a (sort of) parser for ARM's SVD file > > format to produce our header file equivalents. Several others have > > gone down this route too. > > > Tell me more. what are these SVD files and where can I get some? > > Clifford Heath.
What's it worth to you Cliff?
On 9/4/20 10:59 am, Dave Nadler wrote:
> On Wednesday, April 8, 2020 at 7:39:05 PM UTC-4, Clifford Heath wrote: >> On 9/4/20 6:49 am, Stephen Pelc wrote: >>> We agree. In the end we wrote a (sort of) parser for ARM's SVD file >>> format to produce our header file equivalents. Several others have >>> gone down this route too. >> >> >> Tell me more. what are these SVD files and where can I get some? >> >> Clifford Heath. > > What's it worth to you Cliff?
:) Well, I've done a lot of parsing and code generation, and I also hate the manufacturer libraries and header files. I haven't yet launched into building my own ARM infrastructure libraries, but I've often considered doing that. I hadn't come across these SVD files before. Of course, I wrote the above message *before* using Google :) CH
On Thu, 9 Apr 2020 09:39:01 +1000, Clifford Heath <no.spam@please.net>
wrote:

>>> Had a look at the ST code examples and their obscure header file >>> mess for cortex years ago. Our way or the highway and unusable >>> as presented. Code examples were rubbish as well. May be better >>> now, but still useless if you have a house standard for form and function... >> >> We agree. In the end we wrote a (sort of) parser for ARM's SVD file >> format to produce our header file equivalents. Several others have >> gone down this route too. > > >Tell me more. what are these SVD files and where can I get some?
SVD is a format promoted by ARM for CPU description. It's an XML format. AFAIR ARM keeps a collection of these files, and ST usually provide them. See: https://community.st.com/s/question/0D50X00009XkWDkSAN/how-does-st-manage-svd-files Stephen -- Stephen Pelc, stephen@mpeforth.com MicroProcessor Engineering Ltd - More Real, Less Time 133 Hill Lane, Southampton SO15 5AF, England tel: +44 (0)23 8063 1441, +44 (0)78 0390 3612 web: http://www.mpeforth.com - free VFX Forth downloads
On 9.4.20 15:31, Stephen Pelc wrote:
> On Thu, 9 Apr 2020 09:39:01 +1000, Clifford Heath <no.spam@please.net> > wrote: > >>>> Had a look at the ST code examples and their obscure header file >>>> mess for cortex years ago. Our way or the highway and unusable >>>> as presented. Code examples were rubbish as well. May be better >>>> now, but still useless if you have a house standard for form and function... >>> >>> We agree. In the end we wrote a (sort of) parser for ARM's SVD file >>> format to produce our header file equivalents. Several others have >>> gone down this route too. >> >> >> Tell me more. what are these SVD files and where can I get some? > > SVD is a format promoted by ARM for CPU description. It's an XML > format. AFAIR ARM keeps a collection of these files, and ST usually > provide them. See: > > https://community.st.com/s/question/0D50X00009XkWDkSAN/how-does-st-manage-svd-files > > Stephen > >
The ARM files are only the smaller half of the whole story: on the chips there are also the manufacturer-provided peripherals, which, IMHO, are the more complicated to make the header files for. Anyway, I did it by hand. -- -TV
On 9/4/20 10:31 pm, Stephen Pelc wrote:
> On Thu, 9 Apr 2020 09:39:01 +1000, Clifford Heath <no.spam@please.net> > wrote: > >>>> Had a look at the ST code examples and their obscure header file >>>> mess for cortex years ago. Our way or the highway and unusable >>>> as presented. Code examples were rubbish as well. May be better >>>> now, but still useless if you have a house standard for form and function... >>> >>> We agree. In the end we wrote a (sort of) parser for ARM's SVD file >>> format to produce our header file equivalents. Several others have >>> gone down this route too. >> >> >> Tell me more. what are these SVD files and where can I get some? > > SVD is a format promoted by ARM for CPU description. It's an XML > format. AFAIR ARM keeps a collection of these files, and ST usually > provide them. See: > > https://community.st.com/s/question/0D50X00009XkWDkSAN/how-does-st-manage-svd-files
Thanks. Something to reach for when I'm back in this ball-park again. CH
On 2020-04-08 Tauno Voipio wrote in comp.arch.embedded:
> > At least Atmel and ST made the mistake by attempting to > cover all the processors types with one set of sources. > > This led to a sorry mess of conditional code, which is > undecipherable even for a seasoned programmer. (me: > over 50 years of embedded code).
Does anyone have experience with Renesas and their Synergy stuff? Did a workshop a while ago and this all seemed to work quite good. But ofcourse this was a prepared workshop example that was bound to work. Did not have a chance to try it on a project of our own. We nowadays mostly use ST, so using something else must have huge advantages before we give it a try. ;-) -- Stef (remove caps, dashes and .invalid from e-mail address to reply by mail) FORCE YOURSELF TO RELAX!
On Thu, 09 Apr 2020 12:31:57 GMT, stephen@mpeforth.com (Stephen Pelc)
wrote:

>SVD is a format promoted by ARM for CPU description. It's an XML >format. AFAIR ARM keeps a collection of these files, and ST usually >provide them. See: > >https://community.st.com/s/question/0D50X00009XkWDkSAN/how-does-st-manage-svd-files
The specification (such as it is) is here: http://www.keil.com/pack/doc/CMSIS/SVD/html/index.html Stephen -- Stephen Pelc, stephen@mpeforth.com MicroProcessor Engineering Ltd - More Real, Less Time 133 Hill Lane, Southampton SO15 5AF, England tel: +44 (0)23 8063 1441, +44 (0)78 0390 3612 web: http://www.mpeforth.com - free VFX Forth downloads

The 2024 Embedded Online Conference