The anarduino module with rfm98w is undocumented at this point. For example the DIO0 and DIO5 on the RFM98W module, are connected to pins 4 and 2
which i had to figure out by measuring.
There are many pins on the RFM98 module. How can i figure out which pins it is connected to?
stevech wrote:Antenna absent - I've done it often when doing desktop testing and range isn't important.
second SPI device wired up to board... here are the considerations
- added SPI device needs its own unique chip select (SS) bit
- The radioHead interrupt service routine will use the SPI port unaware that there may have been a concurrent SPI by the second SPI device
As to the second point, there are two ways I know of to deal with this "mutual exclusion" access to a shared device (that being the SPI controller).
1. When the second device starts to use the SPI port, it must first cause the radio to switch to the idle mode where the receiver and transmitter are "off" and cannot interrupt. The SPI can then be used for the second SPI device without risk of a radio's interrupt trying to also use the SPI port. Downside: If the second device hogs too much time, an message may be missed. If the message uses the RadioHead reliable datagram protcol, the sender will delay and retry and hopefully the second device will have finished its uses of the SPI and reenabled the receiver by calling available().
2. Arduino (latest) libraries have a function "SPI Transactions". With this, a program contends for use of the SPI port. When the transaction is permitted, the other (radio) usage will have its interrupt disabled until the transaction is finished. This transaction concept does NOT work well with real-time, perishable data as is the case for wireless messaging. Transactions work well for non-real-time such as SPI flash memory, LEDs, and so on.
I use approach (1) due to the real-time nature of wireless.
Ideally, one uses an MCU with two SPI ports as are common on the small ARM boards like Teensy 3.x and Teensy LC. This avoids the contention.