Page 8 of 9

Re: FreeEMS_Loader

Posted: Wed Oct 10, 2012 2:19 pm
by SleepyKeys
Yes! Give me 2-3 hours.

Re: FreeEMS_Loader

Posted: Wed Oct 10, 2012 2:22 pm
by flat4power
no problem
I could not get back to that tomorrow morning so you have all the night ;)

Re: FreeEMS_Loader

Posted: Wed Oct 10, 2012 4:02 pm
by SleepyKeys
How did you get the file set? If you used git, please run 'git log' the first entry you see should be as follows:

commit 100317afebb1b8402b2e5094cdd259731f893db1
Author: Sean Keys <skeys@ipdatasys.com>
Date: Wed Oct 10 07:46:05 2012 -0700

Removed duplicate entries in qmake file so that overriding commands for target type warings dont occour when building under linux

Let me know.

Thx!

Re: FreeEMS_Loader

Posted: Wed Oct 10, 2012 4:04 pm
by SleepyKeys
oops, if you run 'git pull' and then 'git log' you should end up with that being your first commit :). I was getting ahead of myself .

Re: FreeEMS_Loader

Posted: Wed Oct 10, 2012 4:24 pm
by Fred
git describe --dirty=-DEV --always

is better, and having git status output is better still.

I've just done an LA log of your loader, and I know why it's slow...

Basically: it's too simple/unsophisticated.

You're sending an S19 record, then reading it back. What you could/should be doing is assembling S19 records into contiguous blocks of memory such that you can do full sized writes of 256 bytes in one shot. I want you to NOT change it, unless the new code comes fully covered with genuine unit tests, as it's too complex to just wing IMO.

Another thing you're doing is erasing the entire device, rather than just the bits you need to. Full erase is 10.7 seconds, compared to the ~3 seconds of erasing that needs to be done.

And because you erase all, and then load/verify you're making extra page change calls, too. With windows shitty IO causing a lag PER TRANSACTION, and you doing 32 times more transactions than me... that explains why you get fucked so badly on windows and I do not.

Additionally, the requests and responses become a larger percentage of the data the smaller you go...

Image

Attach keeps failing, I give up:

http://stuff.fredcooke.com/why.seans.lo ... .logicdata

Fred.

Re: FreeEMS_Loader

Posted: Wed Oct 10, 2012 4:39 pm
by SleepyKeys
Yeah "git describe --dirty=-DEV --always" needs to ring true for the serialLib too.

Neat pic.

"Basically: it's too simple/unsophisticated."
Performace was not a concern at the time writing this, at least within reason, so the code is basically as simple as possobile.

"You're sending an S19 record, then reading it back. What you could/should be doing is assembling S19 records into contiguous blocks of memory such that you can do full sized writes of 256 bytes in one shot. I want you to NOT change it, unless the new code comes fully covered with genuine unit tests, as it's too complex to just wing IMO."

This was the simpleest way to get the job done. I read it back for verification, yes writing in block of 16 is not ideal when you can go up to 256 we talked about this a long time ago.

"as it's too complex to just wing IMO" yes, +1

"Another thing you're doing is erasing the entire device, rather than just the bits you need to. Full erase is 10.7 seconds, compared to the ~3 seconds of erasing that needs to be done."
Yeah, again I have known that from day one. This goes back to what I said above "Performace was not a concern at the time writing this, at least within reason, so the code is basically as simple as possobile. " Althought this is much simpler to accomplish than wiring variable block sizes.

Re: FreeEMS_Loader

Posted: Thu Oct 11, 2012 4:59 pm
by SleepyKeys
Bump for flat4power :)

Re: FreeEMS_Loader

Posted: Fri Oct 12, 2012 9:01 am
by flat4power
Sean0 wrote:How did you get the file set? If you used git, please run 'git log' the first entry you see should be as follows:

commit 100317afebb1b8402b2e5094cdd259731f893db1
Author: Sean Keys <skeys@ipdatasys.com>
Date: Wed Oct 10 07:46:05 2012 -0700

Removed duplicate entries in qmake file so that overriding commands for target type warings dont occour when building under linux

Let me know.

Thx!
Hi,
So I proceed like that :

Code: Select all

root@srv-web-2:~# git clone git://github.com/seank/FreeEMS-SerialIO.git
Cloning into 'FreeEMS-SerialIO'...
remote: Counting objects: 414, done.
remote: Compressing objects: 100% (155/155), done.
remote: Total 414 (delta 262), reused 407 (delta 255)
Receiving objects: 100% (414/414), 353.23 KiB | 341 KiB/s, done.
Resolving deltas: 100% (262/262), done.
root@srv-web-2:~# cd FreeEMS-SerialIO/
root@srv-web-2:~/FreeEMS-SerialIO# qmake && make
Project MESSAGE: Building Release Version
Project MESSAGE: Straight Linux Build
Makefile:298: warning: overriding commands for target `install_target'
Makefile:270: warning: ignoring old commands for target `install_target'
Makefile:306: warning: overriding commands for target `uninstall_target'
Makefile:278: warning: ignoring old commands for target `uninstall_target'
Makefile:318: warning: overriding commands for target `install_headers'
Makefile:286: warning: ignoring old commands for target `install_headers'
Makefile:324: warning: overriding commands for target `uninstall_headers'
Makefile:292: warning: ignoring old commands for target `uninstall_headers'
g++ -c -pipe -Wall -Werror -O2 -D_REENTRANT -Wall -W -fPIC -DQT_WEBKIT -DQT_NO_WARNING_OUTPUT -DQT_NO_DEBUG_OUTPUT -DQT_NO_DEBUG -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4 -Isrc -Isrc/inc -Isrc/inc/public -I. -o AsyncRead.o src/AsyncRead.cpp
src/AsyncRead.cpp: In member function ‘virtual void IPDS::AsyncRead::run()’:
src/AsyncRead.cpp:59:33: error: ‘read’ was not declared in this scope
make: *** [AsyncRead.o] Error 1
root@srv-web-2:~/FreeEMS-SerialIO# git log
commit 36cbde09f2bb105d263d9eaceabcbe702b72c9ae
Author: Sean Keys <skeys@ipdatasys.com>
Date:   Sun Oct 7 08:21:09 2012 -0700

    Lowered the amount of time read() blocks for.  Put in prototype for a findPorts() function along withe some skeleton code

Re: FreeEMS_Loader

Posted: Fri Oct 12, 2012 2:35 pm
by SleepyKeys
'git log' should show :
commit 85e32661d6281c312c8801f2cbe7c7b8c52c172b
Author: Sean Keys <skeys@ipdatasys.com>
Date: Wed Oct 10 07:59:48 2012 -0700

Comment and cleanup qmake file. Override warnings should be suppressed when building on other platforms

first log entry displayed^

What does 'git describe --dirty=-DEV --always' show ?

Any chance I can ssh into your machine? A basic user account would do.

FWIW
seank@dv6500:~/work/workspaceCDT/asyncSerial$ qmake
Project MESSAGE: Building Release Version
Project MESSAGE: Straight Linux Build

Re: FreeEMS_Loader

Posted: Fri Oct 12, 2012 2:46 pm
by flat4power

Code: Select all

root@srv-web-2:~/FreeEMS-SerialIO# git describe --dirty=-DEV --always
36cbde0
edit:
PM for ssh access ;)