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,WEIRD_PORT autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,8518fb63d2af28cf X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.68.125.233 with SMTP id mt9mr18585205pbb.5.1335860836750; Tue, 01 May 2012 01:27:16 -0700 (PDT) Path: r9ni118980pbh.0!nntp.google.com!news2.google.com!volia.net!news2.volia.net!feed-A.news.volia.net!newsfeed.utanet.at!texta.sil.at!news.nobody.at!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail From: Brian Drummond Newsgroups: comp.lang.ada Subject: Re: Tasking on GNATAVR Date: Tue, 1 May 2012 08:27:16 +0000 (UTC) Organization: A noiseless patient Spider Message-ID: References: <19355816.2739.1335755877395.JavaMail.geo-discussion-forums@ynlp3> <13692499.358.1335823673528.JavaMail.geo-discussion-forums@yncd9> Mime-Version: 1.0 Injection-Date: Tue, 1 May 2012 08:27:16 +0000 (UTC) Injection-Info: mx04.eternal-september.org; posting-host="DkTdSjxOCm6DqG+Uf7eArg"; logging-data="3504"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+yFjEVqGWsnAkB55b9k7NyTOpf8e6LKSs=" User-Agent: Pan/0.135 (Tomorrow I'll Wake Up and Scald Myself with Tea; GIT 30dc37b master) Cancel-Lock: sha1:kF8xMS7+qQoJQDWmlxsH0ug6RVg= Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Date: 2012-05-01T08:27:16+00:00 List-Id: On Mon, 30 Apr 2012 15:07:53 -0700, mjsilva wrote: > On Sunday, April 29, 2012 8:17:57 PM UTC-7, Rego, P. wrote: >> Ok, now I got to build and burn the .hex in an Arduino Duemilanove >> atmega328p totally in Ada using GPL GNATAVR in GPS, following >> http://student.agh.edu.pl/~mkucia/wiki/doku.php?id=avrada and much help >> from you guys. >> >> In short it consists of: >> 1) Converting a .xml (from AVR Studio) to the atmega328p package spec, >> which maps all the memory addresses of the chip (so I don't have to do >> it) >> 2) Using this spec package from a main file 3) GPS builds the .elf >> linking with a WinAVR object library 4) From command-line, convert the >> .elf in .hex and burn it into the chip using avrdude. >> >> Now a simple blink program runs quite well, so runs accordingly as I >> burn it and start the chip. >> >> At this point, we achieve the same coding paradigm than AVR Studio, but >> in Ada from GPS, not in C anymore. >> >> But now I want to include tasking on the code, and I did not find so >> many resources in documentation (actually I just found >> http://docs.adacore.com/gnat-cross-docs/html/gnat_ugx_12.html). Anyway, >> I included >> >> task My_Useless_Task; >> task body My_Useless_Task is begin >> null; >> end My_Useless_Task; >> >> and when I tried to build, builder returned me >> >> violation of restriction "No_Tasking" at system.ads:52 > >> So, what should I do to make the tasks work? > > AFAIK, there is no AVR Ada runtime, so it would have to be written. I > have no idea how much work that would be. Warren Gay reported success with experimental tasking on AVR some time ago, (about a year?) using the open source AVR-Ada toolchain (from Sourceforge). It was intended to be included in AVR-Ada 1.2 which is scheduled for release very soon, but I don't know if it's still included. Search for Warren's AVR-Ada posts for some more information, and keep eyes open for AVR-Ada 1.2. I haven't tried the Adacore version so I don't know how/if they inter- operate. - Brian