Skip to content
Snippets Groups Projects
Select Git revision
  • e9bf0ba7306afec2d1c46fed23626d557b22def4
  • master default protected
2 results

fab-step-log.md

Blame
  • Log

    2020 11 05

    Started in, have the schematic mostly roughed out: this'll be 1.5 sided (solid GND below a routed layer). I think... the largest challenge is just getting things around themselves without using any vias. Found a tranciever as well.

    2020 11 16

    Just routed out the program / power / data interface side of this.

    routing

    Success going forward will rely on a a fortuitous alignment of the RS485 interface pins against a SERCOM port somewhere on 11-16... not at all sure if any such alignment exists.

    2020 11 17

    Lucky me, those line up. I can put the SERCOM's TXPO at 0 (for TX on SER-0) and and RXPO at 3 (for RX on SER-3) and the middle two will do data enable and rx enable, just GPIO.

    routing

    So, sorted that out. I think it works OK. I can make one of these in the fab-version, and can copy the schematic onto a smaller 2-layer board to fab lots of at a board house, having pins 17-20 free for an AS5047 on the back... same RS485 interface, maybe the QFN D21, and 0805s or smaller passives, pinch traces / spaces etc.

    2021 06 12

    Re-routed this for UCBus compatibility, still looks like the best option despite SPI availability: SPI interrupt handlers are minimum ~ 2us, meaning byte period of 2.6us (at 3MHz) is limiting, might as well use simplicity of UART, and ability / option for it to self-configure as P2P connection, etc. RS485 UART is same pin count as TTL SPI, would rather have noise / distance immunity.

    I left off some pins (SERCOM0) to potentially add an encoder here, the routing for that would be tough but probably possible.

    route schem

    2021 06 19

    Realized today that I had 5v, 24v lines on the plug optimistically configured for easier routing: the cable symmetry results in a more awkward routing which I've corrected, just had to squish the connector / RS485 bit up 1.5mm or so, so that I could wiggle those 5v and 24v lines beneath the connector:

    route schem

    2021 10 19

    Thinking about updating this w/ easier / simpler stepper hardware, have this list of new chips to try:

    • 296-DRV8434RGERCT-ND (stepper chip)
    • DRV8436RGERCT
    • 296-40076-1-ND (h-bridge w/ current sense output)
    • MAX14871EUE+CT-ND (A4950 a-la-moderne)

    2021 12 05

    I have a few hours today, think I might roll an update for this: I want closed loop control everywhere... and a little better mounting / encoder options.

    I think I will do...

    • new h-bridge... also wouldn't mind a bump-stall-endstop, but that's a choice
    • the other rs-485 driver: easier to solder, more in-stock
    • samd21, ofc
    • ... maybe a thru-hole for stepper shafts, and then connector for various encoder options ? spi, quadrature, etc
    • delete the bus button, will use some other wake-up,
      • or share that pin w/ the limit

    Actually that RS485 chip (ISL3176EIBZ) that was in stock two weeks ago is now OOS... so I suppose I am sticking with the chip that I have. It's a shame about this supply chain stuff, will make it hard to share the boards.

    So! I think I just need to choose encoder pinouts / connector, and an h-bridge.

    H-Bridge Picking

    DRV8816

    We have the DRV8816, which is a nice part but probably has too many control pins...

    8816

    I especially like that it delivers amplified current sense output, so that one can run a real current controller externally... four input pins though, and running 2x of these I might even run out of pins.

    Though I think I can just tie both EN's to the same pin - well, all four of them, so this is maybe a contender. But means rolling current controllers... simpler circuit (no RC filter -> vrefs) but more complex code.

    Ship date is May of 2022, ffs.

    MAX14871

    This one is basically a modern A4950, I think, but it's unclear if the built-in current regulation is really good enough to 'point' - might be more of a

    A4954

    This is basically (?) two A4950's in one chip... yep, haha that's it: it's also out of stock. FFS.

    DRV8841

    A TSSOP, long boy, kinda complex, but probably has all the whistles we want. In stock... only 146 though...

    Sheesh, this is a lot - but it might be the one.

    8841

    It's a decent count of passives, but maybe still smaller overall. I'm going to look for single h-bridges for a minute.

    DRV8801

    Same energy as the DRV8816, slightly different?

    The DRV8841

    I am tempted to try this one out... I want to see about pins. I should only need 6: 2 for each h-bridge to set state / dir, and 1 for each vref.

    Yeah there's xI0 and xI1, which are current scalars: I can tie them all together and either ^ logic, to set full current all the time, or set them to a digital pin, and use them as en/disable.

    Alright then, this might be it, or I'll give it a go at least.

    This becomes crowded... thinking about -> 0805s.

    • 0805's
    • thru-hole jtag bb
    • thru-hole bus conn.

    Now, I came to this party because I wanted to see better encoder / board mounting to motors. I am still thinking, I guess, that part of this maybe means punching a thru-hole in the circuit so that it can mount more or less to the motor face, then the encoder part can float above...

    So I think we assume the existence of an interposer, then this mounts to the interposer with whatever hole pattern I'd like... and I can do a stack / standoff thing for the magnetic encoder, if we go that route.

    Moving along... I think I need to find my cable.

    For that, I'm tempted to just lay down two sets of solder-on pads... the limit,we want a connector for, but the other stuff... it'll be bundled in here together. A little ribbon-with-soldered-ends makes sense for a prototype thing.

    JST-XH seems like a common plug; it's the LiPO balance plug. There are pre-crimped leads available, or even on amazon.

    The through hole in the circuit causes all kind of routing trouble, I am thinking perhaps... I need to look at dual-shaft motors to get a sense for how necessary this is.

    Many of the rear shafts are quite long, so this would be real nice. Though I won't use it with pulse encoders...

    Damn and I can line this encoder pinup straight through with just a liiitle more pinch...

    And then the mounting is just another little bit of complicated because of the USB, which I am thinking I might use the vertical mount for...

    OK it's more of a monster than I had thought, but it's nearly done.

    I think I am going to put it (and myself) to bed for now, I'll probably get at it tomorrow AM, do the ~ 2 hours to finish it off, always good to do fresh eyes anyways.

    2021 12 06

    More or less done w/ this now;

    routed schematic

    Sending these to fab, doing orders, then we're off. I leave the actual CAD design of the mount, etc, to myself in the future.

    Quadrature Decoding

    Ah - one last thing. Dave pointed out that I should have paid attention to the rate of quadrature signal generation - so I had an ohshit moment for this...

    There's a sheet now, basically I wanted to know how long between pulses at certain rates. This is kind of punishing... I can do 1024 PPR @ 1K RPM makes for 5.8us between pulse, if I go to the encoder's full 4096 PPR I get 1.46us: a lot.

    So I have ordered this part LS7366R-S which is a hardware counter (SPI interface) that I could inter-pose between the encoder, my circuit, etc... and I just noticed that simpleFOC uses interrupts, seems fine. Here's their doc.

    For the interrupts - my beef is that I have some i.e. ~ 4us (?) interrupts happening pretty regularely on the UCBus, so adding this additional requirement is troublesome.

    I need to know if interrupts can interrupt others - haha - otherwise a 2us QDEC interrupt spacing on top of a 5us comms interrupt will miss a tick.