Getting PCIe Working On The New Pi 5

After the Pi 4 released, a discovery was quickly made that the internals of the popular single-board computer use PCIe to communicate with each other. This wasn’t an accessible PCIe bus normally available in things like desktop computers for expansion cards, though; this seemed to be done entirely internally. But a few attempts were made to break out the PCIe capabilities and connect peripherals to it anyway, with varying levels of success. The new Pi 5 seems to have taken that idea to its logical conclusion and included a PCIe connector, and [George] is showing us a way to interface with this bus.

The bus requires the port to be enabled, but once that’s done it’s ready to be used. First, though, some support circuitry needs to be worked out which is why [George] is reverse engineering the system to see what’s going on under the hood. There are a few handshakes that happen before it will work with any peripherals, but with that out of the way a PCIe card can be connected. [George] removed the connector to solder wires to the board directly in order to connect a proper PCIe port allowing a variety of cards to be connected, in this case a wireless networking card and an old Firewire card. This specific build only allows Gen 1 speeds, but the bus itself supports faster connections in theory with better wiring and support circuitry.

While it might not be the prettiest solution, as [George] admits, it does a great job of showing the inner workings of this communication protocol and its use in the new, more powerful Raspberry Pi 5. This makes a lot of things more accessible, such as high-speed PCIe HATs allowing for a wide range of expansion for these popular single-board computers, which wouldn’t have been possible before. If you’re still stuck with a Pi 4, though, don’t despair. You can still access the PCIe bus on these older models but it’ll take a little bit more work.

Thanks to [CJay] for the tip!

Continue reading “Getting PCIe Working On The New Pi 5”

Teensy Stands In For The Motorola 68k

While it might not seem like it today, there was a time in the not-too-distant past where Motorola was the processor manufacturer. They made chips for everything, but the most popular was arguably the 68000 or 68k. It’s still has a considerable following today, largely among retrocomputing enthusiasts or those maintaining legacy hardware. For those wanting to dip their toes into this world, this Motorola 68000 emulator created by [Ted Fried] may be the thing needed to discover the magic of these once-ubiquitous chips.

The emulator itself runs on a Teensy 4.1, a 32-bit ARM microcontroller running at 600 MHz — giving it enough computing power to act as a cycle-accurate emulator not only for the 68000 CPU but also the local bus interface, in this case for a Mac 512K. This capability also makes it a drop-in replacement for the 68000 in these older Macs and the original hardware in these computers won’t notice much of a difference. A few tricks are needed to get it fully operational though, notably using a set of latches to make up for the fact that the Teensy doesn’t have the required number of output pins to interface one-to-one with the original hardware.

While the emulator may currently be able to replace the hardware and boot the computer, there is still ongoing development to get every part of the operating system up and working. The source code is available on the project’s GitHub page though so any updates made in the future can be found there. And if you have a Mac 128k and still haven’t upgraded to the 512k yet, grab one of these memory switching modules for the upgrade too.

Continue reading “Teensy Stands In For The Motorola 68k”

Four jumper wires with white heatshrink on them, labelled VCC, SCL, SDA and GND

Three Pitfalls In I2C Everyone Wishes Weren’t There

The best part of I2C is that it is a bus that is available just about anywhere, covering a vast ecosystem of devices that offer it as a hardware-defined interface, while being uncomplicated enough that it can also be implemented purely in software on plain GPIO pins. Despite this popularity, I2C is one of those famous informal standards that feature a couple of popular implementations, while leaving many of the details such as exact timing, bus capacitance and other tedious details to the poor sod doing the product development. Thus it is that we end up with articles such as a recent one on the tongue-twisting [pair of pared pears] blog, covering issues found while implementing an I2C slave.

As with any shared bus, whether multi-master or not, figuring out when the bus is clear is a fun topic, yet one which can cause endless headaches. One issue here comes from a feature that the SMBus version of I2C calls quick read/write. This allows for the rapid transfer of some data. Still, depending on the data returned by the slave, it may appear to the master that nothing is happening yet, since SDA is being held low by the slave until the stop condition, essentially locking the bus.

I2C hold times example.
I2C hold times example.

Where things get even more exciting comes generally in the form of what logic analyzers love to traumatically call a ‘spurious start/stop condition’. This refers to the behavior of SDA and SCL, with SDA going low before SCL indicating an error. This can occur due to a hold time that’s too low, causing other devices on the bus to miss the transition. Here SMBus defines a transition time of 300 ns, while I2C calls for 0 seconds, but it’s now suggested to delay calling a start/stop condition until a delay of 300 ns has passed. Essentially, it would seem that implementing a hold time is the way forward until evidence to the contrary appears.

The third pitfall pertains to the higher-speed modes of I2C, including Fast-Mode (FM) and Fast-Mode Plus (FM+). Backward compatibility with these higher speed versions is absent to spotty. Although FM+ (introduced by NXP in 2007) is supposed to be backward compatible with slower speeds, effectively the timing requirement differences between the FM+ and FM standards are too large to compensate for. At least in the current versions of the standards, but one of the joys of I2C is that there’s always another new set of revisions to look forward to.

Interlaken Want To Connect All The Chips

One of the problems with designing things on a chip is finding a good way to talk to the outside world. You may not design chips yourself, but you care because you want to connect your circuits — including other chips — to the chips in question. While I2C and SPI are common solutions, today’s circuits are looking for more bandwidth and higher speeds, and that’s where Interlaken comes in. [Comcores] has an interesting post on the technology that blends the best of SPI 4.2 and XAUI.

The interface is serial, as you might expect. It can provide both high-bandwidth and low-latency multi-channel communications. Interlaken was developed by Cisco and Cortina Systems in 2006 and has since been adopted by other industry-leading companies. Its latest generation supports speeds as high as 1.2 Tbps.

Continue reading “Interlaken Want To Connect All The Chips”

Electric Volkswagen Adds Rooftop Solar

Volkswagen has continually teased the release of a new Microbus in the same way that Duke Nukem Forever strung us all along in the 00s, but unlike the fated video game it seems as though Volkswagen is finally building a hip new van rather than continually teasing its release year after year. With the clunky name of I.D. Buzz, European drivers can expect to see them later this year while those in the North American market will have to wait until 2024. That release will have a camper-equipped option though, but you may also want to equip yours with some solar panels as well.

The German tuning shop ABT is behind this design, which adds 600 watts of solar fixed to the top of the van. The solar roof will generate electricity largely to power the van’s auxiliary systems and is being aimed at those who are looking to outfit this van as a camper and need something to power things like refrigerators, interior lighting, and various electronics while on extended stays. There is also some mention of a 1000 watt option but with the limited space available on the roof may involve a side panel of some sort.

ABT is also noting that this system can be used to extend the driving range and, while technically true, don’t expect to be driving an I.D. Buzz on entirely solar power unless you’re willing to let it sit to charge the battery for days at a time. Like other solar installations on vehicles we’ve seen from various ingenious builders, the lack of real estate available on passenger vehicles limits their use largely to auxiliary electrical loads, but it can be possible to drive a vehicle on solar energy alone with the right design.

Driverless Buses Take To The Road In Scotland

Scotland! It’s the land of tartans, haggis, and surprisingly-warm kilts. It’s also ground zero for the first trial of full-sized driverless buses in the United Kingdom.

It’s not just automakers developing driverless technologies. Transit companies are desperate to get in on the action because it would completely upend their entire existing business structure. Now that self-driving buses are finally approaching a basic level of competence, they’re starting to head out to haul passengers from A to B. Let’s look at how the UK’s first driverless bus project is getting on out in the real world. 

Continue reading “Driverless Buses Take To The Road In Scotland”

Coils In The Road Could Charge EVs While Driving

One of the primary issues with EVs is that you need to pull over and stop to get a charge. If there isn’t a high-speed DC charger available, this can mean waiting for hours while your battery tops up.

It’s been the major bugbear of electric vehicles since they started hitting the road in real numbers. However, a new wireless charging setup could allow you to juice up on the go.

Electric Highways

Over the years, many proposals have been made to power or charge electric vehicles as they drive down the road. Many are similar to the way we commonly charge phones these days, using inductive power transfer via magnetic coils. The theory is simple. Power is delivered to coils in the roadway, and then picked up via induction by a coil on the moving vehicle.

Taking these ideas from concept into reality is difficult, though. When it comes to charging an electric vehicle, huge power levels are required, in the range of tens to hundreds of kilowatts. And, while a phone can sit neatly on top of a charging pad, EVs typically require a fair bit of ground clearance for safely navigating the road. Plus, since cars move at quite a rapid pace, an inductive charging system that could handle this dynamic condition would require huge numbers of coils buried repeatedly into the road bed. Continue reading “Coils In The Road Could Charge EVs While Driving”