Hi.
I have been working on a project with TTL jpeg camera + rs485 + bunch of other stuff.. And been busy writing some libraries for my project.. Skipping now to the interesting part..
I wrote a small protocol library for rs485 with 3 modules: command module (ascii commands), something like the serial command from arduino, receipt module for that (simple answering module), and a simple file transfer module ( and actually xmodem as well, but didn't use it with this).. Every module has a checksum system, so data can be validated. It's very simple but causes some extra data. But not a problem.
Well, I put all the pieces together, hardware and software and wrote a simple "server" software to my computer which I also connected to my rs485 bus.. And started a.. Small stress test.. My computer request the maple to take a photo with camera and then send it over rs485.. Loop on maple is a simple rs485 listener.. And loop on my computer is one that sends requests for image file to maple..
Been doing some tests during this day and lots of data has passed through my rs485 during the whole project.. But never so much as today.. My usual tests today were about 200 pictures, but finally I decided to stick with my code.. And started a final test, which ended with 370 images sent. These images are about 12000-16000 bytes in size.. (320x240)..
Transfers are done in 248byte blocks, because data must be readed from camera at same time, camera should support 115200, but the truth is that it doesn't- data loss is huge with anything else than 38400..
And camera also doesn't seem to support larger that 248 byte blocks to be downloaded.. So file transfer reads 248 bytes from camera with 38400 baudrate, makes a header for it and sends it to my computer along with header with 115200 baudrate- all this takes about 6 seconds.
I guess amount of pictures send today is nearly 2000 in complete, but those last 370 images were the last nail in the coffin so to speak.. I first suspected it's my code and started to make changes.. The problems were that my maple was sending false information.. I had bool variables for somethings, like: is camera frozen, was camera initialization okay, is TVout enabled, is internal motion detecting system enabled.. And if the camera has not been frozen to frame, maple still returned that yes, it is frozen because even though I set the boolean variable to false (trust me, I multiplied setting of variable to false and still..), it resulted the previous value..
There were other strange things too, data errors on the line started to occur a bit too often..
I finally took another maple and tried with that one.. And it works perfectly!
Now the question is; have I fried my maple's RAM? What are the limitations of this device? It is very propable.. That the broken maple cannot be revived, but is there a diagnostic software that I could flash on it that could be used to do some testing that what has gone wrong with it, so I could avoid breaking others as well? Okay, amount of data transmitted must be doubled as it's first readed from camera and then sent, I calculated that it's not huge gigabit like transfer, more like 50 megabytes.. But it's huge amount of data regarding to the project I've been planning here.. So this amount of data normally would never been transmitted through my maples.. But is there any point to keep working on this or am I just breaking all my devices here?