[HN Gopher] An interactive-speed Linux computer made of only 3 8...
       ___________________________________________________________________
        
       An interactive-speed Linux computer made of only 3 8-pin chips
        
       Author : dmitrygr
       Score  : 112 points
       Date   : 2025-04-04 19:22 UTC (3 hours ago)
        
 (HTM) web link (dmitry.gr)
 (TXT) w3m dump (dmitry.gr)
        
       | classichasclass wrote:
       | This pleasantly reminds me of the little 6502 or 1802 Altoids-tin
       | computers you can buy and assemble, but arguably more "useful"
       | (though I get a lot of use out of a 6502 ;-).
        
         | SpaceNoodled wrote:
         | What do you do with your 6502?
        
       | FirmwareBurner wrote:
       | I knew it was gonna be dimitry from reading the title
        
         | dmitrygr wrote:
         | Not sure if compliment or insult :)
        
           | yapyap wrote:
           | lol I'd assume a compliment!
        
           | blacklion wrote:
           | Definitely compliment! At least, if it was my comment with
           | exactly same text
        
           | rhelz wrote:
           | Like somebody said in response to a paper which was
           | anonymously published by Newton: "I recognize the Lion from
           | his claw!"
        
       | yapyap wrote:
       | > There was a time when one could order a kit and assemble a
       | computer at home
       | 
       | I think I get what OP means but you can definitely order a pc kit
       | and just assemble it nowadays
        
         | dmitrygr wrote:
         | Not in the same way. Not with a soldering iron and schematics.
        
           | mrguyorama wrote:
           | I recognize there is something hard describe about how "it's
           | not the same", but:
           | 
           | https://eater.net/shop
        
             | dmitrygr wrote:
             | Yes, but sadly that cannot run modern Linux
        
       | dvh wrote:
       | Please tell me you didn't use ENIG for the USB connector. It
       | would be sacrilege.
        
         | dmitrygr wrote:
         | I am just a lowly software guy who pretends to know how to use
         | EAGLE. To me "ENIG" just means "5% more expensive boards". What
         | did I miss?
        
       | myself248 wrote:
       | I have the perverse urge to forego even the board, and just make
       | this a circuit sculpture.
        
         | dmitrygr wrote:
         | Do it!
         | 
         | I am not an artist or a sculptor so I did not dare try
        
       | alnwlsn wrote:
       | It's almost 2 chips. One is just a USB-serial IC! But you didn't
       | count the SD card, so you're up to 3 again.
       | 
       | Total pin count is so low on this, I'm very tempted to make a
       | dead bug version.
        
         | dmitrygr wrote:
         | I didn't make a dead bug version so you'd be first :). Microsd-
         | to-sd adapters make good solderable microsd holders.
        
         | blacklion wrote:
         | USB2Serial IC could go to the cable made by others and "doesn't
         | count" as uSD doesn't count.
        
       | zokier wrote:
       | I think it would be cute to also use 8 pin SPI flash chip instead
       | of SD card for storage.
        
         | dmitrygr wrote:
         | Looked into it. But then the "getting files in and out" story
         | gets hard.
        
           | mystified5016 wrote:
           | I'd be very surprised if there isn't a filesystem driver for
           | SPI flash. Linux obviously can speak SPI and SPI flash is
           | extremely common in a lot of applications.
        
             | dmitrygr wrote:
             | I mean once assembled. In my design you can remove card,
             | put files in, boot again, use the files.
        
               | ajb wrote:
               | Theoretically you can use one of these:
               | https://www.tindie.com/products/bobricius/micro-sd-card-
               | to-s...
               | 
               | I haven't tried it so I don't know how well it works
        
       | em3rgent0rdr wrote:
       | I'm always a bit saddened to see that a separate chip is the go-
       | to method to interface with USB. Unfortunately USB is an
       | incredibly-complex protocol that it seems anything beyond a basic
       | V-USB running USB 1.1 at low-speed is generally not doable
       | without specialized hardware and a significant software stack.
       | Meanwhile a protocol like SPI is ridiculously simple...the
       | minimum hardware needed is a shift register that can be clocked
       | fast enough. I miss how desktop and labtops used to have an
       | exposed serial and parallel port, which could communicate at this
       | low level. I often wonder if instead of USB existing that we
       | instead stuck with UART, I2C, or SPI multidrop (using a small set
       | of standard clock rates) for simple peripherals (maybe over a
       | single connector like the 4-pin JST SH cable for Stemma QT, Qwiic
       | and Grove) over a short distance, and then jumped to IEEE 802.3
       | Ethernet links for data-heavy peripherals like monitors and
       | external drives. Then instead of having to have separate support
       | for USB and Ethernet, you just would support Ethernet links.
        
         | tylerflick wrote:
         | I mean technically you have all of these interfaces on a
         | raspberry pi.
        
         | parl_match wrote:
         | i mean... someone did try this with i2c. a couple of dead
         | computer companies shipped a bus that i forget the name of,
         | based on this concept. its descendant is the vga hdmi control
         | channel spec (which was implemented as a de facto separate
         | standard but is very similar)
         | 
         | the name is escaping me
        
           | kps wrote:
           | ACCESS.bus by Philips (who developed I2C) and DEC, and the
           | DEC variant SERIAL.bus (with different voltage levels) used
           | by their keyboards and mice for a little while.
        
         | pantalaimon wrote:
         | There are plenty of MCUs that will work as a USB device, they
         | were just ruled out by the package restriction.
        
         | mystified5016 wrote:
         | So you want to replace a USB PHY with a serial to Ethernet
         | converter and an Ethernet PHY.
         | 
         | The reality is that the simple protocols like SPI and I2C just
         | are not good enough. They aren't fast, the single-ended signal
         | scheme makes them _very_ sensitive to noise, and there is no
         | error correction. These protocols make sense and work extremely
         | well for their intended purpose: connecting ICs on a PCB. If
         | you expose an unterminated port to the outside world, all bets
         | are off.
         | 
         | These protocols and variations thereof are still in heavy use
         | in modern PCs. But they're _internal_ busses, as the protocols
         | intend.
         | 
         | I haven't looked closely at the USB spec, but I imagine the
         | main problem with bit-banging is simply the speed required. You
         | _have_ to have dedicated hardware because no microcontroller is
         | fast enough to toggle the pins while also running the software
         | stack to decode the protocol and manage error correction.
         | 
         | You can run into this exact problem bit-banging I2C. With a
         | 20MHz CPU, the maximum clock speed you can get is about 250KHz.
         | Just a bit more than half the typical maximum rate of 400KHz.
         | You can absolutely forget about the 1MHz version.
         | 
         | PHYs exist for one very good reason: it is _vastly_ cheaper to
         | offload comms protocols to hardware. Without that, you have to
         | over-spec your CPU by quite a lot to get enough resources to
         | manually manage communication. This is why every modern
         | microcontroller contains hardware for I2C, SPI, serial, etc.
         | 
         | In summary, the simple serial protocols like SPI and I2C and
         | UART are just absolutely terrible choices for external
         | peripherals. They can't operate at reasonable speeds, they
         | can't tolerate long cables, they can't tolerate noise. The
         | nature and design of these protocols (excepting RS232 which is
         | _not_ UART) means that they cannot be used this way. There 's
         | no change to the spec you could make to support this without
         | reinventing USB.
        
           | Skunkleton wrote:
           | USB is also tough to bitbang also it has pretty strict timing
           | requirements. Compared to something like i2c where the clock
           | only advances when the pin is explicitly toggled.
        
           | fxtentacle wrote:
           | UART over LVDS is still quite simple and works well for long
           | cables and it tolerates ground differences and noise well.
        
         | topspin wrote:
         | > Meanwhile a protocol like SPI is ridiculously simple
         | 
         | Yes, it is. It was intended to require as little silicon as
         | possible to minimize the cost to the transistor budget. SPI
         | doesn't contemplate power supply, hot-plug, discovery, bit
         | errors, or any other of a host of affordances you get with USB.
         | 
         | I think there is some value for software developers to
         | understanding SPI and the idioms used by hardware designers
         | with SPI. Typically, SPI is used to fill registers of
         | peripherals: the communication is not the sort of high level,
         | asynchronous stuff you typically see with USB or Ethernet and
         | all the layers of abstraction built upon them. Although there
         | is no universal standard for SPI frames, they do follow
         | idiomatic patterns, and this has proven sufficient for an
         | uncountably vast number of applications.
        
       | coupdejarnac wrote:
       | Under parts selection.. Even considering the PIC 16F. Why.
        
         | dmitrygr wrote:
         | Every 8 pin MCU was given a shot
        
       | rhelz wrote:
       | Was there no native ARM linux you could have used? As I recall,
       | you have used this emulated MIPs technique in many of your
       | published projects, so it's good to prove that the hardware is
       | working?
       | 
       | Or why not just go full native....grab some MIPS-core IP and make
       | your own with an FPGA?
        
         | dmitrygr wrote:
         | Because no FPGAs come in 8-pin packages
         | 
         | And no Linux runs on cortex-m0 with ram attached over SPI.
         | 
         | And MIPS is the easiest Linux-compat architecture to emulate.
        
       | nine_k wrote:
       | > _So, which pins could be combined with SDIO 's three? After
       | much thinking, the solution is obvious. RAM's_ nCS _can be the SD
       | card 's_ CLK. _RAM 's_ CLK _can be the SD card 's_ CMD. _RAM 's_
       | MOSI _can be the SD card 's_ DAT. _Try and figure out all the
       | possible interactions with each device and what that would look
       | like to the other, to convince yourself that it will work
       | safely._
       | 
       | This is truly a brilliant hack, well worth publishing at _Hacker_
       | News.
        
       ___________________________________________________________________
       (page generated 2025-04-04 23:00 UTC)