Main Site Documentation

Hardware PWM capabilities


#1

How fast can the PWM go on the Spider? Can it be used as a 1MHz clock signal for another chip?

If not, how about with the Hydra?

I’m trying to figure out if I really need an intermediary chip full o’ C code to do something I plan to do later this week.

Pete


#2

Yes. 1mhz is actually slow :slight_smile:


#3

Sweeeet. Now we’re talking.


#4

Is that a C64 Audio chip ??

What is next ?

Music synth ? Text to speech ?


#5

Just for the record, I thought I’d show that the Gadgeteer/Spider has no problem doing 1MHz PWM:


Socket _clockSocket;
Socket _dataSocket;

PWMOutput _clockPwm;
        
public SidInterface(int socketNumberData, int socketNumberClock)
{
    _clockSocket = Socket.GetSocket(socketNumberClock, false, this, null);
    _dataSocket = Socket.GetSocket(socketNumberData, false, this, null);
}

public void StartClock()
{
    _clockPwm = new PWMOutput(_clockSocket, Socket.Pin.Seven, this);
    _clockPwm.Set(1048576, 50);
}

Still not sure how much of this experiment will work, but that’s why it’s an experiment :slight_smile:

Pete