xianthax Posted January 13, 2007 Report Share Posted January 13, 2007 i have a project that requires that i output a bit stream from memory very fast.....16Mhz. the catcher is that i need an untouched bitstream, i.e. i need to write 64K bytes + of data out at 10Mhz with no stop bits no sync bits jsut a straight dump from memory. I've already tried with a pic and various approaches using different serial interfaces with no success.does anyone still make a bitwise chip? the limiting factor i have found is that it is difficult to extract a bit in a modern microprocessor, it requires a mask, a comparison then a write to the output latch and i need to load a byte at a time into memory. does anyone have an idea of a chip that is capable of doing this that is resonable in price / board space?thanks in advance.-xian Quote Link to comment Share on other sites More sharing options...
MP Posted January 13, 2007 Report Share Posted January 13, 2007 Pic needs 4 clock cycles per instruction. AVR completes one instruction per clock cycle.I have no idea what you are talking about with bitwise chips, comparisons, and having problems extracting a bit at a time with a micro. Never had such problems with a micro. Are you refering to CRC error checking? Not required, but a good idea to check to make sure your transmitted data is ok. You didn't say RS232 was a requirement. Why not use I2C protocol?MP Quote Link to comment Share on other sites More sharing options...
xianthax Posted January 14, 2007 Author Report Share Posted January 14, 2007 well i'm not accually tranmitting data, there isn't another chip receiving this data. i simply need to spit out say 64Kbit as a bit stream at a particular clock speed. i'm trying to work this in on a pic as i have one in place already, but the solution does not seem easy on a pic.....by bitwise i mean......think of the process need to do what i'm talking about in a pic there is no "put bit 7 from the byte at 0x7h to pin RB3" instruction because pic's deal in bytes, not bits, as their primary block or data. to do that with a pic you have to move the byte containing the bit you want to a reg, mask/compare it then output the result. in psudo C:pin RB3 = (byte & 0b00000010) == 0b00000010;that compiles to almost 10 instructions. of course to output each bit in the byte you have to right rotate the mask or the byte, maintain counters to decide when to load the next byte, etc, and keep everything timed to the output freq is correct. obviously i'm trying to shoehorn something into a pic it wasn't really designed to do...i'm now looking at possibly some memory chips that are capable of just dumping bits and tapping into that but i'm always open to other ideas.thanks for the response-xian Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.