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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.66.118.134 with SMTP id km6mr48941703pab.37.1438273799342; Thu, 30 Jul 2015 09:29:59 -0700 (PDT) X-Received: by 10.140.98.117 with SMTP id n108mr648421qge.23.1438273799292; Thu, 30 Jul 2015 09:29:59 -0700 (PDT) Path: buffer2.nntp.dca1.giganews.com!border2.nntp.dca1.giganews.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!f3no4995793igg.0!news-out.google.com!78ni191qge.1!nntp.google.com!69no2846546qgl.1!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 30 Jul 2015 09:29:59 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=81.203.145.32; posting-account=AFCLjAoAAABJAOf_HjgEEEi3ty-lG5m2 NNTP-Posting-Host: 81.203.145.32 References: <2df4698f-4c8e-457c-822d-209cb2f8ab5e@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <76a06b25-96c1-49d2-8b88-e0a8ece98cc0@googlegroups.com> Subject: Re: Running a preprocessor from GPS? From: EGarrulo Injection-Date: Thu, 30 Jul 2015 16:29:59 +0000 Content-Type: text/plain; charset=ISO-8859-1 Xref: number.nntp.giganews.com comp.lang.ada:194531 Date: 2015-07-30T09:29:59-07:00 List-Id: On Thursday, July 30, 2015 at 6:14:52 PM UTC+2, Simon Wright wrote: > EGarrulo writes: > > > KISS solution: > > > > TickCount := (if System.FreeRTOS.Tasks.In_ISR > > then xTaskGetTickCountFromISR > > else xTaskGetTickCount) > > return Tick * Time_Base (TickCount); > > > > or: > > > > if System.FreeRTOS.Tasks.In_ISR then > > TickCount := xTaskGetTickCountFromISR; > > else > > TickCount := xTaskGetTickCount; > > end if; > > return Tick * Time_Base (TickCount); > > Both of these require Tick_Count (!) But then why did you write xTaskGetTickCountFromISR (!)? :D I know, I know: they must be system calls. I just went with what -- at first sight -- seemed your naming convention.