Another thread has prompted me to ask this question. I need to process two hex files to produce a third. I want to slice two large chunks (204 bytes) from the front of the hex files, compare the chunks and then append one or both to a third file. I want to repeat this until I run out of data. (I'm basically zipping two same sized MPEG Transport Streams into another the same size. There aren't any commercial tools or freeware available that will do exactly what I want.) The comparison will involve looking at two thirteen bit binary numbers.
All three files will be 270 MBytes in size (which is why I don't want to do this by hand with a hex-editor!)
I was going to use something like C or Basic to do this, but I'm wondering if it could be done with a shell script instead. Is it possible to grep (or equivalent function) a 13 bit binary word and then do a comparison or examine the binary string? Everything I have read about shell scripting seems to describe processing byte-aligned data containing printable strings. I'd be delighted if someone could disprove this. I've tried googling but not come up with any relevant results.
I should probably add that this is totally legit. I'm not editing copyrighted DVDs or anything, I'm producing a test stream from a hex file I have generated and some colour bars.
Thanks guys.
Shell scripts and non-text files
Puppy related raves and general interest that doesn't fit anywhere else
Message
Author
Jump to
- House Training
- ↳ Beginners Help ( Start Here)
- ↳ Users ( For the regulars )
- ↳ Für deutschsprachige Anhänger
- ↳ Pour les francophones
- ↳ Usuarios de habla Hispana
- ↳ HOWTO ( Solutions )
- ↳ Bugs ( Submit bugs )
- Advanced Topics
- ↳ Additional Software (PETs, n' stuff)
- ↳ Package Collections / Repositories
- ↳ REQUESTS
- ↳ Browsers and Internet
- ↳ Business
- ↳ Compiling
- ↳ Desktop
- ↳ Documents
- ↳ Drivers
- ↳ Educational
- ↳ Engineering/Science/Simulation
- ↳ Eye Candy
- ↳ Filesystem
- ↳ Games
- ↳ Graphics
- ↳ Multimedia
- ↳ Network
- ↳ Security/Privacy
- ↳ System
- ↳ Utilities
- ↳ Virtualization
- ↳ Unsorted
- ↳ Cutting edge
- ↳ Multi-session live-CD/DVD
- ↳ Hardware
- ↳ Audio
- ↳ Networking
- ↳ Dialup
- ↳ Ethernet
- ↳ Wireless
- ↳ Printers
- ↳ Video
- ↳ Puppy Derivatives
- ↳ Puppy Projects
- ↳ Next Puppy Development
- ↳ 4.x
- ↳ Bugs (4.x dev)
- ↳ Usability Issues (4.x dev)
- ↳ 5.x
- ↳ Bugs (5.x dev)
- ↳ Usability Issues (5.x dev)
- ↳ Localization Project
- ↳ Documentation Project
- Taking the Puppy out for a walk
- ↳ Announcements
- ↳ Puppy Power
- ↳ Suggestions
- ↳ Misc
- Off-Topic Area
- ↳ Programming
- ↳ Security
- ↳ Truly off-topic conversations
- ↳ Spam reports