Firstly, I come here often and have had no need to ask for help as my question has already been asked and answered. So to all those that have unknowingly helped me in the past... Thanks.
The problem I have at the moment is when I have both USB and external power connected at the same time, the mega is recognised by ubuntu (14.04) but will not communicate with it.
This wouldn't normally be a problem but since I am using it with a ramps board (3d printing) I need both connected.
I have determined that it is not the ramps board causing the problem (does this with no shields attached) and it is not the mega board as it does the same thing on all my mega boards.
I normally use Cura as my slicer and that used to connect and communicate but not print. So I installed pronterface and thats when I noticed the problem. However, I dont think that is what is causing it (just a gut feeling).
Has anyone else had this problem? Not in any hurry but any suggestions or advice will be most appreciated.
Thanks in advance
The problem I have at the moment is when I have both USB and external power connected at the same time
When you say "external power" where is the external power connected.
the mega is recognised by ubuntu (14.04) but will not communicate with it.
What does "will not communicate" mean?
The power (12v power supply) is connected to the jack next to the USB socket. When connected, Ubuntu will recognise the arduino (/dev/ttyACM0), but will not open the port for serial coms and uploading scripts.
When the 12v power is removed, coms will work perfectly.
All other aspects of the arduino work fine with either or both plugs connected.
Please note, that it was communicating perfectly fine, I could have both USB and power connected and communicate perfectly.
but will not open the port for serial coms and uploading scripts.
What error messages do you receive when you open the serial port.
No serial error messages, it just sits there waiting. However, I have been looking at the syslog and found this:
Jul 12 13:45:02 Cockpit kernel: [ 4574.276053] usb 3-1: USB disconnect, device number 106
Jul 12 13:45:11 Cockpit kernel: [ 4583.160017] usb 3-1: new full-speed USB device number 107 using uhci_hcd
Jul 12 13:45:11 Cockpit kernel: [ 4583.352562] usb 3-1: New USB device found, idVendor=2341, idProduct=0042
Jul 12 13:45:11 Cockpit kernel: [ 4583.352565] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=220
Jul 12 13:45:11 Cockpit kernel: [ 4583.352567] usb 3-1: Manufacturer: Arduino (www.arduino.cc)
Jul 12 13:45:11 Cockpit kernel: [ 4583.352569] usb 3-1: SerialNumber: 85336303532351608290
Jul 12 13:45:11 Cockpit kernel: [ 4583.355603] cdc_acm 3-1:1.0: ttyACM4: USB ACM device
Jul 12 13:45:11 Cockpit mtp-probe: checking bus 3, device 107: "/sys/devices/pci0000:00/0000:00:1d.1/usb3/3-1"
Jul 12 13:45:11 Cockpit mtp-probe: bus: 3, device: 107 was not an MTP device
this is repeated over and over.
Looking into this, albeit only for the last 20 minutes, I found that it may be something to do with the modem manager and found this site:
it suggests that a rule be placed in the /etc/udev/rules.d directory to tell the modem manager to ignore the device.
Still playing around with this idea (never done anything with "rules" before)
If you (or anyone else) have any suggestions, I will be very grateful.
OK, I think I have "fixed" it
Following advice given at:
Not sure if this actually fixed the problem but its working now and as they say "if it works, don't fix it"
Here is what I did:
- create a file called 77-modem-manager-freetronics.rules in the /etc/udev/rules.d directory
- put these 2 lines in there: (as per the site's advice)
- change "26ba" to "2341:0042"
- sudo /etc/init.d/udev restart
- noticed no change so I rebooted
Not sure if the file name can be anything as I have never done anything with rules before. Might study up on it one day.
If anyone notices what may have been done better or anything, please let me know.