Legacy Forum: Preserving Nearly 20 Years of Community History - A Time Capsule of Discussions, Memories, and Shared Experiences.

TTL (COM3) in Ubuntu

Based on DMP's Vortex processor / SoC this board is a full computer capable of running a standard Windows and Linux installation on the backpack of your robot.
21 postsPage 1 of 21, 2
21 postsPage 1 of 21, 2

TTL (COM3) in Ubuntu

Post by haydndup » Wed Jul 20, 2011 8:26 pm

Post by haydndup
Wed Jul 20, 2011 8:26 pm

Hi all,

I currently have a RB-110 running a custom kernel (not the one supplied by Roboard). The reason for using my own kernel is because I am running Xenomai.

For the past few days, I have been trying to communicate with a Pololu Serial Server Controller via TTL on COM3.

A bit of background: I have installed Ubuntu 10.04.2 and Xenomai on the board (I have documented the process online if anyone is interested - http://www.haydnweb.co.za/tag/rb-110/). So far so good; I have LAN, Wifi, Xenomai etc. I have also tested the GPIO pins using the RoBoIO library and that works.

At first, I hadn't set up the COM3 and COM4 ports because I didn't know I needed to. I then found this post, http://robosavvy.org/forum/viewtopic.php?p=28663, and followed the instructions that Roboard tech support suggested. This went well, and the output of "setserial -g /dev/ttyS*" is identical to the output shown in the set up guide.

In terms of code, I have tried using both the RoBoIO com library and the code posted on http://robosavvy.com/forum/viewtopic.php?t=7147. Neither of the methods were able to communicate with the Pololu. From what I understand, the Pololu uses 5V TTL and the RB-110 uses 3.3V TTL, so I was using a Sparkfun Logic Level Converter to take care of that for me. At this point, I thought the Pololu might be faulty, but I tested it with an Arduino and it worked.

I then joined the TX and RX lines of COM3 and transmitted 3 bytes using the RoBoIO library, and then tried to receive three bytes. The received output was 0 0 0 (which is not what I sent). To confirm, I then connected an oscilloscope to the TX/RX line and monitored it for activity, but I was unable to see any.

I'm not sure if its of any relevance, but the RS-232 port (COM1) definitely works because I have used it to communicate with a Microstrain 3DM-GX1.

Does anyone maybe have any suggestions for me?

Thanks!
Hi all,

I currently have a RB-110 running a custom kernel (not the one supplied by Roboard). The reason for using my own kernel is because I am running Xenomai.

For the past few days, I have been trying to communicate with a Pololu Serial Server Controller via TTL on COM3.

A bit of background: I have installed Ubuntu 10.04.2 and Xenomai on the board (I have documented the process online if anyone is interested - http://www.haydnweb.co.za/tag/rb-110/). So far so good; I have LAN, Wifi, Xenomai etc. I have also tested the GPIO pins using the RoBoIO library and that works.

At first, I hadn't set up the COM3 and COM4 ports because I didn't know I needed to. I then found this post, http://robosavvy.org/forum/viewtopic.php?p=28663, and followed the instructions that Roboard tech support suggested. This went well, and the output of "setserial -g /dev/ttyS*" is identical to the output shown in the set up guide.

In terms of code, I have tried using both the RoBoIO com library and the code posted on http://robosavvy.com/forum/viewtopic.php?t=7147. Neither of the methods were able to communicate with the Pololu. From what I understand, the Pololu uses 5V TTL and the RB-110 uses 3.3V TTL, so I was using a Sparkfun Logic Level Converter to take care of that for me. At this point, I thought the Pololu might be faulty, but I tested it with an Arduino and it worked.

I then joined the TX and RX lines of COM3 and transmitted 3 bytes using the RoBoIO library, and then tried to receive three bytes. The received output was 0 0 0 (which is not what I sent). To confirm, I then connected an oscilloscope to the TX/RX line and monitored it for activity, but I was unable to see any.

I'm not sure if its of any relevance, but the RS-232 port (COM1) definitely works because I have used it to communicate with a Microstrain 3DM-GX1.

Does anyone maybe have any suggestions for me?

Thanks!
haydndup
Newbie
Newbie
Posts: 5
Joined: Wed Jul 20, 2011 8:06 pm

Re: TTL (COM3) in Ubuntu

Post by roboard » Thu Jul 21, 2011 1:56 pm

Post by roboard
Thu Jul 21, 2011 1:56 pm

Hi,

if you are using RoBoIO COM lib to access COM3 with "parity" checking, then we suggest that you may update your RoBoIO to ver 1.81 (we have fixed a bug of COM lib for linux, download it from http://www.roboard.com/download_ml.htm).

Alternatively, you can employ other linux serial library to access COM3. If it still doesn't work, then you may check the BIOS to confirm that COM3 is really enabled.

:)
Hi,

if you are using RoBoIO COM lib to access COM3 with "parity" checking, then we suggest that you may update your RoBoIO to ver 1.81 (we have fixed a bug of COM lib for linux, download it from http://www.roboard.com/download_ml.htm).

Alternatively, you can employ other linux serial library to access COM3. If it still doesn't work, then you may check the BIOS to confirm that COM3 is really enabled.

:)
roboard
Savvy Roboteer
Savvy Roboteer
Posts: 302
Joined: Fri Jul 03, 2009 4:44 am

Post by haydndup » Thu Jul 21, 2011 8:24 pm

Post by haydndup
Thu Jul 21, 2011 8:24 pm

Hi there, thanks for the reply.

I was not using parity checking, but I updated RoBoIO anyway.

Maybe I missed a setting? In the BIOS I have the following configured:
COM3 -> IRQ10 -> 3E8
COM4 -> IRQ11 -> 2E8

IRQ10 and IRQ11 are set as "Available". I have tried using "Reserved" too. Also, IRQ3 and IRQ4 are reserved. What is the correct setting for this?

Are there any other settings that I need to check to use COM3 and COM4?

The output of "setserial -g /dev/ttyS*" is:
Code: Select all
/dev/ttyS0, UART: 16550A, Port: 0x03f8, IRQ: 4
/dev/ttyS1, UART: 16550A, Port: 0x02f8, IRQ: 3
/dev/ttyS2, UART: 16550A, Port: 0x03e8, IRQ: 10
/dev/ttyS3, UART: 16550A, Port: 0x02e8, IRQ: 11


That is identical to the output shown in the set up guide.

Also, I'm not sure if it's normal, but I have to rerun setserial every time the Roboard boots. Does setserial not save the configuration?

In terms of code, I have tried using both RoBoIO and Linux native COM.

The RoBoIO code I am using is this:
Code: Select all
#include <stdio>
#include <unistd>
#include <string>
#include <stdlib>
#include <roboard>

int main ()
{
   roboio_SetRBVer(RB_110);
   if (io_Init() == -1)
   {
           printf("ERR: fail to initialize I/O lib (%s)!\nEnsure that you have root access.\n", roboio_GetErrMsg());
      return 1;
   }

   if (com_Init(COM_PORT3, COM_FDUPLEX) == false)
   {
           printf("ERR: fail to initialize I/O lib (%s)!\n\n", roboio_GetErrMsg());
      return 1;
   }
   com_SetFormat(COM_PORT3, COM_BYTESIZE8, COM_STOPBIT1, COM_NOPARITY);
   com_SetBaud(COM_PORT3, COMBAUD_50BPS);

while(1){

   if (com_Write(COM_PORT3, 0x07) == false)
   {
      printf ("Sending failed\n");
   }else {
      printf ("Sent: %i\n", 0x07);
   }
   printf("Received: %i\n", com_Read(COM_PORT3));

   }
   com_Close(COM_PORT3);
   io_close();
   return 0;
}


Instead of printing 7 back, it prints 65535 each time.

Then, I also tried to use a modification of acentw's code:
Code: Select all
#include <stdio>
#include <unistd>
#include <termios>
#include <fcntl>

int main(void) {
    unsigned char data[3] = {0xff, 0x00, 0xFE};
    unsigned char rec[3] = {0};
    int i;
   
    int fp = open("/dev/ttyS2", O_RDWR | O_NOCTTY);
printf("open\n");
    if(fp < 0) return 1;

    termios term;
    term.c_cflag |= CLOCAL | CREAD;
    term.c_cflag &= ~(CSIZE);
    term.c_cflag |= CS8;            // 8 bits
    term.c_cflag &= ~(PARENB); // no parity
    term.c_cflag &= ~(CSTOPB); // 1 stopbit
   
    cfsetospeed (&term, B9600); // output baudrate = 115200
    cfsetispeed (&term, B9600); // input baudrate = 115200
   
    term.c_iflag = IGNPAR; // No detect parity for input data.
    term.c_oflag = 0;
    term.c_lflag = 0;
    term.c_cc[VTIME] = 10; // timeout = 1s
    term.c_cc[VMIN] = 0;
    tcflush(fp, TCIFLUSH);
   
    tcsetattr(fp, TCSANOW, &term);

    while(true) {
    printf("%i \n", write(fp, data, 3));
    read(fp, rec, 3);

    for(i=0; i<3; i++) printf("%X ", rec[i]);
    printf("\n");
    }

   
    close(fp);
    return 0;
}

With this code, the output was always "0 0 0".

For both bits of code I joined COM3's TX and RX lines together, so I should be receiving what I was sending out. I have also tried using COM4 instead of COM3, and that didn't work either.

The only difference I can think of is that I am not using the kernel supplied by Roboard. What kernel options must be enabled for the RB's COM3 and COM4 to work? Could the kernel be causing this? Is there any definite way to test that the COM3 and COM4 ports are even working?

Thanks again.
Hi there, thanks for the reply.

I was not using parity checking, but I updated RoBoIO anyway.

Maybe I missed a setting? In the BIOS I have the following configured:
COM3 -> IRQ10 -> 3E8
COM4 -> IRQ11 -> 2E8

IRQ10 and IRQ11 are set as "Available". I have tried using "Reserved" too. Also, IRQ3 and IRQ4 are reserved. What is the correct setting for this?

Are there any other settings that I need to check to use COM3 and COM4?

The output of "setserial -g /dev/ttyS*" is:
Code: Select all
/dev/ttyS0, UART: 16550A, Port: 0x03f8, IRQ: 4
/dev/ttyS1, UART: 16550A, Port: 0x02f8, IRQ: 3
/dev/ttyS2, UART: 16550A, Port: 0x03e8, IRQ: 10
/dev/ttyS3, UART: 16550A, Port: 0x02e8, IRQ: 11


That is identical to the output shown in the set up guide.

Also, I'm not sure if it's normal, but I have to rerun setserial every time the Roboard boots. Does setserial not save the configuration?

In terms of code, I have tried using both RoBoIO and Linux native COM.

The RoBoIO code I am using is this:
Code: Select all
#include <stdio>
#include <unistd>
#include <string>
#include <stdlib>
#include <roboard>

int main ()
{
   roboio_SetRBVer(RB_110);
   if (io_Init() == -1)
   {
           printf("ERR: fail to initialize I/O lib (%s)!\nEnsure that you have root access.\n", roboio_GetErrMsg());
      return 1;
   }

   if (com_Init(COM_PORT3, COM_FDUPLEX) == false)
   {
           printf("ERR: fail to initialize I/O lib (%s)!\n\n", roboio_GetErrMsg());
      return 1;
   }
   com_SetFormat(COM_PORT3, COM_BYTESIZE8, COM_STOPBIT1, COM_NOPARITY);
   com_SetBaud(COM_PORT3, COMBAUD_50BPS);

while(1){

   if (com_Write(COM_PORT3, 0x07) == false)
   {
      printf ("Sending failed\n");
   }else {
      printf ("Sent: %i\n", 0x07);
   }
   printf("Received: %i\n", com_Read(COM_PORT3));

   }
   com_Close(COM_PORT3);
   io_close();
   return 0;
}


Instead of printing 7 back, it prints 65535 each time.

Then, I also tried to use a modification of acentw's code:
Code: Select all
#include <stdio>
#include <unistd>
#include <termios>
#include <fcntl>

int main(void) {
    unsigned char data[3] = {0xff, 0x00, 0xFE};
    unsigned char rec[3] = {0};
    int i;
   
    int fp = open("/dev/ttyS2", O_RDWR | O_NOCTTY);
printf("open\n");
    if(fp < 0) return 1;

    termios term;
    term.c_cflag |= CLOCAL | CREAD;
    term.c_cflag &= ~(CSIZE);
    term.c_cflag |= CS8;            // 8 bits
    term.c_cflag &= ~(PARENB); // no parity
    term.c_cflag &= ~(CSTOPB); // 1 stopbit
   
    cfsetospeed (&term, B9600); // output baudrate = 115200
    cfsetispeed (&term, B9600); // input baudrate = 115200
   
    term.c_iflag = IGNPAR; // No detect parity for input data.
    term.c_oflag = 0;
    term.c_lflag = 0;
    term.c_cc[VTIME] = 10; // timeout = 1s
    term.c_cc[VMIN] = 0;
    tcflush(fp, TCIFLUSH);
   
    tcsetattr(fp, TCSANOW, &term);

    while(true) {
    printf("%i \n", write(fp, data, 3));
    read(fp, rec, 3);

    for(i=0; i<3; i++) printf("%X ", rec[i]);
    printf("\n");
    }

   
    close(fp);
    return 0;
}

With this code, the output was always "0 0 0".

For both bits of code I joined COM3's TX and RX lines together, so I should be receiving what I was sending out. I have also tried using COM4 instead of COM3, and that didn't work either.

The only difference I can think of is that I am not using the kernel supplied by Roboard. What kernel options must be enabled for the RB's COM3 and COM4 to work? Could the kernel be causing this? Is there any definite way to test that the COM3 and COM4 ports are even working?

Thanks again.
haydndup
Newbie
Newbie
Posts: 5
Joined: Wed Jul 20, 2011 8:06 pm

Post by ShiU_Damien » Fri Jul 22, 2011 6:47 am

Post by ShiU_Damien
Fri Jul 22, 2011 6:47 am

Hi haydndup,

I currently control the Dynamixel AX-12 servos in Ubuntu 9.04 on RB-110. I used the RoBoIO Ver 1.81 to control servos via TTL on COM3 & COM4. It worked normal, but my kernel is supplied by Roboard.
I also tried the codes that you posted, and it worked no matters. Could you use the API of RoBoIO "roboio_GetErrMsg()" to get the error message
when "com_Read(COM_PORT3)" failed?
Hi haydndup,

I currently control the Dynamixel AX-12 servos in Ubuntu 9.04 on RB-110. I used the RoBoIO Ver 1.81 to control servos via TTL on COM3 & COM4. It worked normal, but my kernel is supplied by Roboard.
I also tried the codes that you posted, and it worked no matters. Could you use the API of RoBoIO "roboio_GetErrMsg()" to get the error message
when "com_Read(COM_PORT3)" failed?
ShiU_Damien
Newbie
Newbie
Posts: 2
Joined: Fri Jul 22, 2011 5:04 am

Post by haydndup » Fri Jul 22, 2011 8:41 am

Post by haydndup
Fri Jul 22, 2011 8:41 am

Hi ShiU_Damien,

Thanks for testing my code. I'm not by the Roboard at the moment, so I'll only be able to post the error message a bit later.

I think it must be the kernel then - it's the only thing that I have different. What kernel version are you using? Could you post its config file that is in /boot?

Thanks again.
Hi ShiU_Damien,

Thanks for testing my code. I'm not by the Roboard at the moment, so I'll only be able to post the error message a bit later.

I think it must be the kernel then - it's the only thing that I have different. What kernel version are you using? Could you post its config file that is in /boot?

Thanks again.
haydndup
Newbie
Newbie
Posts: 5
Joined: Wed Jul 20, 2011 8:06 pm

Post by ShiU_Damien » Fri Jul 22, 2011 1:13 pm

Post by ShiU_Damien
Fri Jul 22, 2011 1:13 pm

Hi,

My kernel version is "2.6.34.9-vortex86-sg", and I didn't do any modification with Linux kernel.

There is the config file that is in /boot:
http://robosavvy.com/Builders/ShiU_Damien/config_file.rar

Wish that can help you.
Hi,

My kernel version is "2.6.34.9-vortex86-sg", and I didn't do any modification with Linux kernel.

There is the config file that is in /boot:
http://robosavvy.com/Builders/ShiU_Damien/config_file.rar

Wish that can help you.
ShiU_Damien
Newbie
Newbie
Posts: 2
Joined: Fri Jul 22, 2011 5:04 am

Post by roboard » Mon Jul 25, 2011 7:59 am

Post by roboard
Mon Jul 25, 2011 7:59 am

haydndup wrote:...
Could the kernel be causing this? Is there any definite way to test that the COM3 and COM4 ports are even working?
...


Hi,

the kernels of most Linux distributions open only two COMs, and you need to manually modify the kernel configuration to open COM3 and COM4 in order to get them work.

Alternatively, RoBoard's linux kernel has been configured to open COM3 and COM4 by default. So if you employ RoBoard's linux kernel, the COM3 and COM4 can work directly.

:)
haydndup wrote:...
Could the kernel be causing this? Is there any definite way to test that the COM3 and COM4 ports are even working?
...


Hi,

the kernels of most Linux distributions open only two COMs, and you need to manually modify the kernel configuration to open COM3 and COM4 in order to get them work.

Alternatively, RoBoard's linux kernel has been configured to open COM3 and COM4 by default. So if you employ RoBoard's linux kernel, the COM3 and COM4 can work directly.

:)
roboard
Savvy Roboteer
Savvy Roboteer
Posts: 302
Joined: Fri Jul 03, 2009 4:44 am

Post by haydndup » Mon Jul 25, 2011 8:53 pm

Post by haydndup
Mon Jul 25, 2011 8:53 pm

@ShiU_Damien,

Thanks for the config, I'm busy comparing it to my config and looking for differences. Unfortunately, I'm not sure what exactly I'm looking for.

With regards to the error message for com_Read(), all it says is "time-out to read bytes"

@roboard,

Thanks for the reply. What in the kernel config do I need to change? I've been comparing mine, but haven't found anything obvious that I need to change. If you can point me to the exact things I need to modify, I would greatly appreciate it.

I would love to use the roboard kernel where I know everything will work, but I have to use real-time Linux for my project, which means I can't use the kernel you provide.

On a separate note, as I mentioned in my first post, I am using Xenomai to provide hard real-time support. Now, Xenomai has a real-time driver for the 16550A which is what the RB-110 uses for COM3 and COM4. If I enable the real-time driver, would I still be able to use RoBoIO, or would I need to use standard Linux C serial? More info on the driver is here: http://www.xenomai.org/index.php/16550A

Thanks again!
@ShiU_Damien,

Thanks for the config, I'm busy comparing it to my config and looking for differences. Unfortunately, I'm not sure what exactly I'm looking for.

With regards to the error message for com_Read(), all it says is "time-out to read bytes"

@roboard,

Thanks for the reply. What in the kernel config do I need to change? I've been comparing mine, but haven't found anything obvious that I need to change. If you can point me to the exact things I need to modify, I would greatly appreciate it.

I would love to use the roboard kernel where I know everything will work, but I have to use real-time Linux for my project, which means I can't use the kernel you provide.

On a separate note, as I mentioned in my first post, I am using Xenomai to provide hard real-time support. Now, Xenomai has a real-time driver for the 16550A which is what the RB-110 uses for COM3 and COM4. If I enable the real-time driver, would I still be able to use RoBoIO, or would I need to use standard Linux C serial? More info on the driver is here: http://www.xenomai.org/index.php/16550A

Thanks again!
haydndup
Newbie
Newbie
Posts: 5
Joined: Wed Jul 20, 2011 8:06 pm

Post by roboard » Tue Jul 26, 2011 6:38 am

Post by roboard
Tue Jul 26, 2011 6:38 am

Hi haydndup,

1.
To enable COM3 & COM4 for your kernel, please try to modify the boot loader configuration file as follows (assuming you use GRUB):

title ...
root ...
kernel /boot/vmlinuz-2.6.34 root=... 8250.nr_uarts=4
initrd /boot/initrd.img-2.6.34

2.
RoBoIO 1.8/1.81 assumes that the serial device file names are "ttyS0" ~ "ttyS3". If you employ the real-time serial driver of Xenomai, the device file names for COM ports may change, and you may need to modify the com.cpp of RoBoIO 1.8/1.81 to adopt the new device names:

Find in com.cpp the following line:
Code: Select all
static char* COM_portname[4] = {"/dev/ttyS0", "/dev/ttyS1", "/dev/ttyS2", "/dev/ttyS3"};

Modify the strings to the device names of Xenomai's real-time driver and then rebuild the RoBoIO.

:)
Hi haydndup,

1.
To enable COM3 & COM4 for your kernel, please try to modify the boot loader configuration file as follows (assuming you use GRUB):

title ...
root ...
kernel /boot/vmlinuz-2.6.34 root=... 8250.nr_uarts=4
initrd /boot/initrd.img-2.6.34

2.
RoBoIO 1.8/1.81 assumes that the serial device file names are "ttyS0" ~ "ttyS3". If you employ the real-time serial driver of Xenomai, the device file names for COM ports may change, and you may need to modify the com.cpp of RoBoIO 1.8/1.81 to adopt the new device names:

Find in com.cpp the following line:
Code: Select all
static char* COM_portname[4] = {"/dev/ttyS0", "/dev/ttyS1", "/dev/ttyS2", "/dev/ttyS3"};

Modify the strings to the device names of Xenomai's real-time driver and then rebuild the RoBoIO.

:)
roboard
Savvy Roboteer
Savvy Roboteer
Posts: 302
Joined: Fri Jul 03, 2009 4:44 am

Post by haydndup » Tue Jul 26, 2011 9:24 am

Post by haydndup
Tue Jul 26, 2011 9:24 am

Hi roboard,

Thanks for the help. I did initially set the 8250.nr_uarts when I followed the COM3 and COM4 tutorial on your site.

The weird thing is that I can see the ports, and I can open a connection to them, but I can't send/receive unless I am using the RB kernel. When I switch over to the Xeno kernel, I can't send/receive (I have checked this with an oscilloscope).

This makes me think it's something in the kernel .config, but I'm not sure what. I see that I have CONFIG_USB_SERIAL set to no. I know that this will affect COM5 and COm6 because they use the FTDI chip. Is it possible that this is affecting the 16550A UART chip too?
Hi roboard,

Thanks for the help. I did initially set the 8250.nr_uarts when I followed the COM3 and COM4 tutorial on your site.

The weird thing is that I can see the ports, and I can open a connection to them, but I can't send/receive unless I am using the RB kernel. When I switch over to the Xeno kernel, I can't send/receive (I have checked this with an oscilloscope).

This makes me think it's something in the kernel .config, but I'm not sure what. I see that I have CONFIG_USB_SERIAL set to no. I know that this will affect COM5 and COm6 because they use the FTDI chip. Is it possible that this is affecting the 16550A UART chip too?
haydndup
Newbie
Newbie
Posts: 5
Joined: Wed Jul 20, 2011 8:06 pm

Post by roboard » Tue Jul 26, 2011 11:01 am

Post by roboard
Tue Jul 26, 2011 11:01 am

haydndup wrote:...I see that I have CONFIG_USB_SERIAL set to no. I know that this will affect COM5 and COm6 because they use the FTDI chip. Is it possible that this is affecting the 16550A UART chip too?


Hi haydndup,

CONFIG_USB_SERIAL shouldn't affect the COM3 and COM4. Your issue may be caused by inadequate configuration or option setting of Xenomai kernel; to confirm this, you may switch back to the normal Ubuntu kernel to see whether COM3/4 work on the normal kernel.

:)
haydndup wrote:...I see that I have CONFIG_USB_SERIAL set to no. I know that this will affect COM5 and COm6 because they use the FTDI chip. Is it possible that this is affecting the 16550A UART chip too?


Hi haydndup,

CONFIG_USB_SERIAL shouldn't affect the COM3 and COM4. Your issue may be caused by inadequate configuration or option setting of Xenomai kernel; to confirm this, you may switch back to the normal Ubuntu kernel to see whether COM3/4 work on the normal kernel.

:)
roboard
Savvy Roboteer
Savvy Roboteer
Posts: 302
Joined: Fri Jul 03, 2009 4:44 am

Post by gdo » Tue Jul 26, 2011 1:15 pm

Post by gdo
Tue Jul 26, 2011 1:15 pm

As seen with haydndup, needed actions to use COM3 are :

- Set IRQ 10 as reserved in BIOS
- Launch the following comand : sudo setserial /dev/ttyS2 port 0x03e8 irq 10 autoconfig
- Be sure you have good permissions to access /dev/ttyS2

Tested on RB-100 with cutecom by plugging TX to RX. Communications parameters are 115200 8N1 and no flow controls.

@Haydndup, you confirm it is working for RB-110 ?

@roboard, when you say :
Alternatively, RoBoard's linux kernel has been configured to open COM3 and COM4 by default. So if you employ RoBoard's linux kernel, the COM3 and COM4 can work directly.


Does it mean you modified something in or near <linux_kernel_source_dir>/arch/alpha/include/asm/serial.h file ?

gdo
As seen with haydndup, needed actions to use COM3 are :

- Set IRQ 10 as reserved in BIOS
- Launch the following comand : sudo setserial /dev/ttyS2 port 0x03e8 irq 10 autoconfig
- Be sure you have good permissions to access /dev/ttyS2

Tested on RB-100 with cutecom by plugging TX to RX. Communications parameters are 115200 8N1 and no flow controls.

@Haydndup, you confirm it is working for RB-110 ?

@roboard, when you say :
Alternatively, RoBoard's linux kernel has been configured to open COM3 and COM4 by default. So if you employ RoBoard's linux kernel, the COM3 and COM4 can work directly.


Does it mean you modified something in or near <linux_kernel_source_dir>/arch/alpha/include/asm/serial.h file ?

gdo
gdo
Savvy Roboteer
Savvy Roboteer
Posts: 34
Joined: Fri Dec 17, 2010 5:47 pm

Post by roboard » Tue Jul 26, 2011 3:23 pm

Post by roboard
Tue Jul 26, 2011 3:23 pm

gdo wrote:...Does it mean you modified something in or near <linux_kernel_source_dir>/arch/alpha/include/asm/serial.h file ?
...


Hi gdo,

we just configure and build the kernel to support COM3/4. "serial.h" is not modified.

:)
gdo wrote:...Does it mean you modified something in or near <linux_kernel_source_dir>/arch/alpha/include/asm/serial.h file ?
...


Hi gdo,

we just configure and build the kernel to support COM3/4. "serial.h" is not modified.

:)
roboard
Savvy Roboteer
Savvy Roboteer
Posts: 302
Joined: Fri Jul 03, 2009 4:44 am

Post by gdo » Tue Jul 26, 2011 4:05 pm

Post by gdo
Tue Jul 26, 2011 4:05 pm

But kernel from kernel.org does it by default ? :?
The only thing is that the COM3/COM4 are not associated to an IRQ.

I'm sure we say the same thing in two different way. :lol:
But kernel from kernel.org does it by default ? :?
The only thing is that the COM3/COM4 are not associated to an IRQ.

I'm sure we say the same thing in two different way. :lol:
gdo
Savvy Roboteer
Savvy Roboteer
Posts: 34
Joined: Fri Dec 17, 2010 5:47 pm

Post by roboard » Tue Jul 26, 2011 8:53 pm

Post by roboard
Tue Jul 26, 2011 8:53 pm

Hi gdo,

COM1~COM4 have existed in serial.h and no need to update the serial.h unless you want to make the base address & IRQ of COM3/4 be hard coded in the kernel.

The details for our kernel configuring and building should be answered by our Linux engineer, who is on vacation this week. We will ask him to mention the details next week.

:)
Hi gdo,

COM1~COM4 have existed in serial.h and no need to update the serial.h unless you want to make the base address & IRQ of COM3/4 be hard coded in the kernel.

The details for our kernel configuring and building should be answered by our Linux engineer, who is on vacation this week. We will ask him to mention the details next week.

:)
roboard
Savvy Roboteer
Savvy Roboteer
Posts: 302
Joined: Fri Jul 03, 2009 4:44 am

Next
21 postsPage 1 of 21, 2
21 postsPage 1 of 21, 2