LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 10-05-2006, 08:10 PM   #1
kimbosung
LQ Newbie
 
Registered: Oct 2006
Posts: 1

Rep: Reputation: 0
Serial Communication On Linux......


Hi, Everyone.
It's my Second time to writing to foreigner.
I can't speake English very well.

I'm studing RFID communication use v720-H01 RFID Module made by 'OMRON'

I'm trying to make program C++(QT, in Linux).

for that, I have to use Serial communication.
I have already seen Serial Communication HOWTO.

there was some information what I need.
BAURATE, COM1="/dev/ttyS1", CRTSCTS,,,,
and, I check <asm/termbits.h> header file, so I could see many parameters.

But I have question yet.
Way that "BCC Setting [Enable/Unable]"???
I tried to find explanation of Parameters in <termbits.h> header file, But It's not easy.
ex) CS8 = Databit_8, ParityBit_No, StopBit_1

please teach me How can I setting "BCC" on the coding.
or How can I find explanation of Parameters in <termbits.h> header file.

I append my serial communication setting, and coding.
============================================================
BARURATE=38400, comport=com1, 8bit, no parity, 1 stopbit.

#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <termios.h>
#include <stdio.h>

#define BAUDRATE B38400
#define MODEMDEVICE "/dev/ttyS1"
.....
newtio.c_cflag = BAUDRATE | CRTSCTS | CS8 | CLOCAL | CREAD;
.....
============================================================
 
Old 10-05-2006, 09:04 PM   #2
randyding
Member
 
Registered: May 2004
Posts: 552

Rep: Reputation: 31
I have a simple coding example you can D/L here.

If you can't access this site post back here and I'll move it to another location. This web server is currently black-listing most non-US ip ranges.

Last edited by randyding; 03-19-2009 at 10:44 PM. Reason: web site is now gone, removed url
 
Old 04-08-2007, 08:44 AM   #3
sea waves
LQ Newbie
 
Registered: Apr 2007
Posts: 9

Rep: Reputation: 0
hello,,

I need the website provided by randyding

but i can't access it..

can u plz provide another link

Thank u
 
Old 04-08-2007, 08:26 PM   #4
ta0kira
Senior Member
 
Registered: Sep 2004
Distribution: FreeBSD 9.1, Kubuntu 12.10
Posts: 3,078

Rep: Reputation: Disabled
Since you have Qt, I assume you also have KDE? If so, go into Konqueror and type info:libc into the address bar. That is by far the most useful reference for C on Linux I've encountered.
ta0kira
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
Serial Communication in Debian Linux ashlesha Linux - Newbie 9 06-26-2006 07:59 PM
Serial port communication in 'C' on Linux kirti Linux - Hardware 1 06-25-2004 01:58 PM
communication with serial port vidyaraj Linux - Hardware 0 03-09-2004 08:32 PM
serial port communication vidyaraj Linux - Software 6 03-02-2004 06:46 PM
communication via serial port perdesiz Linux - Software 0 11-13-2003 06:23 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 07:29 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration