Close

Getting closer

A project log for Orthrus

SD card secure RAID USB storage

nick-sayerNick Sayer 10/03/2017 at 05:060 Comments

It turns out that if you swap out the 16 MHz crystal for a 12 MHz one, USB seems to work a lot better. The firmware hasn't completed the full attach sequence just yet, but it's much further along.

It's unclear why 16 MHz doesn't work. The datasheet says both are acceptable, and both work with SAM-BA in ROM. But Atmel Start doesn't have any knob I can find that you need to flip for the UPLLCK when it's coming from a 16 MHz source, and there's nothing in the datasheet about that either.

12 MHz is arguably a better choice anyway, since it's 300 divided by 25, which means that the CPU clock speed can be maxed out (I was using 288 MHz before).

Another bug in Atmel Start is that it won't allow you to set a bulk endpoint maximum packet length of higher than 64. The hardware supports up to 1024, and the high-speed spec requires a minimum of 512 (alas, that change isn't enough to fix the enumeration problems).

So... that's progress, at least.

I've updated the schematic / board files, making v3.0.1. The 3.0 boards are still fine - nothing much changed on the board. I've added a 0 Ω resistor as a disconnect point for Vddcore so you can experimentally disconnect it if you're so inclined (the resistor pads have a trace jumping them so there's no need for an actual part). There'a also an ever-so-slight tweak to the USB line layouts, but it's not so significant as to make much of a difference (beyond being more theoretically correct). High speed differential signals like that should not have "T" paths, and I made a small pair to connect the TVS protection diode matrix. Now the traces enter and exit the pads, meaning they stay more linear.

Version 3.0 is still what's going to be submitted to the judges for the HP. I just need to get USB working the rest of the way...

Discussions