6v6gt:
To put single a pulse of a specific duration on an Arduino pin, you'd do something like:digitalWrite(pulsePin,1) // Set output to 1
delayMicroseconds( pulseLength ) ; // set this yourself
digitalWrite(pulsePin,0) // Set output to 0
Thanks @6v6gt, I got that.
But as an interesting hack, where the data is already a byte (so doesn't need to be massaged into microseconds), and the range of pulse lengths is suited to the problem (low rate ASK transmission over a short but potentially noisy range), and without an Arduino in front of me to try it on, would it work as required?
To ask it as a deeper question, does the Arduino complete sending a pulse in analogWrite before executing the next instruction, or would the following digitalWrite terminate the analogWrite early, or on the other end would it take so long to terminate that a pulse and a bit or maybe two or more whole pulses were sent?
Yes, I could (and have looked at) use an FSK serial link, but where's the fun in following everyone else?
Pogo