Welcome! Log In Create A New Profile

Advanced

Pronterface, linux, RAMPS, and 250000 baud rate

Posted by alik 
Pronterface, linux, RAMPS, and 250000 baud rate
October 31, 2012 04:36PM
Hello guys.

I'm trying to use pronterface in my Arch linux.
However, when I'm trying to set baud rate to 250000 I've got error:
ValueError: Failed to set custom baud rate: 250000.

I know that this is not standard baud rate (standard one is 230400), but 250000 is preferrable for ATMega2560, so maybe it's possible to configure it somehow in linux?

Thanks in advance.
Re: Pronterface, linux, RAMPS, and 250000 baud rate
October 31, 2012 04:56PM
Many linux distros will not work with that baud rate, use 115200 (or whatever the one close to this is).
Re: Pronterface, linux, RAMPS, and 250000 baud rate
November 01, 2012 03:26AM
Thanks, crispy1.
It looks like there is no easy solution of this problem sad smiley
So, probably I have to use one of standatd baud rates.
Re: Pronterface, linux, RAMPS, and 250000 baud rate
June 29, 2013 05:27PM
Nobody has a solution for this problem? I've tried with debian and Ubuntu and I've never maken pronterface to connect to the Arduino Mega 2560 w/Ramps 1.4, I'm working on Windows 7 where the problem doesn't appear.

I searched in the web for an answer to this problem some time ago but nobody talked about it, now I'm reading this topic without solution and this forum unresolving the problem too...

The next attempt to make pronterface connect with arduino mega on linux is trying with fedora 17 and I'm going to continue using windows...

Thanks to all forumers!!

Attached a picture-capture of the problem.
Attachments:
open | download - Captura de pantalla de 2013-06-29 23:20:43.png (248.4 KB)
Re: Pronterface, linux, RAMPS, and 250000 baud rate
June 29, 2013 05:31PM
i ended up having to go with 115200 for my baud rate under kubuntu


[mike-mack.blogspot.com]
Re: Pronterface, linux, RAMPS, and 250000 baud rate
July 01, 2013 04:34PM
There is patch to pyserial to solve the problem.
I use it successfully.
[groups.google.com]

Edited 1 time(s). Last edit at 07/01/2013 04:35PM by karabas.
Re: Pronterface, linux, RAMPS, and 250000 baud rate
July 01, 2013 07:01PM
Karabas, Have you got a link to the patch or how to make it works successfully, it would be very useful for me and also it could make me sleep deeply finally...

Dissidence, are you using the Arduino Mega 2560 with Ramps 1.4? I think it needs the 250000 of baud rate...
Re: Pronterface, linux, RAMPS, and 250000 baud rate
July 01, 2013 07:12PM
yes i am using the arduino mega 2560 and ramps 1.4. and no it dose not need it but i think it works more smoothly at that baud rate. that is all defined in the firmware.

i have printed a lot of things at 115200 with no issues. but on things with a lot of small moves then i will notice the pauses.


[mike-mack.blogspot.com]
Re: Pronterface, linux, RAMPS, and 250000 baud rate
July 07, 2013 10:15AM
I use Arduno 2560


From the above link
"Martin Renold Apr 14:
Thanks for pointing this patch out, I've just upgraded my baudrate now.

I think the better way to install is:

svn co [pyserial.svn.sourceforge.net] pyserial
cd pyserial
patch -p0 < ../pyserial.patch
cd pyserial
python setup.py install --user
python3 setup.py install --user
"

Edited 1 time(s). Last edit at 07/07/2013 10:17AM by karabas.
Re: Pronterface, linux, RAMPS, and 250000 baud rate
July 09, 2013 12:37PM
Amazing! Worked perfectly for me, on both Ubuntu 13.04 and Ubuntu Server 12.04. I'll test on Raspbian at some point, though I don't see why it wouldn't work there just as well.

Having never used patch before, I was a bit confused by the instructions describing the better way to do it. So, for similarly confused people, you first need to download the patch file from the first link, and have it sitting in the directory above where you clone pyserial. Dumb, I know, but everyone has their moments.
Re: Pronterface, linux, RAMPS, and 250000 baud rate
August 25, 2014 12:27AM
i made these package with the patch already applied, these are for ubuntu trusty 14.04. install them with dpkg -i python*-serial_2.6-1build1_all.deb
Attachments:
open | download - python3-serial_2.6-1build1_all.deb (48.7 KB)
open | download - python-serial_2.6-1build1_all.deb (64.7 KB)
Re: Pronterface, linux, RAMPS, and 250000 baud rate
September 06, 2014 12:18AM
This help me solve my issues with connecting to my ramps 1.4 marlin using

Distributor ID: Debian
Description: Debian GNU/Linux 7.6 (wheezy)
Release: 7.6
Codename: wheezy

I wanted to thank you for your time.
Re: Pronterface, linux, RAMPS, and 250000 baud rate
September 06, 2014 10:11AM
Fall back to 115,200 baud. Some computers/operating systems have problems running any faster than this.....
Re: Pronterface, linux, RAMPS, and 250000 baud rate
September 07, 2014 02:25AM
Unless there is a bug in the Linux Kernel, or somewhere else, there is nothing that should prevent you from connecting to an arduino at 250000. With that said, in the case of Ubuntu 14.04, the problem is the use of pyserial 2.6 that does not, normally, include the patch to allow the use of custom baud rates in python programs. For those with other GNU/Linux versions, the next version; pyserial 2.7, should already include that patch. I recompiled the same version that Ubuntu 14.04 provide, with the patch, because i wanted to avoid any bugs 2.7 might bring along.

Anyway, personally, i believe that, not being able to connect at the speed you want in GNU/Linux, when it did work in windows, is a serious issue. But the release system being what it is, these kinds of fixes can take some time to get through. In the case of Ubuntu, the problem might not even get fixed by the time 14.10 gets out. The problem being that pyserial 2.7 is new enough that its not even in Debian Unstable yet. In any case, i will keep an eye on this topic.

Edited 1 time(s). Last edit at 09/07/2014 02:40AM by swe3tdave.
Re: Pronterface, linux, RAMPS, and 250000 baud rate ... what worked for me
December 27, 2014 01:48PM
Hello all ... don't know if this is relevant any more or not but thought I'd add what worked for me. I'm running Ubuntu 12.04 LTS and RAMPs 1.4.

I tried the generic apt install pyserial to get the packages that pronterface needs as documented in many instruction sets on the topic. As many have discovered, the baud rate of 250000 generates an error. The suggestion in multiple forums was to apply pyserial.patch. I tried that in multiple ways using the patch command. The patch failed (probably because the patch had already been incorporated into the distribution).

Finally, I just decided to merge several solutions. I downloaded pyserial using the more specific path given above:
svn co [svn.code.sf.net] pyserial

(Note: seems that the post formatter doesn't show the whole path above. It's svn, dot, code, dot, sf, dot, net, slash, p/pyserial/code/trunk . If you mouse over it, it appears at the bottom of the browser.)

Hoping that the patch had already found it's way into the distribution, I just installed it:
python setup.py install --user
python3 setup.py install --user

Restarted pronterface ...
... AND IT WORKED !

Edited 1 time(s). Last edit at 12/28/2014 11:19AM by djzman.
Re: Pronterface, linux, RAMPS, and 250000 baud rate
August 31, 2015 12:54AM
Thanks for the .deb files, The python3 did the trick for me. Very new to python and did not understand the line "svn co [pyserial.svn.sourceforge.net] pyserial" posted by others previously in this thread. All else is obvious. If someone has the time... I am curious what it means and how to accomplish... future reference.

thanks
Re: Pronterface, linux, RAMPS, and 250000 baud rate
November 09, 2015 12:23PM
And its 2015 and I still seemed to not have the patch

Am on ubuntu 114.04

I downloaded the sources from [github.com] (so not svn)
Ran

python setup.py install --user
python3 setup.py install --user

Restarted pronterface ...
... AND IT WORKED !

Edited 1 time(s). Last edit at 11/09/2015 12:23PM by brentgracey.
Re: Pronterface, linux, RAMPS, and 250000 baud rate
November 09, 2015 01:20PM
Even though there are upgrade on Ubuntu 14.04, for the most part, its only security fixes. If you are using 14.04, of course the problem will still be there. This is because of the development model Ubuntu uses is more of a "frozen cycle" model, there is pretty much no software versions changes unless you change to a newer Ubuntu release. This is done to help stabilize the whole system, and to lower down the work load on the developers. The problem is that every time you upgrade one component, you often introduce bugs in other components. Even if its to repair a bug, it is just not worth the risk. It might be ok on a beta release, but its not on a stable one. Even if that means getting stuck with a bug until the next release or more... If you want more regular upgrade, you could try debian testing or debian unstable. But, personally, i've tried both and a simple upgrade can sometimes leave you stuck with a system that just wont boot.
Sorry, only registered users may post in this forum.

Click here to login