[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [lwip-users] lwIP on TI C55 processor
From: |
Jamie Granger |
Subject: |
RE: [lwip-users] lwIP on TI C55 processor |
Date: |
Thu, 3 Sep 2009 16:21:56 +0100 |
Chris,
Yes, the C55 does allow packing 8-bit values to/from 16-bit words as you
suggest. This is all just 16-bit operations, and shifting and masking,
which are fine. In fact there is a "char" type on the C55, but it is a
16-bit value which uses only the lower 8-bits.
So I think, in many places in lwip where an 8-bit pointer is used to
access memory, I would have to replace it with some packing/unpacking
similar to your example. It looks like it might be a lot of work -
which is why I was asking if anyone's already done it.
Thanks,
Jamie
-----Original Message-----
Jamie,
Does the C55 provide any way of handling 8 bits, or of packing 16 bits
down to 8?
For instance:
int16 a,b,c;
c = (a<<8) + (b & 0x00ff);
where the 8 bit values are the bottom 8 bits of the 16 bit a and b.
Much of the data encoding in TCP/IP etc is 8 bit values packed into 16
bit locations. If you can manage the pack and unpack, then there is
hope.
Regards,
Chris.
--
------------------------------------------------------------------------
---
| Chris Williams EMail address@hidden
|
| Web www.chrydesn.co.uk
|
| Tel/Fax 01686 688065
|
| Chrysalis Design. Electronics, Computers, Hardware, Software.
|
| Design and development to meet all your needs.
|
------------------------------------------------------------------------
---
_______________________________________________
lwip-users mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/lwip-users
This e-mail and any files transmitted with it ("E-mail") is intended solely for
the
addressee(s) and may contain confidential and/or legally privileged
information.
If you are not the addressee(s), any disclosure, reproduction, copying,
distribution
or other use of the E-mail is prohibited. If you have received this E-mail in
error,
please delete it and notify the sender immediately via our switchboard or
return e-mail.
Neither the company nor any individual sending this E-mail accepts any liability
in respect of the content (including errors and omissions) and timeliness of
the E-mail
which arise as a result of transmission. If verification is required, please
request
a hard copy version.
ERA Technology Ltd Registered in England Number 4044609 Registered Office:
Brook Road, Wimborne, Dorset, U.K. BH21 2BJ .
This email was scanned by Postini, the leading provider in Managed Email
Security. For more information visit
www.groveis.com