What's new
Technically speaking XT/HS should work regardless (the difference is current gain to drive an oscillator circuit on CLKOUT, but the dimm is using a clock generator). The 628 has the EC (external clock) option, which the 621 does not. EC will enable CLKIN pin, and disable the driver on CLKOUT.

If programming PIC16F628A, use EC (EXTCLK) as that is the best option for the application
I agree that on the 627/628 it is more logical to use EC but please test this people!
Maybe EC will be better on Chihiro/Triforce as well but I would like to see hardware pictures first!
As I said, I can test different PIC codes with my Naomi1 and NetDimm.

Unfortunately I don't have a Chihiro or a Triforce.

One thing that is not really clear to me is which kind of behaviour I'm supposed to see checking the different codes.

I'm still using werejag's code till now and I can't see any problem, so testing HS mode or EC mode is obviously doable but I'm not sure what to expect from the different codes.
 
@zeruel85 please just try the image I posted and burn one device with HC and verify and then burn one with EC clock to see if it works.
 
Here I am.

I'm testing right now Gigawing 2.

Results:
1. Using rtw's bin file with HS mode: Error 33
2. Using rtw's bin file with EC mode: Error 33
3. Using werejag's hex file: Works OK
4. Using rtw's bin file with werejag's settings: Works OK
5. Using rtw's bin file with HS mode (MCLRE disabled): Error 33
6. Using rtw's bin file with HS mode and all other parameters (BOREN, /PWRTE, WDTE) as per werejag's file: Works OK
7. Using rtw's bin file with EC mode and all other parameters (BOREN, /PWRTE, WDTE) as per werejag's file: Works OK

Settings taken from werejag's hex file attached.

CONCLUSION:
I think that the most important parameters are BOREN, /PWRTE and WDTE at this point, because it always works, no matter what kind of osc mode we select.
Next step could be trying to disable one of the three parameters, but it's a lot of work and a lot of possible combination.
 

Attachments

  • werejag-settings.jpg
    werejag-settings.jpg
    99.4 KB · Views: 287
Last edited:
@zeruel85 that was some pretty impressive testing, thank you very much!

The reason why this code works so well with werejag's settings is because I have posted the wrong settings:cursing:

I went back and checked my notes, these are the correct settings:

Set memory protection at your discretion
MCLRE should be set to internal also called "disabled"
WDTE (watchdog) disabled.
LVP (low-voltage programming) enabled.
PWRTE (power up timer) enabled.
BOREN/BODEN (brown-out reset) disabled.
Clock source should be set to HS

If you could be so kind to do the test with my image and the settings above we might actually get to the bottom of this.
 
Last edited:
@zeruel85 that was some pretty impressive testing, thank you very much!

The reason why this code works so well with werejag's settings is because I have posted the wrong settings:cursing:

I went back and checked my notes, these are the correct settings:

Set memory protection at your discretion
MCLRE should be set to internal also called "disabled"
WDTE (watchdog) disabled.
LVP (low-voltage programming) enabled.
PWRTE (power up timer) enabled.
BOREN/BODEN (brown-out reset) disabled.
Clock source should be set to HS

If you could be so kind to do the test with my image and the settings above we might actually get to the bottom of this.
I've just tried but it gives me Error 33. :(

EDIT:
WTF! I made a mistake. Please give me another minute to recheck the settings. :D

EDIT2:
Are the settings correct now? Look at the pic please.
 

Attachments

  • rtw-correct.jpg
    rtw-correct.jpg
    101.8 KB · Views: 222
Last edited:
To clarify the naming and logic of settings with TL866:

Checked = 1
Unchecked = 0

Config options that start with '/' means 'active low', so 0 = enabled, 1 = disabled
 
Ok, I retried with the settings attached, but without luck, always Error 33.
 

Attachments

  • rtw-correct.jpg
    rtw-correct.jpg
    101.8 KB · Views: 152
That software is a bit interesting ...

Something is wrong, the final register should be: 0x3F82

I.e. werejag's settings but BODEN switched off.
 
That software is a bit interesting ...

Something is wrong, the final register should be: 0x3F82

I.e. werejag's settings but BODEN switched off.
0x3F82:
 

Attachments

  • 0x3f82.jpg
    0x3f82.jpg
    99.5 KB · Views: 158
This post intentionally left blank :D
 
Last edited:
Let me try something, hold on for 5 minutes.
I think I'm undestanding. 0x3FFF is all unchecked, 0x3F00 is all checked. Maybe if you want 0x3F82 you need to do 0x3FFF - 0x3F82 = 0x3F7D, and so it explains werejag's settings.

I don't know if you can follow my reasoning. :D

Sorry, I'm not a EE, but an Aerospace Engineer, so programming this kind of stuff is just a hobby for me. :)
 
OK, can you try that file on a PIC, it is a NETBOOT PIC!

Sounds pretty cool being an Aerospace Engineer :thumbsup:
Your hex works fine!

Looking at the config bits, you are using INTOSC (fosc=101), right?

EDIT: oh my god, using Elnec software the config bits are exactly reversed with respect of TL866, is this normal???
 

Attachments

  • rtw-hex-elnec.jpg
    rtw-hex-elnec.jpg
    31.1 KB · Views: 186
  • rtw-hex-tl866.jpg
    rtw-hex-tl866.jpg
    99.5 KB · Views: 185
Last edited:
OK, can you try that file on a PIC, it is a NETBOOT PIC!

Sounds pretty cool being an Aerospace Engineer :thumbsup:
Your hex works fine!
Looking at the config bits, you are using INTOSC (fosc=101), right?
Normality has returned :D

No I am using HS, the problem is that your software shifts bits around, this had me very confused.
Tomorrow I will generate .hex files from my tools with the settings and maybe the mods can clean up a bit here afterwards :D

Thank you for your testing @zeruel85!
 
OK, can you try that file on a PIC, it is a NETBOOT PIC!

Sounds pretty cool being an Aerospace Engineer :thumbsup:
Your hex works fine!Looking at the config bits, you are using INTOSC (fosc=101), right?
Normality has returned :D
No I am using HS, the problem is that your software shifts bits around, this had me very confused.
Tomorrow I will generate .hex files from my tools with the settings and maybe the mods can clean up a bit here afterwards :D

Thank you for your testing @zeruel85!
Yeah, I noticed that too, very confusing!
See my previous post, you can see how the bits are perfectly reversed, what a mess!

Glad to help the community by the way. :)

For tonight I'm done, tomorrow I can test other codes, if you want.

Thanks for your help mate. :)
 
Chihiro and triforce 3 use a ceramic oscillator. The pic is plugged into a small vertical daughterboard that plugs into the dimm board. The oscillator is on that same small daughterboard. I assume it needs the pic oscillator circuits.
 
pic.png





I can't seem to get this to work. I burned the file with my GQ-4X using the settings provided. The game loads and verifies, but I get error 33 Gateway not found once the game tries to actually boot. Anything else I can try? I've tried a few different games.
 
Back
Top