LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
LinkBack Search this Thread
Old 05-31-2011, 11:56 AM   #1
Lantzvillian
Member
 
Registered: Oct 2007
Location: BC, Canada
Distribution: Fedora, Debian
Posts: 193

Rep: Reputation: 38
Unhappy SUSE 11.2 minicom and expect not sending backspaces


Hi all,

I am writing an expect script that will automate flashing an embedded device through minicom using a serial connection and am running into problems sending backspaces.

The script catches the configuration prompt on startup and can flash the device, but setting the MAC addresses in the fconfig are being problematic.

For example, when I run the script, I can set the variables that are defaults by just pressing enter or enter new directives when prompted.. the problem arrises when I need to enter a new MAC address and there is already one set - I need to overwrite it somehow.

If I manually go through fconfig using minicom (minicom version 2.3 (compiled Dec 3 2008)), I can use backspace on my keyboard to remove the old MAC address and enter a new one - no problem.. but with expect.. I am having issues.

I tried sending \b, \^H, \010 \177... These do not work. Minicom has BS set for the backspace key though... I tried setting it to DEL - no luck.

On the other hand, I can send control-C with send "send \003"...

Any help would be great.. thanks!
 
Old 07-01-2011, 07:44 PM   #2
dannybpng
Member
 
Registered: Sep 2003
Location: USA
Distribution: Fedora 20
Posts: 58

Rep: Reputation: 19
Try adding delays

I'm no expert, but it could be that the embedded device needs time to process the backspace or has very little type-ahead buffer space. Either try using the sleep command between each backspace or maybe use 'send -h'

-h flag forces output to be sent (somewhat) like a human actually typing

Just a thought.

Dan
 
  


Reply

Tags
expect, minicom, suse


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] /usr/bin/expect : Script to check server load using both expect and bash Soji Antony Programming 1 07-27-2010 11:27 PM
Problem sending files trough minicom, cutecom pmil Linux - Software 2 07-22-2008 05:43 AM
Minicom via ttyS0: Please help with $TERM, $MINICOM, colors, mouse/gpm. GrapefruiTgirl Linux - Software 2 07-19-2008 07:01 AM
telnet backspaces eastsuse Linux - Newbie 2 12-02-2004 05:38 PM
Sending ascii codes with minicom ganninu Linux - Software 0 08-27-2003 08:01 AM


All times are GMT -5. The time now is 11:06 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration