TYTEs - more than a word but not as long - agreed?
Peter Jakacki
Posts: 10,193
Dear Chip,
I use PNut to construct bytes, words, and longs, but what I would also like is an operator that takes 3 bytes. I'm sure it would be fairly simple to implement and the hardest part is coming up with a suitable name which is why I have suggested tryte for "triple byte". Now that I have done my part then how about it? Huh?
BTW, this is all your fault Chip, you made P2 handle unaligned data easily so seeing that I have 16-bit words addressing 64k which I could stretch to 256k I also thought well instead of a wasteful 32-bit address why not just use 24-bit addresses which are fetched with a long as the top 8-bits would be ignored in any memory reference. So if I can I will try trytes.
I use PNut to construct bytes, words, and longs, but what I would also like is an operator that takes 3 bytes. I'm sure it would be fairly simple to implement and the hardest part is coming up with a suitable name which is why I have suggested tryte for "triple byte". Now that I have done my part then how about it? Huh?
BTW, this is all your fault Chip, you made P2 handle unaligned data easily so seeing that I have 16-bit words addressing 64k which I could stretch to 256k I also thought well instead of a wasteful 32-bit address why not just use 24-bit addresses which are fetched with a long as the top 8-bits would be ignored in any memory reference. So if I can I will try trytes.
Comments
I was thinking that with the way the hub FIFO works, it could easily be made to handle any data size from 1 to 32 bits. The RAMs that we are using have bit-level write control, so it could work both ways. It's not practical to implement, at this point, but it could be used for things like 3-bit pixels, etc. I guess all addresses would need another 3 bits to get down from bytes to bits. Spin could be compiled into various bit-length data instead of just bytes. That's how the BASIC Stamp worked; that interpreter often just read one bit.
tribbles will dribble,
if bit two bytes
past a nibble.
Word!
https://en.wikipedia.org/wiki/Ternary_numeral_system
so we are same generation ? ;-)
a while ago there was Star Trek Night here and people selected the Trybbles episode as one to see again. ;-)
That way, it's still 4 letters, like the others.
Hi Chip, I think you're weally wong this time but you may be on to something. How about we shorten tryte to tryt to make it four characters and unique?
I have amended the title accordingly.
But WONG!
Aren't two words in there, but since the hub is byte-aligned it does not matter. It's 3 bytes, so a TONG might work.
But I do like the tribble or short TRIP. Yeah. That might work.
Enjoy!
Mike
Anything "ibble" based sounds good but a nibble is 4-bits so it would have to be hexiblle or "sexibble" but I favor a 4 letter version that at least sounds like 3 bytes.
There most certainly are two words in there. This instruction is to take a long, ie 2 words on the Propeller, and place them into some new order of binary management. So with this in mind, I'm standing by TWIT!
All this dribble stuff, meh, but TRIN sounds good also.
Enjoy!
Mike
RDBYTES D/#, S/#/ptr, #n
WRBYTES D/#, S/#/ptr, #n
xxBYTE, xxWORD, and xxLONG would just be aliases for N=1, 2, and 4 respectively.
BYT3 = byte with backwards E
I'm not quite following - Chip said this would be a PNUT ASM change, but your example suggests a packed reading of 3 bytes
( with presumably a matching Ptr+3 ). That's more than an Assembler change ?
TRIB = TRI-Byte
On the other hand the other permutation/contraption of LONG+WORD might even be better: LORD! Everybody knows christians have that sweet spot for trinity and everything-three! :clown:
Would also sound like be me everytime someone suggests to extend the instruction word to some wacky number <> 32!
http://www.oddee.com/item_98063.aspx
tri-bytes seems to be a bit of better lexicon. Beware of men in tytes.
Instead of 4 bits equaling a nibble, you could call 4 bits a tutu.
http://www.discountdance.com/dancewear/style_A1705.html?pid=17993&Shop=Style&SID=759255075
http://www.amiami.com/top/detail/detail?gcode=FIGURE-014564&page=top