M.2 Hacker – Expand your laptop

M.2 Hacker – Expand your laptop

M.2 Hacker – Expand your laptop

You’ve already seen M.2 cards in modern laptops. If you’re buying an SSD today, it will most likely be an M.2. Many of our laptops have M.2 WiFi cards, consumer oriented WWAN cards now come in M.2, and every now and then we see M.2 cards that defy our expectations. Nowadays, using M.2 is one of the most effective ways to add new features to your laptop. I found the M.2 standard to be quite accessible and hackable too, and I’d like to point this out to you.

If you’ve ever searched the web trying to understand what makes M.2 tick, you’ve probably found one of the many confusing articles that just copy things out of a PDF of an M.2 specification, and make things seem more complicated than they are In fact . Let’s instead take a look at the real world use of M.2. Today, I’ll show you the M.2 devices you’ll encounter in the wild, and teach you what you need to know to take advantage of them. In Part Two, I’ll show you how to create your own M.2 cards and card acceptors too!

Well-thinking, mostly

You can really appreciate the M.2 standard once you start looking at it, especially if you’ve worked with mPCIe hardware for some time. mPCIe is what we’ve been using all these years, and it’s gradually becoming a patchwork of incompatible pinouts. As manufacturers have thought about all kinds of hardware they could include, you’ll find breakthroughs like mSATA and WWAN coexistence extensions, and a noticeable lack of standardization in things like mPCIe WWAN modems once you need something like UART or PCM. The M.2 specification, fortunately, accounted for all of these lessons.

The M.2 standard is designed with real-world use cases in mind and selects as many pins as possible, making sure that cards of the same purpose from different manufacturers can be replaced with one another. It’s broken down into different keys that each serve a purpose – like directed storage keys, WWAN, WiFi, and other purpose keys. Each key defines a pinout for a set of interfaces such as PCIe, USB 2.0 or 3.0, SATA, I2C, DisplayPort, etc. Most of these interfaces are, of course, very tasty for a hacker.

No card or socket is required to support all interfaces defined in the switch’s pinout, or any particular interface. This makes sense if you’re designing systems – a lot of specific interfaces are situational or expensive. However, of course, it can cause confusion of the “fits, but doesn’t work” type of confusion. For example, a SATA SSD with a B+M switch will only work in some NVMe switch sockets, and some proprietary standards like CNVi put a wrench in the concept of “any M.2 WiFi card will work with your laptop”.

Some M.2 cards may look flippable, but they aren’t

However, in real-world use there are fasteners you can rely on – if you see an M-key, A-key, or E-key slot, it has a PCIe, if you see a B-key, A-key, or E-key slot, it has USB 2.0; And if you have schematics or a few M.2 hardware on hand, you can quickly test the compatibility of any given slot. There are also I2C SDA and SCL pins defined on all switches, but whether they’re connected to anything at all is a 50/50 chance, and apparently depends on the moon phase of the exact day when the laptop’s motherboard was designed.

b + m? The M.2 standard allows for switches on cards to be combined, allowing the card to fit two different socket types and increasing the compatibility of your card. There are two groups you will see – B + M and A + E, which are used for SSDs and WiFi cards respectively, and the key pins B, M, A and E are designed around these two groups. You lose some optional features, but important items like PCIe remain accessible. As an aside, while it may seem that you can insert a B+M SSD upside down if you apply enough force, or push an M-key card into the B-key socket, not only will it not work, it will reverse the polarity of the input voltage and there may be fiery consequences . Even with these few hiccups, M.2 is more logical and powerful than mPCIe ever.

stick of solid state

Two B+M SSDs – one SATA and one NVMe via PCIe 2x connection

The most common are M.2 SSDs. They are either SATA or NVMe – the latter is a storage interface that uses PCIe as a physical layer. We’ve talked about Internal NVMe In depth, feel free to check it out. SATA SSDs usually use a B + M key – some are only a B key, but they are rare. NVMe SSDs usually use an M key, some use a combination of B+M and are therefore limited to two PCIe lanes, you’ll see this with cheaper SSDs.

An SSD can only support one of these standards – not both at all. It can be hard to tell which is which, so if there is no NVMe or SATA logo on the label, look up the model number. If you have an SSD on hand or get some high-resolution photos, look up the number of differential pairs. If there are only two of them, then it is SATA; If there are three, five, or nine of them, it’s NVMe. Statistically, you are more likely to see NVMe SSDs, as they are becoming increasingly abundant.

M-key or B-key port may support both or only one of them. In ports B and M, there is a specific pin to distinguish between PCIe and SATA SSDs, and if the host supports both standards, it will automatically switch between them. With some laptops, it can be difficult to know whether or not an M.2 SATA SSD will be supported — NVMe, by contrast, is a safe bet, as it is rarely unsupported. And if you have a simple external adapter that only has a PCIe connector or a SATA connector, it will only support this type of SSD.

All ways to do WiFi

M.2 WiFi uses A or E keys – Most WiFi cards you’ll see will use a combined A+E switch, sockets are used as an A key but nowadays an electronic key is the norm. You get 1x PCIe link and USB 2.0, with the former using physical WiFi and the latter using Bluetooth. In both A and E switches, you get a second PCIe 1x jumper – not a link, a link! – But it’s rare that you see sockets connecting it, and then it is Hard to find hosts For cards like this Google Coral Dual TPU Accelerator. Compared to mPCIe, uFL antenna connectors are no longer – they are MHF3, also known as wFL, So you may need some new antenna hardware.

Not all built-in WiFi cards work on PCIe, of course – the electronic key pin also represents SDIO WiFi cards. SDIO is an embeddable interface mostly used for SD cards and WiFi chip connections – for example, on boards like the Raspberry Pi. Few cards and transformers seen there Using the electronic key, with hackers who haven’t started yet Eyebrows raised. Given how easy it is to design your own M.2 cards, we hope to see M.2 SDIO WiFi cards become more popular one day – maybe then, Pine64 won’t design Weird WiFi units.

Half size WiFi card on the top, 1216 M.2 WiFi module on the bottom

It’s rare to see electronic key cards or a pure A-key – one of the exceptions, CNVi, It uses the E key, which is not the good kind of exception. it’s a Owned by Intel only An interface derived from M.2 that allows the chipset to do most of the WiFi work it used to do on PCIe WiFi cards. These damn M.2 WiFi cards not only work with AMD processors or older laptops, there are two versions of CNVi and they have Neither backward nor forward Compatibility which leads to user confusion, Additional expenses and e-waste. There is one temporary upside – slots usually connect both CNVi and PCIe + USB2, so you could theoretically use a CNVi card, and then get additional internal PCIe and USB links for your hacking purposes.

There are two somewhat wacky WiFi card form factors you may encounter. First of all there is a WiFi card of fun size for the e-key – made possible because a large part of the pinout is unused by default. It just got more fun but not necessarily fun, you’ve probably seen these protected little units soldered in ultrabooks. This, too, is an M.2 form factor, called 1216. It’s weldable and therefore not easily upgradeable, but with the predefined pinout all together. Sadly, these units also come in a variety of CNVi – on the upside, it’s not like you’ll be exchanging these cards often.

Go around the world with B-Key

Project ready 4G USB modem at cheap price

If you need a cheap USB-connected 4G modem with decent Linux support for your project, you can’t go wrong with a used M.2 B-key modem, which usually comes in the form of a Model 3042, being 30mm wide. A lot of these cards are made for laptops with WWAN connectivity, and the flea market has very low prices. Most are USB 2.0, with some USB 3.0 cards available – for either of them you can find USB plug-in spacers online, there are some Open source beer escape There is, too.

These go to B-key slots on laptops – of all the available M.2 slots, this is the most “wild west” slot you can rely on only having USB 2.0 – everything else varies wildly. The standard specifies quite a few other features – some B-key slots have extra SATA, some have extra PCIe, and some have both SATA and PCIe switchable by the same use of M-key SSDs for PCIe/configuration SATA. Sometimes there is USB 3.0 as well, but there is no guarantee. You’ll definitely have USB 2.0 for your modem, but for any other devices like SSDs, you’ll have to google your laptop’s model number with ‘can I put an SSD in key slot B’ queries.

Unfortunately, if your laptop doesn’t have a WWAN option, not only may the WWAN antennas be absent, but the B key socket on the motherboard may not be soldered either – it’s a weird and frustrating assembly selection to counter that hinders upgradability, but I guess it’s not Do anything with mPCIe. On the plus side, if you have a B key slot, you don’t have to limit yourself to SSDs and WWAN cards – for example, here’s open source USB 2.0 connected RP2040-based M.2 expansion card by [Timonsku]And the Probably a fun upgrade for your laptop!

M.2: Sophisticated, Always Present, Here To Stay

Some parts of the M.2 standard are fading into obscurity, and they are no longer accessible on the laptops out there – if they existed in the first place. If you want to get down to it, the M.2 Electromechanical Specification Rev1.0 document can be found online, and you can learn a lot from its 201 pages. For example, you’ll find that the F key is reserved for some obscure thing called the Future Memory Interface, and no doubt the Intel project on the shelf is only described on some Blogspot pages that Google doesn’t index anymore.

For more realistic but no less fun parts, there was a standard called WiGig, and some ThinkPads even revealed a DisplayPort connector on the A-key WiFi slot for that — along with actually making use of the second PCIe link on the A-key I mentioned above. Apparently, you could have wireless laptop docks, with DisplayPort and USB3.0 connectivity giving you plenty of hardware without a cable in sight. Here are some interesting pictures of WiGig’s internal parts – The receiver inside the dock is actually the M.2 G-key card itself. You can even find docking cards on eBay, as a piece of fairly recent computing history.

You’ll find M.2 basically everywhere. It has a lot of hidden potential, and if we need to take advantage of that, it will help you figure out how to use it out there in the wild. Even if you’ve never been designing an M.2 card, now you know how to distinguish between SATA and NVMe M.2 SSDs, and why pushing a B-key 4G card into your M-key SSD slot won’t do anything good. In the following article, I will show you how to design an M.2 card or put an M.2 socket on your board as well!

#M.2 #Hacker #Expand #laptop

مقالات ذات صلة

اترك تعليقاً

لن يتم نشر عنوان بريدك الإلكتروني. الحقول الإلزامية مشار إليها بـ *

شاهد أيضاً
زر الذهاب إلى الأعلى
سيتات آورج 2022 سيتات آورج 2022