My first version of this was one-way only i.e. the TinySensor sending data to the Raspberry Pi. This is due to the limitation in the Serial implementation in the tiny core, only TX is implemented for debug purposes. I have found a patch for the NewSoftSerial library that makes it compatible with the ATTiny84, so this will give me two-way communication between the Pi and the TinySensor and that opens a whole new door with possibilities, for example, the Pi can order the TinySensor to send out certain RFM12b message to other nodes. I have the patched NewSoftSerial library available on GitHub. My code with the TinySensor receiving RFM12b data and relaying to PI’s serial, but also listening for command and echoing them is here.
There is nothing fancy about connecting the TinySensor to the Raspberry Pi as the TinySensor runs on 3V, so no need for level shifting. Just ensure common ground and hook RX/TX on the Pi to whatever cross pins you chose on the TinySensor and you are in business. For a permanent connection, you can power the TinySensor from the +3.3V on the Pi rather than the battery.
Page views: 3976