![]() |
|
|
|
#1 |
|
"Mike Treseler" <> wrote: > Take sdata_in out of the sensitivity list and > you have a synchronous process that will > sim and synth the same way. > > Hmmm. Why are we making bytes in the first place? > -_______--______----____-------_ > > Don't we just want to preset a counter > while the data is high and count down > while it is low? Well if we were doing one PWM channel perhaps. My goal is to have several PWM channels. Constraints on my design are that I want to be able to "clock in" the various widths behind the running the circuit. Then, once I have the next set of widths ready to go, to assert "load" and at the start of the next PWM period, all PWM channels running at their new value. As a roboticist, and a "hobby" one at that, one application of this technique is to build a device for driving a number of R/C servos that can be programmed with a serial bitstream, and then commanded to operate synchronously. This level of control is essential in using R/C servos to control articulated walking robots for example. (google on the term Robo-One for examples) I'd like to build it out of a CoolRunner CPLD. I am, perhap prematurely, trying to be stingy on flip flops to save macrocells. If I create a single "master counter" that is counting through its iterations, then I can create a PWM output which consists of 'n' flip flops (equivalent to the counter width) and some combinitorial logic that implements an n-bit compare. So if my count width is 'n' then my macrocell count is (pwm_channels + 1) x 'n'. This is because I can use the same macro cells for both the latch and the comparator. The more channels I can get into the CPLD, the fewer CPLDs I'll need. Many Robo-one robots have 27 degrees of freedom (that is a lot of PWM channels The synchronous change facility is a "freebee" once I've isoloated the serial shift register chain from the pwm generator channels (I end up burning another n macro cells for each channel making it (2 * pwm_channels + 1) x 'n' macrocells. There is some other magic with them being synchronous but not simultaneous but I'm not close to needing that stuff yet. --Chuck http://www.mcmanis.com/chuck/robotics/ Chuck McManis |
|
|
![]() |
| Thread Tools | Search this Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to execute an external software from VHDL? And how to interface VHDL with JAVA? | becool_nikks | Software | 0 | 03-06-2009 07:08 PM |
| Vending machine using VHDL | arie | General Help Related Topics | 0 | 03-05-2009 05:45 AM |
| Help on auto conversion from Matlab to vhdl on filter design | hardheart | Hardware | 0 | 12-07-2007 09:19 AM |
| VHDL RAM help!:) | lastval | Hardware | 0 | 11-09-2007 01:40 PM |
| ARRAY(n DOWNTO 0) OF STD_LOGIC_VECTOR(m DOWNTO 0) - VHDL | freitass | Hardware | 0 | 11-01-2007 03:44 PM |