473,398 Members | 2,120 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

format in struct .pack

hi
i know about format argument in pack and unpack like b h i etc but in some cases i am getting < or = symbols along with them what does they signifies
for example struct.pack( "<cI", 'n', var1 )
Mar 23 '07 #1
1 7981
ghostdog74
511 Expert 256MB
hi
i know about format argument in pack and unpack like b h i etc but in some cases i am getting < or = symbols along with them what does they signifies
for example struct.pack( "<cI", 'n', var1 )
My advice : always read the docs. See here . The '<' and '=' are stated in that doc. '<' and '>' has to do with byte order. (little and big endian)
Mar 23 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Raseliarison nirinA | last post by:
hi all, i found an unanswered question at http://www.faqts.com/knowledge_base/index.phtml/fid/538 with possible response below. i've tried to send it at faqt.python but can't figure out how to...
2
by: Amit Gaur | last post by:
Hi newbie to python here, I have a binary file and i need to change the endian format..little to big as well as vice versa..could anyone help me out. thanks ---------------------------------...
2
by: Joshua Forgione | last post by:
Hello. I am reverse engineering some Python Code. I am using the book "The Quick Python Book" as an aide. The following line exists in the code: msg = struct.pack('BBBB',word0, word1, word2,...
0
by: Josiah Carlson | last post by:
Good day everyone, I have produced a patch against the latest CVS to add support for two new formatting characters in the struct module. It is currently an RFE, which I include a link to at the...
6
by: coriolis_wong | last post by:
Hi, I need to transfer csv format file to DBase III format file. How do i do it in Python language? Any help is appreciated. Thanks.
2
by: rong.xian | last post by:
Before I was bitten by the difference below, I think these two ways are the same. However, they are not. Is there any geek who can tell me if this is a bug? (some weird '\x00\x00' was inserted...
9
by: rattan | last post by:
I want a specific packet format for packet exchange between a client server across the network. For example frame format as a python class could be: class Frame: def __init__(self, buffer=None,...
6
by: Jack | last post by:
Hi, All, is it possible to send a struct using the the send function. Here is what I mean typedef struct{ int ID; char name; }sampleStruct; int main(){
4
by: Joshua J. Kugler | last post by:
I'm trying to put some values into a struct. Some of these values are NaN and Inf due to the nature of the data. As you well may know, struct (and other things) in Python <= 2.4 doesn't support...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.