Skip to main content
19 events
when toggle format what by license comment
Aug 24 at 17:43 history edited Wossname CC BY-SA 4.0
deleted 47 characters in body
Aug 24 at 17:07 answer added The Photon timeline score: 2
Aug 24 at 16:44 history edited Wossname CC BY-SA 4.0
deleted 42 characters in body
Aug 24 at 15:33 vote accept Wossname
Aug 24 at 15:23 comment added Wossname Let us continue this discussion in chat.
Aug 24 at 15:21 comment added Marcus Müller @Wossname no, what I mean is that it's possible that your microcontroller already contains exactly the hardware you need to just give you the list of CCW or CW rotation "ticks" since you last asked, no CPU involvement (aside from reading that register) needed at all.
Aug 24 at 15:19 comment added Wossname @MarcusMüller, I don't doubt it. I only picked quadrature for this hobby project because I've done it before (purely in software, for an inverted pendulum balancer) and I still have the encoder device in my parts bin. This microcontroller doesn't have a dedicated quadrature decoder, but I think I can make one from it's CCL / LUT system. I appreciate your insight and guidance, cheers. :)
Aug 24 at 15:13 comment added Marcus Müller I don't know that microcontroller, @Wossname, but "quadrature encoder decoders" are a very common feature in microcontrollers.
Aug 24 at 15:12 comment added Wossname @TomCarpenter, well that's a heck of an aside, nice one! By chance, the hardware I'm using does indeed have a spare D-FF (it's a Microchip AVR128DA64 if you're interested). I'm hoping to be able to use the "CCL" features to take the heavy lifting of decoding the quadrature away from the CPU.
Aug 24 at 15:11 comment added Marcus Müller @Wossname in general, yes. In many cases, the question "is there a five-operations or fewer expression giving me the desired output" is a "boolean satisfiability problem", and that is a class of NP-complete problems; modern SAT solvers have heuristics that find a possible solution in much shorter time. I don't know which problem you'd really solve with an Karnaugh map if you have hundreds of inputs. (say you have a hundred boolean inputs – your karnaugh map becomes 2¹⁰⁰ entries large. I don't think that is a scalable approach: verification solutions takes less time than coming up with them)
Aug 24 at 15:08 answer added Tom Carpenter timeline score: 3
Aug 24 at 15:04 review Close votes
Sep 8 at 3:07
Aug 24 at 15:00 comment added Wossname There is a vote to close this question, can someone please let me know how I can improve it?
Aug 24 at 14:52 comment added Tom Carpenter As an aside, a single rising edge D-Flip Flop will give you X. You connect A to the data input, and B to the clock input. The Q output will then give you the direction. The advantage is that its tolerant to noise and denouncing.
Aug 24 at 14:30 comment added Wossname @MarcusMüller, And yes I get what you mean by basically "brute forcing" each possible input, but I'm interested in the general approach. Is it scalable to hundreds of inputs, which would be hard to brute force? Just curious.
Aug 24 at 14:25 comment added Wossname @MarcusMüller, if I understand you correctly then I was wrong about my extra Y signal being irrelevant. The Y signal is what prevents the "imaginary" 1s from causing problems elsewhere. Because there will be no Y pulse when an imaginary 1 bit is active. Makes sense I think.
Aug 24 at 14:13 comment added Marcus Müller there's exactly one way we would use to figure that out: put in all possible input combinations, and see whether what we get is what you specified should happen. And, I think you'd do the same!
Aug 24 at 14:07 history edited Wossname CC BY-SA 4.0
deleted 8 characters in body
Aug 24 at 14:01 history asked Wossname CC BY-SA 4.0