555 PWM

Thread Starter

MATT838383

Joined Jul 31, 2019
144
Hello MaxHeadRoom thank you for this info i agree but code C programming with a pic for me is to much complicaded! i will try soon microcontrollers for other projects more complex!
best regards!
 
Last edited:

danadak

Joined Mar 10, 2018
4,057
@danadak
I'm curious as to why you buffered the vref with an op-amp in the design in #53?
In PSOC the Vref is itself a hi z output source, so needs buffering to not affect its
value with load issues. Note you can wire it w/o buffering internally, eg. route, to other
components, as long as they are hi z.


Regards, Dana.
 

danadak

Joined Mar 10, 2018
4,057
Hello MaxHeadRoom thank you for this info i agree but code C programming with a pic for me is to much complicaded! i will try soon microcontrollers for other projects more complex!
best regards!
If you want to get started with processors there are block languages where you drag and
drop visual blocks onto design canvas, config (like pick pin # or set a variable), and then
hit upload and tool generates the C like Arduino code for you.

Second window from left is catalog of blocks and their functionality, window to its right
is where you drag the blocks to and config, and far right window is code tool generates for you.

Start with an Arduino Nano or Uno board, << $ 10, The IDE, in this case, mBlock5, is free.
Lots of videos and online help. I do C professionally, but still use this to bang out in very
short time basic aids, like stimulus generators for other stuff, simple control stuff.....

The 5 blocks shown all it took to read the pot with A/D and control the PWM with what was
measured. Downside is this is limited to 8 bit PWM and A/D is also limited in resolution. Its
a tradeoff.


1587852857168.png


Here I used an ATTINY part, versus Arduino board, but simplicity is obvious.
Note when using ATTINY type parts you use an Arduino board to program
them. Whereas if you just use Nano or Uno board mBlock directly programs
them.

1587853104968.png


Lots of fun. There are other block languages you can tether board to PC and it
can speak voltages measured, Snap4Arduino for example. Different block languages have
different capabilities, but once you learn one you can hop around using the
others easily.

When you get back into Arduino there are several block languages out
there with different (and similar) capabilities. Some even support ESP8266
for WiFi applications

mBlock, two versions 3.x and 5.x

Ardublock, also 2 versions, one a lot more capability

Sbnap4Arduino this you can tether a board to a PC and make talking
applications, and other capabilities due to tethering

Flowcode, the license free version

Scratch for Arduino


Regards, Dana.
 
Last edited:

Thread Starter

MATT838383

Joined Jul 31, 2019
144
After some thought I realized the LM339 circuit could be synchronized to an external pulse.
Below is the simulation of the modified circuit with a sync input.
The free running frequency of U1 should be about 5-10% lower than the sync frequency for reliable synchronization.

To allow for component tolerances you likely would have to make R1 a pot to get the desired free run frequency.

View attachment 205312
Hello crutshow i have finished your lm339 PWM (post58) but a problem occurred,i have only 75%duty cycle! is it ok? do you know any other ic's that can hold 85% or higher duty?
thank you
best reguards!
 

djsfantasi

Joined Apr 11, 2010
9,237
Note when using ATTINY type parts you use an Arduino board to program
them. Whereas if you just use Nano or Uno board mBlock directly programs
them.
Or you can buy an ATTiny programmer (Sparkfun has one) and program the chip directly from the Arduino IDE and a laptop/computer. If you think your going to have several ATTiny projects, the less than $20 cost is well worth the simplicity in programming the chips
 

Thread Starter

MATT838383

Joined Jul 31, 2019
144
Hello everybody! i look for a IC that can hold 85% dutycles or higher! i have tried with a LMC 555(49%) and a LM339(70%)! awaiting for your opinions!
thanks
 

BobTPH

Joined Jun 5, 2013
11,516
What circuit are you using? A ‘555 can easily do 85%. Depending on your application you may have to invert the output.

Bob
 

crutschow

Joined Mar 14, 2008
38,513
Hello crustshow what maximum dutycycle you have with your schematic?
You can see from my simulation that the PWM output (yellow trace) reaches 100% duty-cycle (full on) when the modulation input (green trace) reaches 4V.
So I'll ask again, what input (not supply) voltage were you using to get only a 75% duty-cycle?
 
Top