From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: buffer2.nntp.dca1.giganews.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news.glorb.com!feeder.erje.net!1.eu.feeder.erje.net!eternal-september.org!feeder.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: setting an address with pure? Date: Tue, 14 Jul 2015 08:38:36 +0100 Organization: A noiseless patient Spider Message-ID: References: <2a4e8a0e-312c-4c99-977c-a1d1f41c3226@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: mx02.eternal-september.org; posting-host="c762050aff3a30866fa7e79999b14776"; logging-data="17780"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18DvpPOBv9Tiat34axZA1eOuABuzgWyEZY=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (darwin) Cancel-Lock: sha1:5/OXqRQ8CYJIvy75c7S/oh3OXKo= sha1:uNtB3SMGcmZPPbJwFMtOfqG8+ag= Xref: number.nntp.giganews.com comp.lang.ada:194118 Date: 2015-07-14T08:38:36+01:00 List-Id: "RasikaSrinivasan@gmail.com" writes: > Does it have to be pure? > > I use Pragma Restrictions( No_Elaboration_Code ); I don't have any objection to elaboration code per se, I just wanted to get as near to Pure as I could. I did use that restriction for a Cortex Reset_Handler, which is called by the hardware before any elaboration occurs at all. > then : > > DACMAP : DAC_CR_Type > with Volatile , > Address => System'To_Address( 16#NNNN_NNNN# ) ; > > I am not sure if this is what you are aiming for but appears to work > so for. NNNN_NNNN above is the base address of the DAC map as provided > by the STM32 Ref Manual. This was just what I wanted, thanks very much! This is actually in the secret documentation: I would refer to the gcc.gnu.org version, but it's unreachable at this moment. http://docs.adacore.com/gnat_rm-docs/html/gnat_rm/gnat_rm/implementation_defined_attributes.html#attribute-to-address