Puppyserialdetect fix/patch

Under development: PCMCIA, wireless, etc.
Message
Author
Jesse
Posts: 466
Joined: Sun 08 May 2005, 16:07
Location: Auckland, NZ

Puppyserialdetect fix/patch

#1 Post by Jesse »

Hi,

Barry just noticed a problem with latest puppyserialdetect:
http://www.puppylinux.com/news/comments ... 608-031112

Here is a version that'll maybe revert to the original detection scheme.

Version 1.1f:
ADDED README file.
ADDED /dev/ttySX node creation if necessary.
ADDED scan ttyS0 - ttyS4 (inclusive)
REMOVED optimization that might have skipped over a serial modem.
INCLUDES binaries and source code.

Jesse
Attachments
puppyserialdetect-1.1f.tar.gz
(30.3 KiB) Downloaded 1037 times

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#2 Post by BarryK »

Great! But, I'm away from home for 5-6 days and don't have access to a serial modem. Will test as soon as possible.

Jesse
Posts: 466
Joined: Sun 08 May 2005, 16:07
Location: Auckland, NZ

#3 Post by Jesse »

Ok Barry :)

If anyone would like to try out this version, please post if it works or not with your serial modem or internal PCI modem ( /dev/ttyS4 is supposed to be internal PCI modem on some computers), also let us know what make/model it is. If the progam works, it will output a line identifying the modem e.g.:
Type:modem|Port:/dev/ttyS4|Speed:14400

Jesse

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#4 Post by BarryK »

Yes, testers are wanted!
Just to clarify though, if you do have a internal PCI modem, we are only concerned with a true hardware modem -- that's all 'puppyserialdetect' will detect. There aren't too many true-hardware PCI modems around, certainly they are no longer made, and you are only likely to find one in a PC ....how long ago.... 5 years old?

There are apparently some true hardware USB modems, but we havn't got to the point of autodetecting them yet. Except for some models, I'm working on that right now.

Firefox
Posts: 172
Joined: Fri 03 Nov 2006, 12:38
Location: UK

Diamond Modem SupraExpress56e com1 port

#5 Post by Firefox »

I downloaded and installed puppyserialdetect and it detected it ok
Type:modem|Port:/dev/ttys0|Speed:230400

User avatar
Béèm
Posts: 11763
Joined: Wed 22 Nov 2006, 00:47
Location: Brussels IBM Thinkpad R40, 256MB, 20GB, WiFi ipw2100. Frugal Lin'N'Win

#6 Post by Béèm »

Doesn't detect nor the internal modem nor a PCMCIA one.
Only mice's, but as far as I know they aren't serial.
One them is a touchpad.

Code: Select all

sh-3.00# puppyserialdetect
Type:PS2-mouse|Port:/dev/input/mice
Type:PS2-mouse|Port:/dev/input/mice
sh-3.00#
Time savers:
Find packages in a snap and install using Puppy Package Manager (Menu).
[url=http://puppylinux.org/wikka/HomePage]Consult Wikka[/url]
Use peppyy's [url=http://wellminded.com/puppy/pupsearch.html]puppysearch[/url]

Jesse
Posts: 466
Joined: Sun 08 May 2005, 16:07
Location: Auckland, NZ

#7 Post by Jesse »

Hi Béèm,

Are you sure you are running the file that you download?
Normally you have to run it with a ./ prefix, like: ./puppyserialdetect

Code: Select all

sh-3.00# puppyserialdetect 
sh-3.00# ./puppyserialdetect 
Type:USB-mouse|Port:/dev/input/mice
sh-3.00# 
Above you can see that I get two different outputs, from the two different versions on the system, (version with Puppy 2.13 does not detect my usb mouse).

Jesse

muggins
Posts: 6724
Joined: Fri 20 Jan 2006, 10:44
Location: hobart

#8 Post by muggins »

jesse,

i tried ./puppyserialdetect, with pup2.16, and it didn't detect modem on ttyS0. the modem wizard with pup2.16 also doesn't recognise a modem on ttyS0, but if i save, then it's OK. (modemwizard with pup1.08 does see the modem).

jeffrey
Posts: 168
Joined: Mon 16 Jan 2006, 04:20
Location: Christchurch, New Zealand

#9 Post by jeffrey »

No joy with my old Asus PC (500MHz) with external serial modem connected to Com1 (/dev/ttyS0). It does detect the serial mouse (PS/2):

Code: Select all

sh-3.00# ./puppyserialdetect 
Type:PS2-mouse|Port:/dev/input/mice
sh-3.00# 
Let me know if there's something I can run to show you what the hardware is. It's a 3Com US Robotics 56K Faxmodem

jeffrey
Posts: 168
Joined: Mon 16 Jan 2006, 04:20
Location: Christchurch, New Zealand

#10 Post by jeffrey »

... I should perhaps have added that that was done with Puppy 2.14.

zygo
Posts: 243
Joined: Sat 08 Apr 2006, 20:15
Location: UK

#11 Post by zygo »

I get exactly the line that jeffrey got back. My external serial modem is a "3com us robotics 56k voice faxmodem"

The CD I'm running puppy off is remastered with Dougal's program and I accepted the option to customise the iso for this machine (keyboard, mouse).

zygo
Posts: 243
Joined: Sat 08 Apr 2006, 20:15
Location: UK

#12 Post by zygo »

I'm using puppy 2.16. The modem wizard and wvdial both find the modem I mentioned. It's on ttyS0.

Tui
Posts: 378
Joined: Wed 27 Sep 2006, 11:35
Location: Wellington New Zealand

#13 Post by Tui »

Hi Jesse,
I have downloaded the "puppyserialdetect-1.1f and
went thro' the process of what I thought was an install, every thing
looked like an install, and after a reboot I checked I don't think it
loaded, Please advise how to load and check that it loaded.

Cheers Tui

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#14 Post by BarryK »

Jesse,
I'm finally home and able to test my serial modem. No joy I'm afraid. 1.1f does not detect it, 1.0 does. It's a plain-vanilla ordinary external serial hardware modem on ttyS0.

zygo
Posts: 243
Joined: Sat 08 Apr 2006, 20:15
Location: UK

#15 Post by zygo »

My pci sound card died so I replaced it with the original device:

Code: Select all

pci bus 0x0002 cardnum 0x0a function 0x00: vendor 0x14f1 device 0x2f00
 Conexant HSF 56k HSFi Modem
This too is not detected. Nor is it detected by the modem wizard. Is it the kind of modem that is supposed to be detected?

Jesse
Posts: 466
Joined: Sun 08 May 2005, 16:07
Location: Auckland, NZ

#16 Post by Jesse »

Hi Barry,

Are there any clues about what has gone wrong, if you run it with the -d option?
Sorry I don't have a modem here to test with.

What do you think is best course of action, debug and fix 1.1f, or go back to 1.0 and patch things one at a time?

Jesse

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#17 Post by BarryK »

zygo: no, only genuine hardware modems.

Jesse: -d option returns this:

Probing serial ports...
ensure_dev_node_present on /dev/ttyS0 4 64
Found [/dev/ttyS0]
ensure_dev_node_present on /dev/ttyS1 4 65
ensure_dev_node_present on /dev/ttyS2 4 66
ensure_dev_node_present on /dev/ttyS3 4 67
ensure_dev_node_present on /dev/ttyS4 4 68

...which is interesting, at least it recognises something is there!
Does that help to narrow-down the problem?

Jesse
Posts: 466
Joined: Sun 08 May 2005, 16:07
Location: Auckland, NZ

#18 Post by Jesse »

Hi Barry,

Yep, the problem is certainly narrowed down, I just had a quick look at the code and spotted the logic flaw in it, and I looked at the original code, and scratching my head as to why that worked, the original isn't gauranteed to work, but that is determined at compile time, it needs a compiler optimization to be gauranteed for the program to work, which is what probably confused me in the first place.
I'll hopefully post an update soon.

Jesse

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#19 Post by BarryK »

....how's the big-finding going? :wink:
I want to wait until this is fixed before ploading 2.17alpha.

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#20 Post by BarryK »

Okay, I got it working.

I realised that Jesse has a problem not having a serial modem to test with, so got stuck into it myself.

It's a very bad hack though. I went back to the original version, which tests serial modems only. I then turned on the mouse detection bits, which waswhat Dougal did for v1.1, but it didn't detect my ps/2 mouse -- I then tried Dougal's v1.1, same problem.

So, I grabbed Jesse's 'mouse.c' and hacked it very badly, but it now works (don't cringe too much when you look at it, Jesse :D )

I'm only using puppyserialdetect in Puppy to detect modems and mice, not keyboards, as I'm still using some code that pakt works out sometime ago for usb keyboard detection.

I'm called it version 1.2...
Attachments
puppyserialdetect-1.2.tar.gz
(35.73 KiB) Downloaded 513 times

Post Reply