08-10-2007
how i prepare a c++ code(c code) for implementing my own protocol format
helo my protocol format is given below
{ destno,mode,no.of packet,pktsize,,pktno,textsize,CRC}
description:- { is starting flag
destno - 4bytes
mode - 1 byte
no.of pkt - 4byes
pktsize - 6 bytes
pktno 3 bytes
text size 6 bytes
CRC is 2 bytes
i want to write c++ code(or c code) to prepare this packet and after this
i want to transfer this packet over serial port.
after that how i write a code to receive this packet from serial port and how i extract this packet after receiving the packet.
Regards,
Amit
9 More Discussions You Might Find Interesting
1. HP-UX
Hi,
We are facing issue with files transfered using SFTP in Hp-UX.
The transfered files are in Unix Format. That is, file format as UNIX (LF) instead of a PC format (CR & LF).
How can we achieve file transfers as PC format using SFTP?
Your help and input will be highly appreciated.
... (2 Replies)
Discussion started by: brap45
2 Replies
2. Shell Programming and Scripting
Hi
I have a file which is having line like below
Personal Unit=AU003 (Industrial Products Division),Plant=B00089,Departmant=D110
When ever i fine line starting sith Personal Unit and contains Plant Department I need to pick this line and format it like
Personal Unit=AU003 ... (7 Replies)
Discussion started by: krishna.fuji
7 Replies
3. Shell Programming and Scripting
hello all, In refrence to below thread...i am trying to format code using ruby beautifer.... as its mentions....below is the link
https://www.unix.com/shell-programming-scripting/101398-code-formatter-shell-script.html
It says use Bash Script... (1 Reply)
Discussion started by: abdul.irfan2
1 Replies
4. Programming
Hi friends,
Please see the below code carefully.
=======================================================
# Get batch date and Ord range
open OR,$ARGV;
while (<OR>) { # find the batch date
next if length $_ < 3; # BLANK LINE
# last if $. > 120; # sample should be good enough... (2 Replies)
Discussion started by: pspriyanka
2 Replies
5. Shell Programming and Scripting
Hi,
I am having one log files. contains som data according to date. And it is going to append .Eg:abc.log contains below data
2011-10-19 abjhgj
2011-10-19 gjhgjgj
2011-10-20 hhhjh
2011-10-20 hhhhjj
2011-10-21 gg
.
.
.
2011-11-24 yyy
from log files i want catch only... (2 Replies)
Discussion started by: aish11
2 Replies
6. Shell Programming and Scripting
Hi All ,
Below is the perl code. from below code want to confirm one thing that
wahtever the sequence of data we are passing through json format which contains 3 tuples of different sequences
Eg:
ParentID,SystemID,SendingTime,Time,ClientLocation,ClientID,
... (1 Reply)
Discussion started by: aish11
1 Replies
7. Shell Programming and Scripting
Hi
I want to grep a column 6 & column 7 from a CSV Format file & then i have to find the difference between these columns as these both columns contains date & time in 7/7/2012 9:20 this format . So kindly help me out ASAP.
But please kindly dis xls has to be converted in csv format as may... (5 Replies)
Discussion started by: Prateek@123
5 Replies
8. UNIX for Beginners Questions & Answers
Hi,
I have some questions about sqlplus running from bash. I am still new and learning. I have the code shown below:
echo "exit" | sqlplus... (10 Replies)
Discussion started by: mohca2020
10 Replies
9. What is on Your Mind?
By special request, and long overdue, I have updated our "code tags" video and so now we have:
How to Use Code Tags and Format Posts @UNIX.com in 4K
https://youtu.be/4BuPvWJV__k (3 Replies)
Discussion started by: Neo
3 Replies
LEARN ABOUT CENTOS
isodump
isodump(5) Linux IEEE 1394 isodump(5)
NAME
isodump - format of IEEE 1394 isochronous packets dump file
DESCRIPTION
The isodump format stores a series of IEEE 1394 isochronous stream packets (possibly from multiple channels), including their headers. Its
main use is as the output format of dumpiso(1) and the input format of sendiso(1).
The 32 byte header starts at offset 0 with the string "1394 isodump v1" followed by a zero byte. The next 8 bytes form a 64 bit big endian
integer, which represents a bit mask of the channels that were dumped. A set bit at position (1 << x) signifies that channel x was being
listened on. The following 8 bytes are set to zero.
The iso packets follow the header and are appended to the data stream in the order they were received. The packets consist of the header
quadlet as originally received and the data quadlets following directly. The CRC quadlets after header and data do not appear and every-
thing is in big endian, as seen on the bus.
There is no further framing of the packets in the format, packet boundaries can be found by looking at the data size field in the header
quadlet of each packet. The data size field appears in the most significant 16 bits of the header quadlet, contain the size in bytes (the
actual packet is padded to a multiple of four bytes) and do not include the header packet.
COMPATIBILITY
This format was introduced with the iso send and dump tools distributed with libraw1394. No one else uses it so far.
SEE ALSO
sendiso(1), dumpiso(1)
AUTHOR
Andreas Bombe <aeb@debian.org>
libraw1394 2.1.0 isodump v1 isodump(5)