tscircuit / footprinter

micro-builder and DSL for creating PCB footprints, built for AI
https://tscircuit.github.io/footprinter
MIT License
8 stars 9 forks source link

On rotation of footprint in multiple of 45, the pads are missing. #93

Closed imrishabh18 closed 4 hours ago

imrishabh18 commented 9 hours ago

Image

export default () => {
  return (
    <board height="43.18mm" width="18.54mm">
      <chip
        manufacturerPartNumber="ATmega328P"
        name="U1"
        schX={0}
        schY={8}
        pcbX={0}
        pcbY={-8}
        footprint="qfp32"
        pcbRotation={45}
      />
    </board>
  )
}
imrishabh18 commented 9 hours ago

/bounty $5

algora-pbc[bot] commented 9 hours ago

💎 $5 bounty • tscircuit

Steps to solve:

  1. Start working: Comment /attempt #93 with your implementation plan
  2. Submit work: Create a pull request including /claim #93 in the PR body to claim the bounty
  3. Receive payment: 100% of the bounty is received 2-5 days post-reward. Make sure you are eligible for payouts

Thank you for contributing to tscircuit/footprinter!

Add a bounty • Share on socials

ShiboSoftwareDev commented 6 hours ago

Image actually only 90 degree rotation works

imrishabh18 commented 6 hours ago

Yeah I know 90 multiples are working fine. But I was seeing few pcb boards and they were placing the chips in 45deg. So, probably we need to support that as well. I think probably it will be more work to rotate the pads I am guessing

ShiboSoftwareDev commented 4 hours ago

@imrishabh18 can you delete this issue and open it in snippets? Abse found a fix but transferring issues doesn't transfer bounties so please reopen it there. fwiw I implemented rotated_rect in all relevant repos except the autorouter repo. Can you please investigate this issue as I couldn't find the problm? https://github.com/tscircuit/autorouting/issues/96

imrishabh18 commented 4 hours ago

If not here then, I am guessing this logic needs to be implemented in PcbViewer about rotation of footprint. Why in snippets though? 🤔

cc: @seveibar

ShiboSoftwareDev commented 4 hours ago

@imrishabh18 the original problem is the pads not appearing which is fixed by updating pcb-viewer in snippets since I already implemented it in pcb-viewer, and he found another problem where the rotation direction is reversed which needs to be fixed in pcb-viewer. Sorry I didn't clarify earlier