Start Btach Programming Bug

You can either use the bug tracker or describe the anomaly here.

Re: Start Btach Programming Bug

Postby admin » 19, 2011 Mar Sat 10:53 am

The reason why I suspect an adaptor related problem is because here I have no issue when using batch mode and OscCal:
Code: Select all
11:44:01.781 BATCH PROG: Insert device or connect ICSP, then press Enter or OK !
11:44:07.218 BATCH PROG: please wait..
11:44:07.218 Programming...
11:44:07.218 Erasing ("bulk" or "chip") ...
11:44:10.296 Read osccal, result 0x003450
11:44:12.578 Read cfg with bandgap ref, result 0x0021DC
11:44:12.578 Erasing chip using algorithm "12Fxx" .
11:44:14.859 Replaced OSCCAL word in buffer: old=0x003FFF, new=0x003450 .
11:44:14.859 Programming CODE, 0x000000..0x0003FF
11:44:14.859 Programming 0x000000..0x0003FF, algo="12Fxx", CanRead=0 .
11:44:32.812 Verifying 0x000000..0x0003FF
11:44:39.203 Restoring BANDGAP calibration bits for CONFIG-WORD
11:44:39.203 Cfg word before restoring BG calib: 0x003FDC
11:44:39.203 Cfg word after restoring BG calib: 0x002FDC
11:44:39.203 Programming CONFIG, 0x002000..0x002007
11:44:39.203 Programming 0x002000..0x002007, algo="12Fxx", CanRead=0 .
11:44:41.609 Verifying 0x002000..0x002007
11:44:43.703 Programming finished, no errors.
11:44:43.921 BATCH PROG: Insert device or connect ICSP, then press Enter or OK !
11:44:54.781 BATCH PROG: terminated batch mode.

But I realize that in your trace you get "Erasing CODE" before the error when I get "Erasing ("bulk" or "chip") ..."
I will search why is there this difference. It may be reason of the problem...
admin
Site Admin
 
Posts: 153
Joined: 12, 2009 Jul Sun 7:20 pm

Re: Start Btach Programming Bug

Postby admin » 19, 2011 Mar Sat 11:15 am

I have unchecked Program DATA memory and use BULK ERASE (to unprotect) and I get the same messages as you... except it still works on my side...
Code: Select all
12:04:00.281 BATCH PROG: Insert device or connect ICSP, then press Enter or OK !
12:04:04.218 BATCH PROG: please wait..
12:04:04.218 Programming...
12:04:04.218 Erasing CODE
12:04:07.359 Read osccal, result 0x003450
12:04:09.656 Read cfg with bandgap ref, result 0x0031FF
12:04:09.656 Erasing chip using algorithm "12Fxx" .
12:04:11.921 Programming CODE, 0x000000..0x0003FF
12:04:11.921 Programming 0x000000..0x0003FF, algo="12Fxx", CanRead=0 .
12:04:30.46 Verifying 0x000000..0x0003FF
12:04:36.578 Restoring BANDGAP calibration bits for CONFIG-WORD
12:04:36.578 Cfg word before restoring BG calib: 0x002FDC
12:04:36.578 Cfg word after restoring BG calib: 0x002FDC
12:04:36.578 Programming CONFIG, 0x002000..0x002007
12:04:36.578 Programming 0x002000..0x002007, algo="12Fxx", CanRead=0 .
12:04:38.968 Verifying 0x002000..0x002007
12:04:41.62 Programming finished, no errors.
12:04:41.296 BATCH PROG: Insert device or connect ICSP, then press Enter or OK !
12:04:50.281 BATCH PROG: terminated batch mode.

I will try to review again the code with this setup in mind...
admin
Site Admin
 
Posts: 153
Joined: 12, 2009 Jul Sun 7:20 pm

Re: Start Btach Programming Bug

Postby ata » 19, 2011 Mar Sat 1:40 pm

I tryed with Program Data checked and without code protection in my code... And the same.. Normal mode works OK and Start Batch fails..

I wonder if your LPT adapter has the OK-Button.. or you use enter in the Start Batch mode instead... (I'm not in my office now.. so I will try this next monday)... Maybe that is the difference ... anyway I need to use the Ok-Button so the two operators don´t need to use the PC keyboard when programming too many pics..

But I've noticed that the "ESC" key doesn´t terminate the Batch mode as I can see you terminted it in your traces !!!
Maybe it doesn´t mean anything but are the difference I noted between your traces and mine.

If you can .. please give me some hints about your adapter in order to replicate it and test.

Thanks a lot for your help
ata
 
Posts: 12
Joined: 08, 2011 Mar Tue 11:00 pm

Re: Start Btach Programming Bug

Postby admin » 19, 2011 Mar Sat 2:29 pm

I have published the description of my adapter here.

Of course I am using the keyboard as I have no button on it. And I noticed the random problem of the keyboard not working well. Unfortunately it always works under debug. I am already searching in that direction too. This random issue may have the same cause as your problem. At least I cannot prove the opposite since I can't trigger the batch mode when the problem exists!
admin
Site Admin
 
Posts: 153
Joined: 12, 2009 Jul Sun 7:20 pm

Re: Start Btach Programming Bug

Postby admin » 19, 2011 Mar Sat 10:54 pm

I was going crazy because I did not find why the installed R108 was not behaving the same as when under debug. I finally found the reason after checking the About dialog. It was not the R108 that I installed :!: I remember now having been puzzled that the installer generator did not named it automatically R108... I thought it had some regression. But in fact the installer was there with the right name just one line below the window bottom. I gave you, and I was using, an old installer generated about one year ago.

So now, with the R108, the ESC key works in debug in all cases, and the Enter key works if the log memo control has the focus (it does not work when a control processing ENTER such as a button has the focus. I will fix that later.)

So the test you made was worthless as this was still sort of V1.2.1 version. Sorry for that.

Could you retry the test with this real R108 installer.
admin
Site Admin
 
Posts: 153
Joined: 12, 2009 Jul Sun 7:20 pm

Re: Start Btach Programming Bug

Postby ata » 21, 2011 Mar Mon 11:12 pm

Using WxPic-TrunkR108... Now it works..

But I had to enable the "Program Data memory" option to make Start Batch Mode work correctly.
Later I reinstalled former version 1.2.1 and try with "Program Data memory" enabled.... And it works too

On both version, you must enable the "Program Data memory" option (even if you don't need to program EERAM cpu space)
In order to make the Start Batch mode works correctly.

On version 1.2.1 ESC Key doesn't terminate the Batch mode (nor any PC Key)... You have to close the program.
On the new version... ESC Key correctly terminates the Batch mode.

To me, this is a minor bug, Just keep the "Program Data memory" option enabled and I can have two programmers adapters connected at the same time to one PC
(WinPic to LPT1 and Wxpic to LPT2). So two operators can program different (or the same) cpu with different (or the same) code prog without keyboard and display.

Thanks a lot for your effort, support and great software.
If I can be of any help to you, don't hesitate to ask.
ata
 
Posts: 12
Joined: 08, 2011 Mar Tue 11:00 pm

Re: Start Btach Programming Bug

Postby admin » 21, 2011 Mar Mon 11:33 pm

I am glad you find the condition that makes it working.
I will check why it does not work with "Program Data memory" disabled. I am not sure I can reproduce the problem because I believe I already tested it. But I also know that there is a significant difference between the 2 modes that use different branches of code. And this difference may not be justified as there will be no data programming, even when requested, if the data memory is empty. I will look deeper in this area.

I may think about allowing several instances of WxPic with different configurations for the different instances for a future version...
admin
Site Admin
 
Posts: 153
Joined: 12, 2009 Jul Sun 7:20 pm

Re: Start Btach Programming Bug

Postby ata » 22, 2011 Mar Tue 8:31 pm

Different instances of WxPic with different configurations.... Is a very good idea.

But keep an eye on with Parallel ports... The driver has to allow different instances (of wxpic) pointing to different ports (LPT1, LPT2....)
without windows fooling around the LPT ports.

Also, parallel adapters are the best suited to have the OK_Button and the RED/GREEN Leds... very useful when having more than one prog adapter at the same time connected to the same PC. This way, the operators don't need to access the PC keyboard or watch the PC display... Just press the OK-Button and wait for the Green Led to place the next cpu.

The only reason for having more than one instance of wxpic, is to work with more than one adapters at the same time without caring about the PC.
And the only adapter that suits this need is the parallel adapter... I don't know how to do it with serial adapters.

At last, please keep the concept of the device.ini... So any one can add a new pic device without bothering you to add it.. I added many to wxpic (and winpic too)

If you think I could help you design a new (simple) type of adapter, lets say: a serial one (via USB-Serial cable) which alows the OK-Button and the Green/Red leds...
Please tell me... I can do it and send the pcb-assembled to you to test.

The idea is to keep it simple but useful..

Thanks a lot for your effort and great software
ata
 
Posts: 12
Joined: 08, 2011 Mar Tue 11:00 pm

Re: Start Btach Programming Bug

Postby admin » 03, 2011 Apr Sun 10:06 pm

Hello,

I finally found and fixed the origin of the problem. I released the V1.2.2 that contains this fix.

Thank you for your offer to design an adapter. But I have no time to work on hardware at this moment. May be one day I will think about creating a new adapter. But I have other priorities before.

I have started to think to the "multi-session". The most complicated is to have the different instances negotiating their number in a portable way so that they select each their own parameter set. Nothing else should be modified.

Philippe
admin
Site Admin
 
Posts: 153
Joined: 12, 2009 Jul Sun 7:20 pm

Re: Start Btach Programming Bug

Postby ata » 04, 2011 Apr Mon 8:20 pm

Works Perfectly... no problem to be reported.

I also tested with other 12F (even with an 12F1822), 16F and 18Fxxxx... and works perfectly

Thanks a lot for your effort and great work.
If I can be of any help... please don't hesitate to ask.
ata
 
Posts: 12
Joined: 08, 2011 Mar Tue 11:00 pm

PreviousNext

Return to WxPic bug reporting

Who is online

Users browsing this forum: No registered users and 1 guest

cron