Close
0%
0%

Fluff M0

Cheapskate version of Adafruit Feather M0

Similar projects worth following

Adafruit makes really great prototyping boards, and especially their "Feather" series of boards is great. The pinout is actually designed, with a lot of thought put into it, and the boards are all top quality. They also contain a lot of stuff on them already, just in case you need it: LEDs, battery charger, debugging interface, STEMMA connectors, prototyping area, you name it. It means that while you are prototyping and you suddenly need any of this, it's there for you already and you don't have to go out of your way to find it. And the documentation is great as well, not to mention all the work that went into developing CircuitPython and a million libraries. But it comes at a price.

When you finish your project, and it turns out you don't need all those extra things in the end, it feels like a waste to leave that awesome (and relatively expensive) board in your project. That's why I'm making the Fluff. It has the same pinout as the feathers, but it literally only has five components on it — everything non-essential has been removed. Functionally it's a Trinket M0 with more pins and without the diodes. It's the cheapest possible Feather-compatible board that runs CircuitPython.

I'm making this for my own use, and I don't plan on selling it, but as usual all the design files are available, so you can make your own if you want to.

fluff_m0_v1.4.zip

Gerber files.

Zip Archive - 103.73 kB - 07/09/2020 at 16:31

Download

fluff_m0_v1.4.fzz

Fritzing design.

x-fritzing-fzz - 102.90 kB - 07/09/2020 at 16:31

Download

fluff_m0_v1.4_pnp.xlsx

Pick-and-place positions.

sheet - 5.55 kB - 07/09/2020 at 16:31

Download

fluff_m0_v1.4_bom.xlsx

Bill of materials.

sheet - 5.66 kB - 07/09/2020 at 16:31

Download

  • 1 × ATSAMD21E18A-MU microcontroller
  • 2 × 1µF 0604 capacitor capacitor
  • 1 × AP2112K-3.3TRG1 low drop-out voltage regulator
  • 2 × 5.1kΩ 0604 resistor
  • 1 × 1kΩ 0604 resistor

View all 6 components

  • Version 1.4

    deʃhipu21 hours ago 0 comments

    After the fail with missing pulld-downs on CC pins for USB-C, I re-designed the board a little bit:

    There are now contacts and pull-downs for the CC pins, and I also added a large prototyping area in the empty part of the board. The holes are now just on the silkscreen. This time the boards arrived in a few days:

    I put the address of my website on the other side, so that I can use the very flat board as a kind of business card:

    That's pretty much it. The new version works perfectly fine both with USB 2.0 and actual USB-C ports. I'm publishing the fritzing design file, the gerbers and the BOM, so that anyone can make their own — you can find them in the downloads section of this page.

  • Version 1.3 Testing

    deʃhipu07/02/2020 at 15:21 0 comments

    The PCBs arrived after their 3-week trip around the Europe, and as usual I assembled and tested one. The good news is that it works very well with any USB-A to USB-C cable. The plug is a bit wobbly, because there is no metal sleeve to stabilize it, but it doesn't disconnect or otherwise cause problems. The CNC router was even precise enough to mill the small teeth on the sides of the socket, so it goes in with a slight click. I'm pretty happy with that.

    The bad news is that it completely fails to work when connected to an actual USB-C socket with a proper USB-C cable. It simply doesn't receive any power. A little bit of research easily explains why: I didn't add pull-downs on the CC1 and CC2 pins, because I thought it's only needed for OTG devices. Turns out that the wording is a bit confusing, and it's required to have those resistors for USB 2.0 device to receive any power from an USB-C port.

    That means there will be version 1.4 of the board, and it means the parts count also raises — I need to squeeze 2 more resistors in there. I could probably get away with just one resistor — only one of CC1 or CC2 is ever connected — but I will make room for two, and use a bodge wire to see if it works also with one — I will need fewer prototypes that way.

  • Unexpected Delays

    deʃhipu06/23/2020 at 13:31 0 comments

  • Version 1.2

    deʃhipu06/14/2020 at 21:42 0 comments

    The PCBs for version 1.2 arrived from @oshpark now, and even though the version 1.3 will arrive tomorrow, I decided to assemble and test it. I used the nice clear soldermask on black FR4 option for the first time, and it does look pretty nice.

    The fix was simple enough, and now the SPI pins are correct and working. The next version will get rid of the micro-USB socket, and use a PCB socket for USB-C — we will see tomorrow how well that works.

  • Version 1.3 and USB Type-C

    deʃhipu06/03/2020 at 16:09 0 comments

    I'm still waiting for the PCB for the fixed version 1.2 from @oshpark, but in the meanwhile I had some ideas, both for improving the design, and for more use cases for this little board.

    The biggest part, apart from the microcontroller itself, and the only part I couldn't find in the @JLCPCB's parts library, is the USB socket. It sticks out of the PCB, it requires special handling, and it's the weakest spot from the mechanical point of view. It can also vary wildly in price, adding uncertainty to the pricing. So what are the alternatives?

    I remembered the experiments of @juan jesus with his PCB-based USB socket for his #Business Card Gamepad, and the tiny development boards sold by @bobricius that were inspired with it, and I had two realizations. First, I can do the PCB USB Type-C socket easily, especially since I already use the 0.6mm thick PCB.

    Second realization is about another use case for this. My main use case so far has been for personal use, because I need a board that breaks out all the pins of the QFN32 version of the SAMD21 chip, so that I can experiment with which pins can be used for what purposes in my projects. Plus I wanted something I could leave in finished projects without too much regret, and without coming back to them later to scavenge them for parts. Both those goals should be served well with the version 1.2, which breaks out three additional pins (AREF, A6 and D14), and only leaves one pin unused, but connected to a via, so I can still access it if I must (and it's a boring, GPIO-only pin). But now I have one more use case, that the new, flatter design should accommodate nicely: a business card.

    You see, with the whole back of the board free (and the holes plugged), I can put all my contact details on it. And then I can give those boards out to people who are interested in trying CircuitPython. I connected that last, usused, pin to a LED, so that the board can has something visible going on for it. I will probably write some kind of blinking program, that also uses the touch on analog pins for something (and maybe also the internal temperature sensor), so that the board is not boring with just power connected to it. And I can put a VCARD file with my contact details on its disk as well. And maybe some kind of text file with a CircuitPython primer and some links to the resources.

    I could also imagine a branded version of this board being a great giveaway on conferences and such.

  • Bootloader, Firmware and Version 1.2

    deʃhipu05/27/2020 at 00:05 0 comments

    The bootloader has been added to the Adafruit's fork, so now you can compile it yourself: https://github.com/adafruit/uf2-samdx1/pull/120

    Also, the board definition for CircuitPython has been added here: https://github.com/adafruit/circuitpython/pull/2945 — that assumes the correct SCK and MOSI pins, after swapping them.

    I ordered the corrected version 1.2 from OSHPark, and it's also available for order here: https://oshpark.com/shared_projects/SXflbZK4 — it's probably not the most price-efficient way to get it, if you panelize it and order from one of the cheap PCB fabs, you could get it really cheap, but with a really long wait.

    I even checked that JLCPCB has all the parts (except for the USB socket) in their library, so you could in theory get them to assemble it — except I have no idea how to convert Fritzing's pick-and-place file to one of the formats they require.

  • Oops!

    deʃhipu05/26/2020 at 01:14 0 comments

    Would you believe me if I told you that I made a pretty stupid (and easily avoided) mistake in this design? If you have followed any of my previous projects, this should be an obvious thing to you. Of course I made a stupid mistake, that's how I work after all! And you would be completely right! Here is a fragment of the schematic that I posted earlier, with one little detail marked in red. Does it strike it as somewhat odd, perhaps?

    Yes, I swapped MISO and SCK pins. No, any FeatherWing that uses SPI will not work with Fluff M0 v1.0 because of that. Sorry to anyone who used my gerbers. What can be done about it? Well, those are the tracks in real life:

    What can you do when your project has a mistake like that? There is only one thing left to do: scrape it. With a sharp knife. Like this:

    (Sorry for potatocam.) And then you solder some thin wires to it, like this:

    And then you fix the firmware and the gerbers:

    It's a bit sad, because it's actually easier to route the correct pins. Oh well. In any case, version 1.1 is here:

  • Assembled and Flashed

    deʃhipu05/22/2020 at 13:28 0 comments

    Since today is a holiday for me, I had the time to immediately assemble of Fluff M0 and flash it with the bootloader and CircuitPython. Since all pins, including the SWD and SWC are broken out, flashing is simple:

    You just have to connect 3V to VCC, GND to GND, SCK to SWC and MISO to SWD. Then a couple of terminal commands:

    $ JLinkExe -if SWD -device ATSAMD21E18 -speed 4000kHz
    SEGGER J-Link Commander V6.40 (Compiled Oct 26 2018 15:08:38)
    DLL version V6.40, compiled Oct 26 2018 15:08:28
    
    Connecting to J-Link via USB...O.K.
    Firmware: J-Link V10 compiled Oct 26 2018 12:04:17
    Hardware version: V10.10
    S/N: 50112638
    License(s): GDB
    VTref=3.290V
    
    
    Type "connect" to establish a target connection, '?' for help
    J-Link>connect
    Device "ATSAMD21E18" selected.
    
    
    Connecting to target via SWD
    InitTarget()
    Found SW-DP with ID 0x0BC11477
    Scanning AP map to find all available APs
    AP[1]: Stopped AP scan as end of AP map has been reached
    AP[0]: AHB-AP (IDR: 0x04770031)
    Iterating through AP map to find AHB-AP to use
    AP[0]: Core found
    AP[0]: AHB-AP ROM base: 0x41003000
    CPUID register: 0x410CC601. Implementer code: 0x41 (ARM)
    Found Cortex-M0 r0p1, Little endian.
    FPUnit: 4 code (BP) slots and 0 literal slots
    CoreSight components:
    ROMTbl[0] @ 41003000
    ROMTbl[0][0]: E00FF000, CID: B105100D, PID: 000BB4C0 ROM Table
    ROMTbl[1] @ E00FF000
    ROMTbl[1][0]: E000E000, CID: B105E00D, PID: 000BB008 SCS
    ROMTbl[1][1]: E0001000, CID: B105E00D, PID: 000BB00A DWT
    ROMTbl[1][2]: E0002000, CID: B105E00D, PID: 000BB00B FPB
    ROMTbl[0][1]: 41006000, CID: B105900D, PID: 001BB932 MTB-M0+
    Cortex-M0 identified.
    J-Link>loadfile bootloader-fluff_m0-v3.10.0.bin 0
    Downloading file [bootloader-fluff_m0-v3.10.0.bin]...
    Comparing flash   [100%] Done.
    Erasing flash     [100%] Done.
    Programming flash [100%] Done.
    Verifying flash   [100%] Done.
    J-Link: Flash download: Bank 0 @ 0x00000000: 1 range affected (8192 bytes)
    J-Link: Flash download: Total time needed: 0.182s (Prepare: 0.026s, Compare: 0.018s, Erase: 0.000s, Program: 0.125s, Verify: 0.008s, Restore: 0.002s)
    O.K.
    

    And the bootloader is flashed. Now the FLUFFBOOT disk appears, and we can drag the CircuitPython UF2 file to it. Done.

  • Swiss Cheese Arrived

    deʃhipu05/22/2020 at 12:26 0 comments

    The PCBs are here:

    I also have the bootloader and the CircuitPython firmware compiled, just waiting for a separate USB VID/PID for them.

  • Beginning

    deʃhipu05/03/2020 at 18:04 0 comments

    I was working on a version #Kubik M0 that would be compatible with FeatherWings, and I started to wonder whether I could do it with the QFN-32 version of the SAMD21 chip. I knew that the original Feather M0 switched to a bigger package, because there weren't enough pins, but I wanted to cheat anyways — I didn't want an external flash, and I would use the internal oscillator, which saves me a bunch of pins already. I would also use the SWD and SWC pins as regular pins — who needs debugging. So I looked at the original schematics, and started to create my own version.

    I wanted to re-use the same pins as much as possible, and I mostly succeeded. Of course some of the pins are simply not there on the QFN-32 package, so I had to find substitutes for those. That includes most of the analog pins, the SPI pins, and a few of the digital pins — not very bad. In the end, I even added an extra A6 pin to the board, and had two pins unused (I choose PA27 and PA28, since they can pretty much only do GPIO and nothing else).

    Then I started working on the actual PCB layout. It turns out that it's not very easy, because the pins are distributed pretty much randomly — they probably made sense on the bigger package, but with the smaller one I had to use a lot of vias. My first attempt was pretty bad, I had more vias than pins. So I deleted it and started from scratch, planning a little better this time. I came up with this:

    The big black circles are holes — I figured out that since the PCB is empty anyways, I can at least make it a little bit lighter. I could have used that space for a prototyping area, but it's kinda bad shape for that.

    I'm going to order this with my next batch of PCBs and then make a custom CircuitPython firmware for it.

View all 10 project logs

Enjoy this project?

Share

Discussions

MagicWolfi wrote 07/02/2020 at 16:08 point

Please use 2 resistors, one for each CC line. You'll avoid the same disaster that RaspberryPi had with their 1st version powered by USB-C, not working with certain USB-C power adapters. 

  Are you sure? yes | no

deʃhipu wrote 07/02/2020 at 18:24 point

I didn't look into what exactly was the problem with their hardware, because there was usually very little detail described in the articles — good to know it was this. Thanks for the advice.

  Are you sure? yes | no

MagicWolfi wrote 07/03/2020 at 00:50 point

No worries. Unrelated question: What font are you using in the terminal window in background title picture for this project? That looks like the most readable font ever.

  Are you sure? yes | no

deʃhipu wrote 07/03/2020 at 08:28 point

It is, it's called Terminus. Make sure to use a pixel font, not a TTF version, though.

  Are you sure? yes | no

Gerben wrote 05/05/2020 at 15:18 point

I could poke some holes in you PCB design, but it seems you beat me to it. q-;

  Are you sure? yes | no

bobricius wrote 05/04/2020 at 14:18 point

I am not cpython expert but I think D51 is much more cpython friendly + enough flash/ram with minimal price change

  Are you sure? yes | no

morgan wrote 05/04/2020 at 03:29 point

I've also had that feeling of wasting an overly capable devboard in a project for only needing one or two features.

  Are you sure? yes | no

bobricius wrote 05/03/2020 at 22:03 point

Nice, simple, clean ;) good job

  Are you sure? yes | no

deʃhipu wrote 05/03/2020 at 23:04 point

Thanks. We will see if it works when the PCB arrives.

  Are you sure? yes | no

bobricius wrote 05/04/2020 at 13:08 point

Waiting for Fluf M4 :) samd51j19>2xSpi I2c uart with access to all GPIO and without SPI flash and preconfigured st7735 :)

  Are you sure? yes | no

deʃhipu wrote 05/04/2020 at 13:51 point

But why? (I will probably do it anyways...)

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates