1 2 Previous Next 16 Replies Latest reply on Mar 6, 2015 10:38 AM by DaKn_263916

    Hello and a programmable infinite resolution triangle wave generator


      Hi there,


      I'm Nuno and I've just started to play with PSoC 4, first time on PSoCs. Just wanted to say Hi and leave my 1st PSoC project, which I called "programmable infinite resolution triangle wave generator". Big name, uh :)?


      It's a remake of the traditional analog capacitor based opamp and voltage comparator triangle wave generator, but this time the charging and discharging of the capacitor is under digital control. You have the "pure analog" output but can control frequency, and this can make it to at least 245KHz in 1KHz steps. It needs calibration because as the frequency goes up the time spent in the comparator ISR influences more and more the output amplitude/frequency, but the relation is linear; with the calibration values on the source code it generates a wave of nominally 10KHz .. 245KHz in 1KHz steps, 1Vpp, 120mV offset.


      This was made with the prototyping board, so you have the bootloader in there. I noticed that once a PC application opens the serial port you have a kind of crosstalk between the comparator's output and the opamp's output.


      If you have any feedback or just want to say hi, don't be shy :)!



        1 2 Previous Next