Deutsch English Français Italiano |
<vbvi0n$djla$1@dont-email.me> View for Bookmarking (what is this?) Look up another Usenet article |
Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: piglet <erichpwagner@hotmail.com> Newsgroups: sci.electronics.design Subject: Re: port pins Date: Thu, 12 Sep 2024 20:13:11 -0000 (UTC) Organization: A noiseless patient Spider Lines: 46 Message-ID: <vbvi0n$djla$1@dont-email.me> References: <o6c1ej93onsiugcs1m0f6v6d6scff60rpi@4ax.com> <vbvh6a$ddqv$1@dont-email.me> <vbvho1$dhlj$1@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Injection-Date: Thu, 12 Sep 2024 22:13:11 +0200 (CEST) Injection-Info: dont-email.me; posting-host="8b7f6ef5d0fc8febcc4778652cde8fa5"; logging-data="446122"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19ohvBI+XkdE4IF/Wklfk4c" User-Agent: NewsTap/5.5 (iPhone/iPod Touch) Cancel-Lock: sha1:QPlIYZS5In/GfzNRjv4PwDK2vPs= sha1:MRZ1Qqmp3EpqLR6CpPOvHfHoL/U= Bytes: 2608 Phil Hobbs <pcdhSpamMeSenseless@electrooptical.net> wrote: > piglet <erichpwagner@hotmail.com> wrote: >> john larkin <jl@650pot.com> wrote: >>> Something I've wondered about: >>> >>> Suppose we have a c program running on some little uP, and it has some >>> integer variable value, 8 or 12 bits or something, and wants to drive >>> a parallel DAC off-chip. >>> >>> The msb...lsb bits of the variable obviously have to get to the right >>> pins of the DAC. >>> >>> So, in general, how does one pick the physical i/o port pins on the >>> uP, to get the order right? The PCB layout is easiest if we just wire >>> the DAC to the handiest port pins. >>> >>> One could test and bit-bang each bit and port individually, and then >>> strobe the DAC, but that's inelegant. >>> >>> In the RP2040 chip, one can apparently write to a register in a >>> PIO/state machine block, where each bit of the register can be >>> assigned to drive a physical port pin. I think there are some >>> constraints on the selected pins. >>> >>> >>> >> >> I didn’t know that now exists - but sounds super useful. Would have saved >> much headache if it had been around years ago. >> > > We sometimes use the LPC804, which has a gigantic pin mux—you can > effectively put any function on any pin. IIRC reset and isp are a bit > special, but all the gpio and built-in peripheral functions can be > configured any way you like. > > Cheers > > Phil Hobbs > Many thanks for the tip! Currently all my projects are AVR and PIC but the M0 could be next step up. -- piglet