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.2 required=5.0 tests=BAYES_00,FREEMAIL_FROM, FROM_STARTS_WITH_NUMS autolearn=no autolearn_force=no version=3.4.4 X-Received: by 2002:a05:6214:1634:: with SMTP id e20mr24675460qvw.205.1580249188878; Tue, 28 Jan 2020 14:06:28 -0800 (PST) X-Received: by 2002:a9d:6304:: with SMTP id q4mr18242667otk.332.1580249188499; Tue, 28 Jan 2020 14:06:28 -0800 (PST) Path: eternal-september.org!reader01.eternal-september.org!feeder.eternal-september.org!news.uzoreto.com!feeder1.cambriumusenet.nl!feed.tweak.nl!209.85.160.216.MISMATCH!g89no8723931qtd.0!news-out.google.com!w29ni839qtc.0!nntp.google.com!g89no8723922qtd.0!postnews.google.com!google-groups.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Tue, 28 Jan 2020 14:06:28 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: google-groups.googlegroups.com; posting-host=2001:8b0:ca:2:0:0:0:fd; posting-account=TiHetgoAAACluCgYkPc8-TWs6dBNgSne NNTP-Posting-Host: 2001:8b0:ca:2:0:0:0:fd References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <74d98654-5932-4fdb-8b1b-a1378bc3f853@googlegroups.com> Subject: Re: GNATCOLL-Mmap example From: Bob Goddard <1963bib@googlemail.com> Injection-Date: Tue, 28 Jan 2020 22:06:28 +0000 Content-Type: text/plain; charset="UTF-8" Xref: reader01.eternal-september.org comp.lang.ada:57980 Date: 2020-01-28T14:06:28-08:00 List-Id: On Tuesday, 28 January 2020 20:18:03 UTC, Philip Munts wrote: [...] > Here is a quick example using libsimpleio: > > WITH GPIO.libsimpleio; > WITH RaspberryPi; > > PROCEDURE test_gpio IS > > outp : CONSTANT GPIO.Pin := > GPIO.libsimpleio.Create(RaspberryPi.GPIO18, GPIO.Output); > > BEGIN > LOOP > outp.Put(True); > outp.Put(False); > END LOOP; > END test_gpio; > > On a Raspberry Pi 4, which is what happens to be plugged in today, I measured a 360 kHz square wave at GPIO 18. Never mess around with memory mapped I/O unless you need insanely high performance. Then you would probably want to use DMA anyway. Think I'll use that as a backup, but go down the ioctl route, it is a learning process after all...