4 Replies Latest reply on Jun 5, 2017 1:12 PM by Intel Corporation

    Intel Edison w/ Arduino Breakout Board not working consistenly on external power

    eela20

      I'm working on a project with the Intel Edison and Arduino Breakout Board, and I'm having trouble getting it to work properly with the barrel jack connected to a 9V battery.

       

      Here's a breakdown of the project:

      • I'm recording data from a sensor via the serial connection pins on the Arduino Breakout Board.
      • When data comes in from the sensor, I am storing it in an SD card (the breakout board as an onboard sd slot)
      • The Intel Edison+sensor apparatus has to be able to run off an external power source for the purposes of this project.

       

      When I connect the bottom two mini-USB ports from the Arduino breakout board to my laptop and upload code to the Edison via Arduino IDE, the program seems to run as expected. The Edison recognizes the SD card, creates a file, and writes to that data file with data it reads from sensor. However, when I disconnect the two USB ports and power the Edison through a barrel jack connection with a 9V battery, the board does all kinds of weird things. It will either: 1) work as expected, 2) not create a data file, 3) create a data file but not write any sensor values, resulting in an empty file.

       

      I am not sure what is going on. I read online, and another forum discussion said that I should try flashing the 146 version of the firmware because the current version has a bug or something. This is what I've done, and I'm still getting the above behavior. Another forum post (Run Arduino sketch on boot Workaround ) expanded on this concept, except with copying certain files from the 146 to the 159 version. I have not tried this yet, but I'm wondering how this would be different from just running the 146 version. Is it possible that I should use an even older version of the firmware?

       

      One thing I experienced in this process is that right after flashing the 146 firmware, everything seemed to be running smoothly for 2-3 trials. Then, the board starts acting all funky again.

       

      Any help would be greatly appreciated!

        • 1. Re: Intel Edison w/ Arduino Breakout Board not working consistenly on external power
          Intel Corporation
          This message was posted on behalf of Intel Corporation

          Hello Eela20,

          Thank you for contacting us.

          That's a nice project. As a reminder, consider that the Arduino skecth doesn't start automatically after you turn off the Edison, to do this you have to run the sketch on boot, I'm not sure if the post that you provided works, but it is possible to run the sketch on boot creating a script on init.d, to do this please follow these steps:

          1. Use the command cd /etc/init.d to go to the init.d directory.

          2. Create the script using the following commands: 

          cat << EOF > autosketch.sh
          #!/bin/sh
          /sketch/sketch.elf foo bar
          EOF


          3. Make the script executable by changing the permissions with chmod:  chmod +x autosketch.sh

          4. To make sure this script is executed every time linux boots, issue the following command and wait for the return shown below:

          update-rc.d automateSketch.sh defaults
          Adding system startup for /etc/init.d/automateSketch.sh


          Now the skecth will start every time you turn on your Edison, I tested it using the latest Edison Image that you can download form here: https://software.intel.com/en-us/iot/hardware/edison/downloads

          You shouldn't have issues if you power your Edison through the USB cable, but if you still have issues with the 9 V battery the problem is definitely with the barrel jack or the battery itself. To make sure that the barrel jack works fine, tried to run your sketch using a wall adapter power supply.

          If you don't have issues using the wall adapter power supply, it seems that the battery is not providing enough power to the Edison (Current), please check if the battery is fully charge and check its capacity. Normally in these issues we recommend to power the devices that are connected to the Edison (In your case the sensors) with a different power supply.

          I hope you find this information helpful.

          Have a nice day.

          Regards,
          Leonardo R.

          • 2. Re: Intel Edison w/ Arduino Breakout Board not working consistenly on external power
            Intel Corporation
            This message was posted on behalf of Intel Corporation

            Hello Eela20,

            Do you have updates about this?

            Regards,
            Leonardo R.

            • 3. Re: Intel Edison w/ Arduino Breakout Board not working consistenly on external power
              eela20

              Hi Leonardo,

               

              Thank you so much for your priceless advice. I followed the steps you outlined in your post, and I think it is working fine now. We have tested it multiple times, and have conducted walking tests with an external power source. The system appears to be robust, although I would like to test it a few more times just to be sure it works consistently.

               

              One problem that we had to fix was that after reflashing the firmware to the newest version and configuring the Edison to run on boot, the 9V alkaline battery we were using didn't seem to supply enough power. We measured the battery's voltage, and realized it was practically depleted. Thank you for mentioning that issue; now we are using a LiPo battery, which I think is a much more reliable power source. The Edison also works fine with a 9V wall adapter. Again, thank you for the insight on making sure our power was sufficient.

               

              Sorry for the late reply. Thank you again for helping me out with this issue.

              • 4. Re: Intel Edison w/ Arduino Breakout Board not working consistenly on external power
                Intel Corporation
                This message was posted on behalf of Intel Corporation

                Hello Eela20,

                That's awesome. Thank you so much for letting us know.

                It really was a pleasure to help you, and feel free to contact us when you have issues.

                Have a nice day.

                Regards,
                Leonardo R.