ATtiny85 + RFM95 Temperature Sensor


(Wero1414) #21

Yeah, i did it for an arduino mini pro, i needed to do a Class c node, now i will port it to an ATtinny.


#22

After my earlier sketch of the ATtiny85 I packed everything in an easy-to-use Arduino library.
I made a step-by-step tutorial on the TTN Labs site, explaining everything from the installation up to the wiring.
I replaced the thermistor with a smarter sensor with SPI capabilities.
The Bosch BME280 can measure temperature, humidity and pressure.


#23

Thanks for sharing.

My two cents: As you are not using hardware interrupt for DIO0, you can replace your digitalRead() by a read of RFM95 register 0x12 (RegIrqFlags) bit 3 (TxDone).

This can free one pin on your ATTiny.


The WORKBENCH part 1
#26

Sorry, should read more first. Got too excited by the concept. Great work!!


#27


US $1.35 incl. shipping


#28

I tried this one, thinking I could use it instead of the Arduino setup (since it says “Programmer Board”), but I needed to upload a bootloader to the ATTINY85 first.
I ended up using the Arduino setup to first load the bootloader (and then also the program since that was just as easy).


#29

@jym This is a good idea that saves the effort for changing the Reset pin.


#30

OK I thought to that you could use it to upload a bootloader :sunglasses:


#31

Yeah, it is different for the ones with the ATtiny85 integrated into the board:

https://nl.aliexpress.com/item/Free-shipping-Digispark-kickstarter-miniature-for-Arduino-usb-development-board-with-pins-and-Anti-static-bag/32222311445.html

Those already have the bootloader installed and can be used straight away by just plugging them into USB (and install all the needed stuff in the Arduino IDE of course)>
In price they only add 20 cents to the chip, but they expect 5V instead of 3V.


#32

there is an other one with an ATMEL167 (slightly bigger memory).
Not testet, just ordered :wink:


#33

theoretically this is a complete LoRaWAN temp/motion detector node :sunglasses:

*picture updated with smaller capacitor :wink:


#34

why such a big capacitor? buffering the current needed while sending?
does it not constantly discharge the battery?


(Tvloon) #35

ohhh… he forgot to RTFx :unamused:


#36

TinyLoRa-BME280 v1.1
I made some improvements based on the feedback from @jym with regard to the hardware interrupt from DIO0 pin.
In v1.1 only PB3 and PB4 from the ATtiny are needed, no hassle with fuse bits changing the reset pin PB5.
I also had some problems with the current of the BME280 drawing 0.6mA in sleep mode.
Now I disable the SPI interface and set the SCK and DO pin as Input and Low before the ATtiny goes in power down mode.
This gives me the promised 0.1uA of the BME280 as written in the data sheet.
The sleep current of the RFM module is 0.5uA.
Most of the power consumes the ATtiny 3,5uA @ 2,8 volt in power down mode so there is still space for improvement.
Will be continued… it’s a race to the bottom. :smile:


(Leo Korbee) #37

Inspired by this forum, I made a node with ATtiny84 + RFM95W and BME280. I managed to get the current down to 4.8uA in sleep/power down mode. Remember to remove some pull up/pull down resistors on the BME280 bord. Due to the two modes (I2C and SPI) they are on that board. Perhaps you don’t need them all. On my board it used 3.3v/10k = 330uA before I removed one of the SMD resistors.


#38

Great!

attiny85 is cute but I think 84 is much more interesting due to extra pins and cheaper price.

any more details on your implementation ? chance to share code / hw design?


(Leo Korbee) #39

Extra pins is indeed the reason I choose this microprocessor and my experience with it of course. I will share my implementation and detail in a Blog I’m starting. I will announce the site here in a few weeks.


(bluesensing) #40

great


(Leo Korbee) #41

Due to the positive response I made a new blog in the past week and here is the link to the ATtiny84 low power node:
http://www.iot-lab.org/blog/101/

Have fun!


(Tou Yun G) #42

Good work, I can run on 923MHz now ^^.
before can’t run because I set internal clock 1MHz @_@!.

How I can change connect MOSI–MOSI (PB0),
this point is another waste my time for debug it.

Thank You.