Usb Serial Device


bradk3

Still Fresh
Joined
Nov 13, 2010
Messages
5
I know this has been discussed before here, but I'm inexperienced enough with Linux that I couldn't follow the solution.

I want to be able to attach and use a USB/RS-232 serial converter cable. This way, I hope to be able to control another device I'm building with the Caanoo through a serial interface.

So far, however, the Caanoo doesn't appear to be recognizing my converter cable.

I think I understand that I need to build a "usbserial" kernel module... but that's a bit beyond me at the moment. I don't even know where to start understanding what that entails.

I'm not expecting step-by-step instructions, but some (gentle) nudging in the right direction would be appreciated.

Thanks!
 
Last edited by a moderator:
you need to compile the "g_serial.ko" kernel module, yes.

there's another thread about kernel module cross compilation here: http://www.gp32x.de/board/index.php?/topic/58048-kernel-module-cross-compilation/

the firmware source code can be found here: http://dl.openhandhelds.org/cgi-bin/caanoo.cgi?0,0,0,0,42,651

if you have the g_serial.ko - you can just use the scripts/utilities from http://dl.openhandhelds.org/cgi-bin/wiz.cgi?0,0,0,0,14,255 (with your module of course)

hope that helps :)
 
Last edited by a moderator:
The g_serial.ko driver is for enabling the serial port on the EXT port, but if I understood correctly, brad3k wants to plug a serial port adapter into the Caanoo's USB port and then access it from the Caanoo side.

In this case, the usbserial module would indeed be required on the Caanoo (much like it is required on PC when you go the other way around).

Here are the steps to compile it (from memory, I did something like this to compile g_ether.ko for the Wiz):

  1. Get the kernel source for your firmware
  2. You need the GPH SDK with the toolchain on your $PATH
  3. export CROSS_COMPILE=arm-gph-linux-gnueabi-
  4. In the kernel source directory, run "make menuconfig"
  5. Search for the usbserial driver option and set it to "M" (module)
  6. Save the config and run "make modules"
  7. Find usbserial.ko, copy it to the Caanoo and try to load it
 
I actually just tried this myself: In "Device Drivers" -> "USB Support" -> "USB Serial Converter support", I set "USB Serial Converter support" to <M> and enabled "USB Generic Serial Driver".

Here is the resulting module.
 
Last edited:
crow_riot said:
you need to compile the "g_serial.ko" kernel module, yes.

there's another thread about kernel module cross compilation here: http://www.gp32x.de/board/index.php?/topic/58048-kernel-module-cross-compilation/

the firmware source code can be found here: http://dl.openhandhelds.org/cgi-bin/caanoo.cgi?0,0,0,0,42,651

if you have the g_serial.ko - you can just use the scripts/utilities from http://dl.openhandhelds.org/cgi-bin/wiz.cgi?0,0,0,0,14,255 (with your module of course)

hope that helps :)

Okay, wow, that's a lot of good information right there. Thank you so much for taking the time to point those out to me. I've got some good reading to do.

Very much appreciated!
 
Last edited by a moderator:
hmn said:
The g_serial.ko driver is for enabling the serial port on the EXT port, but if I understood correctly, brad3k wants to plug a serial port adapter into the Caanoo's USB port and then access it from the Caanoo side.

In this case, the usbserial module would indeed be required on the Caanoo (much like it is required on PC when you go the other way around).

Here are the steps to compile it (from memory, I did something like this to compile g_ether.ko for the Wiz):

  1. Get the kernel source for your firmware
  2. You need the GPH SDK with the toolchain on your $PATH
  3. export CROSS_COMPILE=arm-gph-linux-gnueabi-
  4. In the kernel source directory, run "make menuconfig"
  5. Search for the usbserial driver option and set it to "M" (module)
  6. Save the config and run "make modules"
  7. Find usbserial.ko, copy it to the Caanoo and try to load it

I appreciate the step-by-step instructions, and I'm sure someone else who reads this will as well.

Many thanks!
 
Last edited by a moderator:
hmn said:
I actually just tried this myself: In "Device Drivers" -> "USB Support" -> "USB Serial Converter support", I set "USB Serial Converter support" to <M> and enabled "USB Generic Serial Driver".

Here is the resulting module.

Thank you for that! You've saved me a whole lot of work. I may still try to build it myself, just for the experience, but I'll try to use what you built right now.

Thanks again!
 
Last edited by a moderator:
Back
Top