Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. My Project
  3. Slim Node Si7021 sensor example

Slim Node Si7021 sensor example

Scheduled Pinned Locked Moved My Project
137 Posts 18 Posters 64.8k Views 20 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • rsachocR Offline
    rsachocR Offline
    rsachoc
    wrote on last edited by rsachoc
    #37

    Folks, a word of caution, for people that are attempting this for the first time, please burn the bootloader before you solder everything, as silly me, I built the entire thing (without the si7021) and now I'll need to bin it because the ATMega is soldered to the board and I've no way to load the bootloader soldered to the board!

    Ah, the life of a newbie :grin:

    I think what I'll do is once I've actually got a working board, I'll do a newbie writeup so that people don't make the same mistakes as me.

    m26872M 1 Reply Last reply
    1
    • mfalkviddM Offline
      mfalkviddM Offline
      mfalkvidd
      Mod
      wrote on last edited by
      #38

      First Attempt In Learning :-) A writeup would be awesome.

      1 Reply Last reply
      0
      • rsachocR rsachoc

        Folks, a word of caution, for people that are attempting this for the first time, please burn the bootloader before you solder everything, as silly me, I built the entire thing (without the si7021) and now I'll need to bin it because the ATMega is soldered to the board and I've no way to load the bootloader soldered to the board!

        Ah, the life of a newbie :grin:

        I think what I'll do is once I've actually got a working board, I'll do a newbie writeup so that people don't make the same mistakes as me.

        m26872M Offline
        m26872M Offline
        m26872
        Hardware Contributor
        wrote on last edited by
        #39

        @rsachoc Why don't you just solder some wires to pins you need ? The "in cicuit serial programming" concept would let you do it with almost anything attached.

        rsachocR 1 Reply Last reply
        0
        • m26872M m26872

          @rsachoc Why don't you just solder some wires to pins you need ? The "in cicuit serial programming" concept would let you do it with almost anything attached.

          rsachocR Offline
          rsachocR Offline
          rsachoc
          wrote on last edited by
          #40

          @m26872 said:

          @rsachoc Why don't you just solder some wires to pins you need ? The "in cicuit serial programming" concept would let you do it with almost anything attached.

          I might as well attempt that! I'm waiting for a breadboard, so I'll try and attempt it when that arrives.

          1 Reply Last reply
          0
          • rsachocR Offline
            rsachocR Offline
            rsachoc
            wrote on last edited by rsachoc
            #41

            Some of my tips (noob alert) that I've gathered in my travels so far for this temp Slim node

            1. Burn the bootloader onto the ATMega328 first! (here is a guide for Arduino as ISP)
            2. Check the capacitor polarity before you solder it (the 4.7uF electrolytic capacitor, the others don't matter)
            3. I prefer using strips for the Atmega (see here) as you'll have more clearance for the capacitors which sit underneath (there is a caveat to this however, in that if you're not sure if you've got/burnt a bootloader onto the ATMega, using strips there is no going back, whereas with the chip socket, you can remove the ATMega). Update I think, for me anyway, if you're confident that the ATMega has been bootloaded successfully, I still prefer strips, however if you're unsure what you can do is use the socket and just sit it higher in it's position to get a decent clearance.
            4. The bill of materials (BOM) is here and also helps with figuring out which pieces go where
            5. Solder the capacitors, wires for Si7021 (with si7021 attached) and FTDI pins to the board first, then the strips + AtMega328p (see below), then the NRF last to the board. I found that the FTDI pins facing straight up were best for the box I was going to put it in
            6. Solder the strips to the ATMega first, then to the board
            7. Check the size of the box/fitting you are going to mount this in before you do all the above!
            8. Check that you are putting the ATMega chip the right way on the board, the notch should be facing the pins for the FTDI.
            9. Check continuity of the pins from the ATMega to the board pins underneath, I found the ATMega to strips were the most difficult to solder, and after I tested continuity I found a single pin which didn't have connection, so I added some more solder to this pin.
            10. Don't forget the resistor at R1 (I soldered this to the underside of the board, less by choice and more by the fact that I forgot about it, but I guess the preference would be the same side as the capacitors)
            11. I strongly advise buying the 3.3v ready si7021 temp sensor (here) as the modification to the 5v version is quite difficult for a newbie (the components are quite small) and you'll probably mess it up like I did.

            General soldering tips
            12) Practice soldering first, some of the joins are a little challenging and it took me a few attempts to get the hang of it
            13) Get a decent size tip, my first was a bit large

            GertSandersG 1 Reply Last reply
            3
            • rsachocR rsachoc

              Some of my tips (noob alert) that I've gathered in my travels so far for this temp Slim node

              1. Burn the bootloader onto the ATMega328 first! (here is a guide for Arduino as ISP)
              2. Check the capacitor polarity before you solder it (the 4.7uF electrolytic capacitor, the others don't matter)
              3. I prefer using strips for the Atmega (see here) as you'll have more clearance for the capacitors which sit underneath (there is a caveat to this however, in that if you're not sure if you've got/burnt a bootloader onto the ATMega, using strips there is no going back, whereas with the chip socket, you can remove the ATMega). Update I think, for me anyway, if you're confident that the ATMega has been bootloaded successfully, I still prefer strips, however if you're unsure what you can do is use the socket and just sit it higher in it's position to get a decent clearance.
              4. The bill of materials (BOM) is here and also helps with figuring out which pieces go where
              5. Solder the capacitors, wires for Si7021 (with si7021 attached) and FTDI pins to the board first, then the strips + AtMega328p (see below), then the NRF last to the board. I found that the FTDI pins facing straight up were best for the box I was going to put it in
              6. Solder the strips to the ATMega first, then to the board
              7. Check the size of the box/fitting you are going to mount this in before you do all the above!
              8. Check that you are putting the ATMega chip the right way on the board, the notch should be facing the pins for the FTDI.
              9. Check continuity of the pins from the ATMega to the board pins underneath, I found the ATMega to strips were the most difficult to solder, and after I tested continuity I found a single pin which didn't have connection, so I added some more solder to this pin.
              10. Don't forget the resistor at R1 (I soldered this to the underside of the board, less by choice and more by the fact that I forgot about it, but I guess the preference would be the same side as the capacitors)
              11. I strongly advise buying the 3.3v ready si7021 temp sensor (here) as the modification to the 5v version is quite difficult for a newbie (the components are quite small) and you'll probably mess it up like I did.

              General soldering tips
              12) Practice soldering first, some of the joins are a little challenging and it took me a few attempts to get the hang of it
              13) Get a decent size tip, my first was a bit large

              GertSandersG Offline
              GertSandersG Offline
              GertSanders
              Hardware Contributor
              wrote on last edited by
              #42

              @rsachoc As a great man once said: "most bananas grow bent, and yet everyone loves them. There is nothing strange about the diversity of routes to success"

              1 Reply Last reply
              1
              • rsachocR Offline
                rsachocR Offline
                rsachoc
                wrote on last edited by
                #43

                Thanks all, I'm sure I will be adding to it, as I'm now trying to compile and upload the sketch. However, I'm getting the following error:

                   #error No forward link or gateway feature activated. This means nowhere to send messages! Pretty pointless.
                
                    ^
                
                exit status 1
                Error compiling.
                

                I'm using the W5100 MQTT gateway sketch (which I believe is on the development branch), so I'm not sure if that's what's causing the error? I've tried deleting the Arduino IDE, the mysensors development branch from my PC, and reinstalling and redownloading the mysensors dev branch, but the same thing happens?

                1 Reply Last reply
                0
                • rsachocR Offline
                  rsachocR Offline
                  rsachoc
                  wrote on last edited by
                  #44

                  OK, so it seems that it was because I was using the dev branch that I'm getting that error. I switched over to stable and the sketch compiles, although I do get a warning.

                  WARNING: Category '' in library UIPEthernet is not valid. Setting to 'Uncategorized'
                  

                  But I also can't upload the sketch above:

                  avrdude: stk500_recv(): programmer is not responding
                  avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x18
                  

                  I noted above that something needed to be changed in terms of the baud rate, mine is set at 115200 in myconfig.h and I can't seem to find a reference in mysensor.h

                  m26872M 1 Reply Last reply
                  0
                  • rsachocR rsachoc

                    OK, so it seems that it was because I was using the dev branch that I'm getting that error. I switched over to stable and the sketch compiles, although I do get a warning.

                    WARNING: Category '' in library UIPEthernet is not valid. Setting to 'Uncategorized'
                    

                    But I also can't upload the sketch above:

                    avrdude: stk500_recv(): programmer is not responding
                    avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x18
                    

                    I noted above that something needed to be changed in terms of the baud rate, mine is set at 115200 in myconfig.h and I can't seem to find a reference in mysensor.h

                    m26872M Offline
                    m26872M Offline
                    m26872
                    Hardware Contributor
                    wrote on last edited by m26872
                    #45

                    @rsachoc I sorry, but there seems to be an error in the sketch in the first post. Baud rate should be 9600 everywhere if you use the common Slim Node fuses and bootloader. Upload (board.txt), MyConfig.h (not MySensor.h since v1.5), Debug-prints and Arduino IDE serial monitor.

                    1 Reply Last reply
                    0
                    • rsachocR Offline
                      rsachocR Offline
                      rsachoc
                      wrote on last edited by
                      #46

                      Thanks, I've updated the sketch that I downloaded, also myconfig.h so that should be good. What do I need to select in the Arduino IDE for board type? I searched in the slim node thread and didn't see a reference to any changes?

                      m26872M 1 Reply Last reply
                      0
                      • rsachocR rsachoc

                        Thanks, I've updated the sketch that I downloaded, also myconfig.h so that should be good. What do I need to select in the Arduino IDE for board type? I searched in the slim node thread and didn't see a reference to any changes?

                        m26872M Offline
                        m26872M Offline
                        m26872
                        Hardware Contributor
                        wrote on last edited by
                        #47

                        @rsachoc No changes. It is that boards.txt entry you should use.

                        1 Reply Last reply
                        0
                        • rsachocR Offline
                          rsachocR Offline
                          rsachoc
                          wrote on last edited by rsachoc
                          #48

                          Hmmm ok, that's what I thought...still no luck, I've modified the boards.txt with the text from the slim node thread, and now it still has the same error message.

                          To confirm, my FTDI adaptor is attached to the board pins as follows:

                          FTDI <-> board
                          GND <-> first pin (i.e bottom left of board when looking at board laying long side horizontal and NRF radio on the other side)
                          CTS <-> board marked GND
                          PWR <-> board marked VCC
                          TXO <-> next up i.e. 4th pin
                          RXI <-> next up i.e. 5th pin
                          DTR <-> next up i.e. last pin

                          Other than that, I guess it may be something wrong with the way I made the board? If so, what's the best way to troubleshoot? Could it be a bad bootloader flash? Is there a way to check if the ATMega has a bootloader?

                          edit in fact, it could be because I don't have the Si7021 connected? Could this be the reason a sketch is not uploading successfully? :worried:

                          m26872M 1 Reply Last reply
                          0
                          • rsachocR rsachoc

                            Hmmm ok, that's what I thought...still no luck, I've modified the boards.txt with the text from the slim node thread, and now it still has the same error message.

                            To confirm, my FTDI adaptor is attached to the board pins as follows:

                            FTDI <-> board
                            GND <-> first pin (i.e bottom left of board when looking at board laying long side horizontal and NRF radio on the other side)
                            CTS <-> board marked GND
                            PWR <-> board marked VCC
                            TXO <-> next up i.e. 4th pin
                            RXI <-> next up i.e. 5th pin
                            DTR <-> next up i.e. last pin

                            Other than that, I guess it may be something wrong with the way I made the board? If so, what's the best way to troubleshoot? Could it be a bad bootloader flash? Is there a way to check if the ATMega has a bootloader?

                            edit in fact, it could be because I don't have the Si7021 connected? Could this be the reason a sketch is not uploading successfully? :worried:

                            m26872M Offline
                            m26872M Offline
                            m26872
                            Hardware Contributor
                            wrote on last edited by
                            #49

                            @rsachoc Start simple. Try on a board without nRF and sensors. Remove everything in the sketch and make it to just print "Hello world" back to serial monitor.

                            1 Reply Last reply
                            0
                            • rsachocR Offline
                              rsachocR Offline
                              rsachoc
                              wrote on last edited by
                              #50

                              Thanks, I haven't actually built a new node, but have been double checking everything on my current node. One thing I wanted to confirm, the 4.7uf capacitor, does the negative leg have to be on the corner of the board, as this is the way I have it currently? I think looking at the board layout in the main slim node thread, it should be the positive leg on the corner and the negative leg on the side of the board (the short side of the board)?

                              m26872M 1 Reply Last reply
                              0
                              • rsachocR rsachoc

                                Thanks, I haven't actually built a new node, but have been double checking everything on my current node. One thing I wanted to confirm, the 4.7uf capacitor, does the negative leg have to be on the corner of the board, as this is the way I have it currently? I think looking at the board layout in the main slim node thread, it should be the positive leg on the corner and the negative leg on the side of the board (the short side of the board)?

                                m26872M Offline
                                m26872M Offline
                                m26872
                                Hardware Contributor
                                wrote on last edited by
                                #51

                                @rsachoc I don't have it in front of me rigth now... but, there should be an arc and a super-small "+"-sign next to the positive pad. Maybe it just look like a dot.

                                1 Reply Last reply
                                0
                                • rsachocR Offline
                                  rsachocR Offline
                                  rsachoc
                                  wrote on last edited by rsachoc
                                  #52

                                  Ok so that may be the problem then! Let me solder it the right way and see if that helps otherwise I'm going to create a bare bones slim mode as suggested

                                  edit to confirm the positive leg of the capacitor goes to the positive marked plus sign hole on the board?

                                  1 Reply Last reply
                                  0
                                  • rsachocR Offline
                                    rsachocR Offline
                                    rsachoc
                                    wrote on last edited by
                                    #53

                                    OK so I changed the polarity of the 4.7uf capacitor and I'm still receiving the same error. So I built a barebones one without sensor and without NRF. I am still getting the same error when uploading the sketch via the FTDI adaptor. I tried uploading a sketch to a Sensebender I have and it worked fine, so that rules out the FTDI adaptor.

                                    Some pics in case someone can spot something obvious.

                                    http://i.imgur.com/1SV0qO2.jpg

                                    http://i.imgur.com/mUp87hB.jpg

                                    http://i.imgur.com/oCqcDpo.jpg

                                    So I can only think that it must be related to the ATMega bootloader? In the how to burn a bootloader thread, I received the following when trying to burn the bootloader, so I assumed it uploaded correctly?

                                    C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/bin/avrdude -CC:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/etc/avrdude.conf -v -patmega328p -cstk500v1 -PCOM5 -b19200 -e -Ulock:w:0x3F:m -Uefuse:w:0x05:m -Uhfuse:w:0xDE:m -Ulfuse:w:0xFF:m 
                                    
                                    avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
                                             Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
                                             Copyright (c) 2007-2009 Joerg Wunsch
                                    
                                             System wide configuration file is "C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/etc/avrdude.conf"
                                    
                                             Using Port                    : COM5
                                             Using Programmer              : stk500v1
                                             Overriding Baud Rate          : 19200
                                             AVR Part                      : ATmega328P
                                             Chip Erase delay              : 9000 us
                                             PAGEL                         : PD7
                                             BS2                           : PC2
                                             RESET disposition             : dedicated
                                             RETRY pulse                   : SCK
                                             serial program mode           : yes
                                             parallel program mode         : yes
                                             Timeout                       : 200
                                             StabDelay                     : 100
                                             CmdexeDelay                   : 25
                                             SyncLoops                     : 32
                                             ByteDelay                     : 0
                                             PollIndex                     : 3
                                             PollValue                     : 0x53
                                             Memory Detail                 :
                                    
                                                                      Block Poll               Page                       Polled
                                               Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
                                               ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
                                               eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
                                               flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
                                               lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                               hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                               efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                               lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                               calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                               signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
                                    
                                             Programmer Type : STK500
                                             Description     : Atmel STK500 Version 1.x firmware
                                             Hardware Version: 2
                                             Firmware Version: 1.18
                                             Topcard         : Unknown
                                             Vtarget         : 0.0 V
                                             Varef           : 0.0 V
                                             Oscillator      : Off
                                             SCK period      : 0.1 us
                                    
                                    avrdude: AVR device initialized and ready to accept instructions
                                    
                                    Reading | ################################################## | 100% 0.02s
                                    
                                    avrdude: Device signature = 0x1e950f
                                    avrdude: erasing chip
                                    avrdude: reading input file "0x3F"
                                    avrdude: writing lock (1 bytes):
                                    
                                    Writing | ################################################## | 100% 0.01s
                                    
                                    avrdude: 1 bytes of lock written
                                    avrdude: verifying lock memory against 0x3F:
                                    avrdude: load data lock data from input file 0x3F:
                                    avrdude: input file 0x3F contains 1 bytes
                                    avrdude: reading on-chip lock data:
                                    
                                    C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/bin/avrdude -CC:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/etc/avrdude.conf -v -patmega328p -cstk500v1 -PCOM5 -b19200 -Uflash:w:C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex:i -Ulock:w:0x0F:m 
                                    Reading | ################################################## | 100% 0.01s
                                    
                                    avrdude: verifying ...
                                    avrdude: 1 bytes of lock verified
                                    avrdude: reading input file "0x05"
                                    avrdude: writing efuse (1 bytes):
                                    
                                    Writing | ################################################## | 100% 0.01s
                                    
                                    avrdude: 1 bytes of efuse written
                                    avrdude: verifying efuse memory against 0x05:
                                    avrdude: load data efuse data from input file 0x05:
                                    avrdude: input file 0x05 contains 1 bytes
                                    avrdude: reading on-chip efuse data:
                                    
                                    Reading | ################################################## | 100% 0.01s
                                    
                                    avrdude: verifying ...
                                    avrdude: 1 bytes of efuse verified
                                    avrdude: reading input file "0xDE"
                                    avrdude: writing hfuse (1 bytes):
                                    
                                    Writing | ################################################## | 100% 0.01s
                                    
                                    avrdude: 1 bytes of hfuse written
                                    avrdude: verifying hfuse memory against 0xDE:
                                    avrdude: load data hfuse data from input file 0xDE:
                                    avrdude: input file 0xDE contains 1 bytes
                                    avrdude: reading on-chip hfuse data:
                                    
                                    Reading | ################################################## | 100% 0.01s
                                    
                                    avrdude: verifying ...
                                    avrdude: 1 bytes of hfuse verified
                                    avrdude: reading input file "0xFF"
                                    avrdude: writing lfuse (1 bytes):
                                    
                                    Writing | ################################################## | 100% 0.01s
                                    
                                    avrdude: 1 bytes of lfuse written
                                    avrdude: verifying lfuse memory against 0xFF:
                                    avrdude: load data lfuse data from input file 0xFF:
                                    avrdude: input file 0xFF contains 1 bytes
                                    avrdude: reading on-chip lfuse data:
                                    
                                    Reading | ################################################## | 100% 0.01s
                                    
                                    avrdude: verifying ...
                                    avrdude: 1 bytes of lfuse verified
                                    
                                    avrdude done.  Thank you.
                                    
                                    
                                    avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
                                             Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
                                             Copyright (c) 2007-2009 Joerg Wunsch
                                    
                                             System wide configuration file is "C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/etc/avrdude.conf"
                                    
                                             Using Port                    : COM5
                                             Using Programmer              : stk500v1
                                             Overriding Baud Rate          : 19200
                                             AVR Part                      : ATmega328P
                                             Chip Erase delay              : 9000 us
                                             PAGEL                         : PD7
                                             BS2                           : PC2
                                             RESET disposition             : dedicated
                                             RETRY pulse                   : SCK
                                             serial program mode           : yes
                                             parallel program mode         : yes
                                             Timeout                       : 200
                                             StabDelay                     : 100
                                             CmdexeDelay                   : 25
                                             SyncLoops                     : 32
                                             ByteDelay                     : 0
                                             PollIndex                     : 3
                                             PollValue                     : 0x53
                                             Memory Detail                 :
                                    
                                                                      Block Poll               Page                       Polled
                                               Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
                                               ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
                                               eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
                                               flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
                                               lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                               hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                               efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                               lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                               calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                               signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
                                    
                                             Programmer Type : STK500
                                             Description     : Atmel STK500 Version 1.x firmware
                                             Hardware Version: 2
                                             Firmware Version: 1.18
                                             Topcard         : Unknown
                                             Vtarget         : 0.0 V
                                             Varef           : 0.0 V
                                             Oscillator      : Off
                                             SCK period      : 0.1 us
                                    
                                    avrdude: AVR device initialized and ready to accept instructions
                                    
                                    Reading | ################################################## | 100% 0.02s
                                    
                                    avrdude: Device signature = 0x1e950f
                                    avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
                                             To disable this feature, specify the -D option.
                                    avrdude: erasing chip
                                    avrdude: reading input file "C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex"
                                    avrdude: writing flash (32768 bytes):
                                    
                                    Writing | ################################################## | 100% 0.00s
                                    
                                    avrdude: 32768 bytes of flash written
                                    avrdude: verifying flash memory against C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex:
                                    avrdude: load data flash data from input file C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex:
                                    avrdude: input file C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex contains 32768 bytes
                                    avrdude: reading on-chip flash data:
                                    
                                    Reading | ################################################## | 100% -0.00s
                                    
                                    avrdude: verifying ...
                                    avrdude: 32768 bytes of flash verified
                                    avrdude: reading input file "0x0F"
                                    avrdude: writing lock (1 bytes):
                                    
                                    Writing | ################################################## | 100% 0.02s
                                    
                                    avrdude: 1 bytes of lock written
                                    avrdude: verifying lock memory against 0x0F:
                                    avrdude: load data lock data from input file 0x0F:
                                    avrdude: input file 0x0F contains 1 bytes
                                    avrdude: reading on-chip lock data:
                                    
                                    Reading | ################################################## | 100% 0.01s
                                    
                                    avrdude: verifying ...
                                    avrdude: 1 bytes of lock verified
                                    
                                    avrdude done.  Thank you.
                                    
                                    m26872M 1 Reply Last reply
                                    0
                                    • rsachocR rsachoc

                                      OK so I changed the polarity of the 4.7uf capacitor and I'm still receiving the same error. So I built a barebones one without sensor and without NRF. I am still getting the same error when uploading the sketch via the FTDI adaptor. I tried uploading a sketch to a Sensebender I have and it worked fine, so that rules out the FTDI adaptor.

                                      Some pics in case someone can spot something obvious.

                                      http://i.imgur.com/1SV0qO2.jpg

                                      http://i.imgur.com/mUp87hB.jpg

                                      http://i.imgur.com/oCqcDpo.jpg

                                      So I can only think that it must be related to the ATMega bootloader? In the how to burn a bootloader thread, I received the following when trying to burn the bootloader, so I assumed it uploaded correctly?

                                      C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/bin/avrdude -CC:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/etc/avrdude.conf -v -patmega328p -cstk500v1 -PCOM5 -b19200 -e -Ulock:w:0x3F:m -Uefuse:w:0x05:m -Uhfuse:w:0xDE:m -Ulfuse:w:0xFF:m 
                                      
                                      avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
                                               Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
                                               Copyright (c) 2007-2009 Joerg Wunsch
                                      
                                               System wide configuration file is "C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/etc/avrdude.conf"
                                      
                                               Using Port                    : COM5
                                               Using Programmer              : stk500v1
                                               Overriding Baud Rate          : 19200
                                               AVR Part                      : ATmega328P
                                               Chip Erase delay              : 9000 us
                                               PAGEL                         : PD7
                                               BS2                           : PC2
                                               RESET disposition             : dedicated
                                               RETRY pulse                   : SCK
                                               serial program mode           : yes
                                               parallel program mode         : yes
                                               Timeout                       : 200
                                               StabDelay                     : 100
                                               CmdexeDelay                   : 25
                                               SyncLoops                     : 32
                                               ByteDelay                     : 0
                                               PollIndex                     : 3
                                               PollValue                     : 0x53
                                               Memory Detail                 :
                                      
                                                                        Block Poll               Page                       Polled
                                                 Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
                                                 ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
                                                 eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
                                                 flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
                                                 lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                                 hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                                 efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                                 lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                                 calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                                 signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
                                      
                                               Programmer Type : STK500
                                               Description     : Atmel STK500 Version 1.x firmware
                                               Hardware Version: 2
                                               Firmware Version: 1.18
                                               Topcard         : Unknown
                                               Vtarget         : 0.0 V
                                               Varef           : 0.0 V
                                               Oscillator      : Off
                                               SCK period      : 0.1 us
                                      
                                      avrdude: AVR device initialized and ready to accept instructions
                                      
                                      Reading | ################################################## | 100% 0.02s
                                      
                                      avrdude: Device signature = 0x1e950f
                                      avrdude: erasing chip
                                      avrdude: reading input file "0x3F"
                                      avrdude: writing lock (1 bytes):
                                      
                                      Writing | ################################################## | 100% 0.01s
                                      
                                      avrdude: 1 bytes of lock written
                                      avrdude: verifying lock memory against 0x3F:
                                      avrdude: load data lock data from input file 0x3F:
                                      avrdude: input file 0x3F contains 1 bytes
                                      avrdude: reading on-chip lock data:
                                      
                                      C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/bin/avrdude -CC:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/etc/avrdude.conf -v -patmega328p -cstk500v1 -PCOM5 -b19200 -Uflash:w:C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex:i -Ulock:w:0x0F:m 
                                      Reading | ################################################## | 100% 0.01s
                                      
                                      avrdude: verifying ...
                                      avrdude: 1 bytes of lock verified
                                      avrdude: reading input file "0x05"
                                      avrdude: writing efuse (1 bytes):
                                      
                                      Writing | ################################################## | 100% 0.01s
                                      
                                      avrdude: 1 bytes of efuse written
                                      avrdude: verifying efuse memory against 0x05:
                                      avrdude: load data efuse data from input file 0x05:
                                      avrdude: input file 0x05 contains 1 bytes
                                      avrdude: reading on-chip efuse data:
                                      
                                      Reading | ################################################## | 100% 0.01s
                                      
                                      avrdude: verifying ...
                                      avrdude: 1 bytes of efuse verified
                                      avrdude: reading input file "0xDE"
                                      avrdude: writing hfuse (1 bytes):
                                      
                                      Writing | ################################################## | 100% 0.01s
                                      
                                      avrdude: 1 bytes of hfuse written
                                      avrdude: verifying hfuse memory against 0xDE:
                                      avrdude: load data hfuse data from input file 0xDE:
                                      avrdude: input file 0xDE contains 1 bytes
                                      avrdude: reading on-chip hfuse data:
                                      
                                      Reading | ################################################## | 100% 0.01s
                                      
                                      avrdude: verifying ...
                                      avrdude: 1 bytes of hfuse verified
                                      avrdude: reading input file "0xFF"
                                      avrdude: writing lfuse (1 bytes):
                                      
                                      Writing | ################################################## | 100% 0.01s
                                      
                                      avrdude: 1 bytes of lfuse written
                                      avrdude: verifying lfuse memory against 0xFF:
                                      avrdude: load data lfuse data from input file 0xFF:
                                      avrdude: input file 0xFF contains 1 bytes
                                      avrdude: reading on-chip lfuse data:
                                      
                                      Reading | ################################################## | 100% 0.01s
                                      
                                      avrdude: verifying ...
                                      avrdude: 1 bytes of lfuse verified
                                      
                                      avrdude done.  Thank you.
                                      
                                      
                                      avrdude: Version 6.0.1, compiled on Apr 15 2015 at 19:59:58
                                               Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
                                               Copyright (c) 2007-2009 Joerg Wunsch
                                      
                                               System wide configuration file is "C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\tools\avr/etc/avrdude.conf"
                                      
                                               Using Port                    : COM5
                                               Using Programmer              : stk500v1
                                               Overriding Baud Rate          : 19200
                                               AVR Part                      : ATmega328P
                                               Chip Erase delay              : 9000 us
                                               PAGEL                         : PD7
                                               BS2                           : PC2
                                               RESET disposition             : dedicated
                                               RETRY pulse                   : SCK
                                               serial program mode           : yes
                                               parallel program mode         : yes
                                               Timeout                       : 200
                                               StabDelay                     : 100
                                               CmdexeDelay                   : 25
                                               SyncLoops                     : 32
                                               ByteDelay                     : 0
                                               PollIndex                     : 3
                                               PollValue                     : 0x53
                                               Memory Detail                 :
                                      
                                                                        Block Poll               Page                       Polled
                                                 Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
                                                 ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
                                                 eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
                                                 flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
                                                 lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                                 hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                                 efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                                 lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                                 calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                                 signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
                                      
                                               Programmer Type : STK500
                                               Description     : Atmel STK500 Version 1.x firmware
                                               Hardware Version: 2
                                               Firmware Version: 1.18
                                               Topcard         : Unknown
                                               Vtarget         : 0.0 V
                                               Varef           : 0.0 V
                                               Oscillator      : Off
                                               SCK period      : 0.1 us
                                      
                                      avrdude: AVR device initialized and ready to accept instructions
                                      
                                      Reading | ################################################## | 100% 0.02s
                                      
                                      avrdude: Device signature = 0x1e950f
                                      avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
                                               To disable this feature, specify the -D option.
                                      avrdude: erasing chip
                                      avrdude: reading input file "C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex"
                                      avrdude: writing flash (32768 bytes):
                                      
                                      Writing | ################################################## | 100% 0.00s
                                      
                                      avrdude: 32768 bytes of flash written
                                      avrdude: verifying flash memory against C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex:
                                      avrdude: load data flash data from input file C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex:
                                      avrdude: input file C:\Users\James\Desktop\RPi Openhab\arduino-1.6.7-windows\hardware\arduino\avr/bootloaders/optiboot/optiboot_atmega328.hex contains 32768 bytes
                                      avrdude: reading on-chip flash data:
                                      
                                      Reading | ################################################## | 100% -0.00s
                                      
                                      avrdude: verifying ...
                                      avrdude: 32768 bytes of flash verified
                                      avrdude: reading input file "0x0F"
                                      avrdude: writing lock (1 bytes):
                                      
                                      Writing | ################################################## | 100% 0.02s
                                      
                                      avrdude: 1 bytes of lock written
                                      avrdude: verifying lock memory against 0x0F:
                                      avrdude: load data lock data from input file 0x0F:
                                      avrdude: input file 0x0F contains 1 bytes
                                      avrdude: reading on-chip lock data:
                                      
                                      Reading | ################################################## | 100% 0.01s
                                      
                                      avrdude: verifying ...
                                      avrdude: 1 bytes of lock verified
                                      
                                      avrdude done.  Thank you.
                                      
                                      m26872M Offline
                                      m26872M Offline
                                      m26872
                                      Hardware Contributor
                                      wrote on last edited by
                                      #54

                                      @rsachoc Looks like you're missing the R1 resistor?

                                      rsachocR 1 Reply Last reply
                                      0
                                      • m26872M m26872

                                        @rsachoc Looks like you're missing the R1 resistor?

                                        rsachocR Offline
                                        rsachocR Offline
                                        rsachoc
                                        wrote on last edited by
                                        #55

                                        @m26872 well that is probably it! I didn't even realise I needed that, oops! Sorry :disappointed: ! Let me try and get one (I think I have some already) and get soldering

                                        rsachocR 1 Reply Last reply
                                        0
                                        • rsachocR rsachoc

                                          @m26872 well that is probably it! I didn't even realise I needed that, oops! Sorry :disappointed: ! Let me try and get one (I think I have some already) and get soldering

                                          rsachocR Offline
                                          rsachocR Offline
                                          rsachoc
                                          wrote on last edited by
                                          #56

                                          It lives! Well the one node I created does at least! I'll troubleshoot it, but the problem was the R1 resistor, which I (noobishly) forgot about! But very pleased, and thanks to m26872 especially and everyone else who helped.

                                          I've updated the lessons learn post too!

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          7

                                          Online

                                          11.7k

                                          Users

                                          11.2k

                                          Topics

                                          113.0k

                                          Posts


                                          Copyright 2019 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • MySensors
                                          • OpenHardware.io
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular