Sending bits for digital control
Posted: Wed Jan 22, 2020 3:01 pm
Good afternoon everybody,
I am willing to use a RPi for digital control.
The signal must be a wave-type current. To send a 1, I shall send a wave with a 116 microsecond period. To send a 0, it must be a 200 microsecond period wave.
When I'm not sending packets, the signal must be a continuous following of 0.
I thought about using PWM to have a signal with a 200 us period. I could pause this signal to send bits, then resume the zeros.
Here is the problem : Sending bits.
Is it possible to send a single wave with PWM ?
Is there an other way than :
set high,
sleep,
set low,
sleep,
begin again.
My specs : RPi 4, current dev in java.
Thank you all for your help !
I am willing to use a RPi for digital control.
The signal must be a wave-type current. To send a 1, I shall send a wave with a 116 microsecond period. To send a 0, it must be a 200 microsecond period wave.
When I'm not sending packets, the signal must be a continuous following of 0.
I thought about using PWM to have a signal with a 200 us period. I could pause this signal to send bits, then resume the zeros.
Here is the problem : Sending bits.
Is it possible to send a single wave with PWM ?
Is there an other way than :
set high,
sleep,
set low,
sleep,
begin again.
My specs : RPi 4, current dev in java.
Thank you all for your help !