Announcement

Collapse
No announcement yet.

Arduino Plugin For Linux (Beta)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • enigmatheatre
    replied
    Originally posted by MattLau View Post
    HI,

    Is there any plan to support direct communication via LInux ? Or it will always be Ethernet only? Thank you
    There are no short-term plans to add USB support to Linux.

    Greig

    Leave a comment:


  • Guest
    Guest replied
    HI,

    Is there any plan to support direct communication via LInux ? Or it will always be Ethernet only? Thank you

    Leave a comment:


  • enigmatheatre
    replied
    Originally posted by dsieg61 View Post
    Thanks,
    I will try selecting just the Arduino next time. But I still think that you can not upload a sketch from the Arduino IDE environment directly over the network (no serial connection). Am I wrong with this? It seems that you need to do the sketch upload with the Uno attached via a serial port (on either windows or Linux). Once uploaded, the serial port can be disconnected and the Arduino will execute on the network. I have not tried connecting the Arduino to the USB connection on my Pi and uploading from there. I suspect that the /dev/ttyAMA0 port that comes up in the Arduino IDE environment (which I thought was a network->USB conversion device) on the Pi is actually the USB wireless keyboard dongle I am using. So, essentially I have been trying to upload the sketch to the keyboard.... ugh!
    Regards,
    David
    David,

    Yes this is correct, you can not update the sketch over the network it has to be a seria/usb connection. The latest Beta supports update of the sketch over wifi to the NodeMCU boards but this is not possible on the standard network shield.

    Greig.

    Leave a comment:


  • dsieg61
    replied
    Thanks,
    I will try selecting just the Arduino next time. But I still think that you can not upload a sketch from the Arduino IDE environment directly over the network (no serial connection). Am I wrong with this? It seems that you need to do the sketch upload with the Uno attached via a serial port (on either windows or Linux). Once uploaded, the serial port can be disconnected and the Arduino will execute on the network. I have not tried connecting the Arduino to the USB connection on my Pi and uploading from there. I suspect that the /dev/ttyAMA0 port that comes up in the Arduino IDE environment (which I thought was a network->USB conversion device) on the Pi is actually the USB wireless keyboard dongle I am using. So, essentially I have been trying to upload the sketch to the keyboard.... ugh!
    Regards,
    David

    Leave a comment:


  • enigmatheatre
    replied
    Originally posted by dsieg61 View Post
    Well, I think that I have been way off base the whole time. I assumed that in the Arduino IDE environment, that selecting the "Arduino Ethernet" as the board, and com port "/dev/ttyAMA0" (on Linux), that it would just upload to the Arduino Uno. Obviously, it doesn't work that way. Running the Arduino IDE from the Windoze box, it only has a selection for "Com 3". Nothing about the network. Reading some ardunio posts, you can program the unit over the network, but you need to set up a tftpboot environment. After enabling the verbose logging on the windows IDE and uploading via com 3, I saw that it logged a bunch of stuff including the upload status. I never got anything like this on the Linux side. So, basically, it never connects to the arduino and therefore does not know where to upload the sketch file. Even though it never logs it, it must just timeout after a while.
    In summary, you can have the Arduino work over the network, but it has to have the sketch uploaded via a windows serial port connected to the arduino, then removed from the serial port and connected to the network. Works fine then.
    If anyone has a different view-point on this, let me know. I am still new to the Arduino, and am no expert.
    Regards,
    David
    OK this would be the problem. If you are selecting "Arduino Ethernet" as the board then it will not upload on to the Uno with an ethernet shield as the "Arduino Ethernet" board is a different product and not an Uno. You need to select Uno as your board as that is what you are using and the Sketch tells the board it has the Ethernet shield on it and the Arduino IDE.

    Greig.

    Leave a comment:


  • Searider
    replied
    Originally posted by dsieg61 View Post
    In summary, you can have the Arduino work over the network, but it has to have the sketch uploaded via a windows serial port connected to the arduino, then removed from the serial port and connected to the network. Works fine then.

    David
    I only use Windows but this is how I have done it using the Node-MCU board.

    Leave a comment:


  • dsieg61
    replied
    Well, I think that I have been way off base the whole time. I assumed that in the Arduino IDE environment, that selecting the "Arduino Ethernet" as the board, and com port "/dev/ttyAMA0" (on Linux), that it would just upload to the Arduino Uno. Obviously, it doesn't work that way. Running the Arduino IDE from the Windoze box, it only has a selection for "Com 3". Nothing about the network. Reading some ardunio posts, you can program the unit over the network, but you need to set up a tftpboot environment. After enabling the verbose logging on the windows IDE and uploading via com 3, I saw that it logged a bunch of stuff including the upload status. I never got anything like this on the Linux side. So, basically, it never connects to the arduino and therefore does not know where to upload the sketch file. Even though it never logs it, it must just timeout after a while.
    In summary, you can have the Arduino work over the network, but it has to have the sketch uploaded via a windows serial port connected to the arduino, then removed from the serial port and connected to the network. Works fine then.
    If anyone has a different view-point on this, let me know. I am still new to the Arduino, and am no expert.
    Regards,
    David

    Leave a comment:


  • dsieg61
    replied
    dhalsall,
    Thanks for the info. It is actually a knockoff Arduino Uno. I have seen posts that indicate that there is an issue around the W5100 reset times conflicting with the bootloader. Holding the reset button during the time it says "Compiling", and release when it says "Uploading", removing resistors on the W5100 next to the reset switch, etc. The reset button thing did not work, and there appear to be differences on my W5100 board than others (the beauty of knockoffs ;( ). So, I will do some more research to see if I can find a path forward. Probably should just bite the bullet and get genuine Arduino stuff. In the meantime, I have a way to experiment with what was the original intention:

    To create a inexpensive remote unit that can provide temp, motion, light levels, etc. back to my HS3 app.
    Regards,
    David

    Leave a comment:


  • dhalsall
    replied
    Hi David,

    I haven't experienced your issue exactly, but I did run into issues when moving to a newer version some time ago.

    For my only Linux install, I'm having success on a Mega with:

    Sketch Ver. 1.0.0.101
    Plugin Ver. 1.0.103

    I realize it may not be possible to go back to those versions, but just FYI.

    Is it a Mega 2560 you're using also?

    Leave a comment:


  • dsieg61
    replied
    Thanks Greig,
    I actually am beginning to think that this is an issue with the W5100 Network Shield. There are a number of posts (on other sites) of people with the same issue as myself (not being able to upload a sketch with the W5100 shield attached). So, for now I will update and upload the sketch from the windows box. Once uploaded, I can disconnect from the serial and connect to the network, and it is fine. Kind of a pain though.
    Regards,
    David

    Leave a comment:


  • enigmatheatre
    replied
    Originally posted by dsieg61 View Post
    Thanks for the quick replies!
    OK, so I have a windoze10 box. I am trying these two versions of the Sketch file:
    HomeseerBoard1-v1: This is a sketch(version 127) created from the Arduino plugin on the windows box. This is the one that has worked in the past.

    HomeseerBoard1-v6: This is a sketch (version 145) created from the Arduino plugin on the Raspberry Pi, and copied over to the windows box. The one I can't get to upload to the Arduino from Linux IDE

    Taking your advice above, I figure I would be able to take the Pi Sketch and upload it with Arduino IDE on the windows box, remove it from the Windows box, plug it into the network and all would be good.

    Using either Arduino IDE 1.6.8, or 1.8.5 on the windows box, via connection through the com3 port, with either Genuine Ardunio, or Arduino Ethernet selected, I can upload both sketches to the Arduino (via com3). When done uploading, ping will only respond to the V1 sketch file. There is no network connection using the V6 version.
    Can I really copy over a Linux sketch to the windows box to do the upload to the Arduino?
    Thanks,
    David
    David,

    The plugin uses the same sketch for windows and Linux so it should not matter where it is from. The best way to get it is to browse to the Linux HS system from the windows system then go to the config page and download the sketch.
    The plugin is also the same but checks the OS and makes changes when required.

    Both sketches look fine to me. I see no reason for it not to work.

    Can you please enable debug logging on the plugin config page then try and connect the board again then wait 5min. You can then disable debug logging and click on the link to download it and send it to me to have a look at.

    It looks to me like the board is not updating to the new version but I cant work out why!

    I am off to bed and working tomorrow so it might be a couple of days before I can get back to you.

    Greig.

    Leave a comment:


  • dsieg61
    replied
    Thanks for the quick replies!
    OK, so I have a windoze10 box. I am trying these two versions of the Sketch file:
    HomeseerBoard1-v1: This is a sketch(version 127) created from the Arduino plugin on the windows box. This is the one that has worked in the past.

    HomeseerBoard1-v6: This is a sketch (version 145) created from the Arduino plugin on the Raspberry Pi, and copied over to the windows box. The one I can't get to upload to the Arduino from Linux IDE

    Taking your advice above, I figure I would be able to take the Pi Sketch and upload it with Arduino IDE on the windows box, remove it from the Windows box, plug it into the network and all would be good.

    Using either Arduino IDE 1.6.8, or 1.8.5 on the windows box, via connection through the com3 port, with either Genuine Ardunio, or Arduino Ethernet selected, I can upload both sketches to the Arduino (via com3). When done uploading, ping will only respond to the V1 sketch file. There is no network connection using the V6 version.
    Can I really copy over a Linux sketch to the windows box to do the upload to the Arduino?
    Thanks,
    David
    Attached Files

    Leave a comment:


  • enigmatheatre
    replied
    The sketch looks fine to me.
    The board is not being updated with this sketch so this is a problem with the upload process.
    I have never used the Arduino IDE on Linux so not sure where to go with this.
    Maby some other users will be able to help if they have used it but if you have a windows system available just use that to update the board the connect it to the PI with the Ethernet.

    Greig.

    Sent from my SM-G950F using Tapatalk

    Leave a comment:


  • dsieg61
    replied
    I started from scratch. Attached is the sketch file I am using (basic default sketch). I got rid of the compiler warning messages (except for the memory usage) by rebooting the Pi HS3 server (which is what I am using to compile and upload the Arduino). It still is not updating the Arduino. Seems similar to the above post about pins on the WS5100 EtherShield pins, but it is not clear what you need to do to fix it. I tried to tie D4 high with a resistor to 5v, but that didn't do anything.
    David
    Attached Files

    Leave a comment:


  • enigmatheatre
    replied
    Did you transfer your setup or are you starting from scratch?
    Did you download the sketch from the plugin page on your Linux system and not use the old one?

    Greig.

    Sent from my SM-G950F using Tapatalk

    Leave a comment:

Working...
X