Re: Wireless module!
Posted: Wed Jul 08, 2026 10:15 am
A first play today....
First up - using a UART doesn't work (needs inverting) - so I did a small transmit that uses TMR2 to generate 4000Hz (250uS) timing.
It's a little 'clunky' at present - data is put into 'buf' and 'length' set to it's length (in bits) - the data needs to include the 0xAA or 0x55 AGC bits - but because it is Manchester encoded - this is actually done as 0xFF (two bytes of 0x0b0101010101) or 0x00 (two bytes of 0b10101010) -n encoding gives 0 -> 0b10 and 1 -> 0b01 (which makes decoding the signal easier (maybe))
This doesn't do decoding (yet) - need to pull another Arduino.
This code is Arduino specific (there is a custom interrupt to get a 4kHz timing)
So - something to try out. I found an aerial helped (and I just poked a jumper through the relevant holes - solder later!)
Showing 'sent' and 'received' by connecting the data pins of the transmitter and receiver to a logic analyser (which works better than a scope - the signal is rather noisy)
Martin
First up - using a UART doesn't work (needs inverting) - so I did a small transmit that uses TMR2 to generate 4000Hz (250uS) timing.
It's a little 'clunky' at present - data is put into 'buf' and 'length' set to it's length (in bits) - the data needs to include the 0xAA or 0x55 AGC bits - but because it is Manchester encoded - this is actually done as 0xFF (two bytes of 0x0b0101010101) or 0x00 (two bytes of 0b10101010) -n encoding gives 0 -> 0b10 and 1 -> 0b01 (which makes decoding the signal easier (maybe))
This doesn't do decoding (yet) - need to pull another Arduino.
This code is Arduino specific (there is a custom interrupt to get a 4kHz timing)
So - something to try out. I found an aerial helped (and I just poked a jumper through the relevant holes - solder later!)
Showing 'sent' and 'received' by connecting the data pins of the transmitter and receiver to a logic analyser (which works better than a scope - the signal is rather noisy)
Martin