Hacking COMPLETED BASIC MODCHIP / DONGLE UF2 SD BOOT FILES. Trinket / Rebug / RCMX86 / Others

iriez

Well-Known Member
Member
Joined
Oct 27, 2016
Messages
549
Trophies
0
Age
49
Website
www.xbins.org
XP
1,867
Country
United States
So you are flashing it by serial?

Using the swd and sck pins?

If it isn't being recognised by usb, no serial port is being configured. This leaves serial debugging.

You must be bit banging it with some gpios on something. Jlink? Openocd?

If it isn't compiling correctly, that could be because I haven't finished sorting my git out.

Short term fix to get it to compile... Take the 1 off the end of the fusee array and length

No, i am flashing via USB via I assume emulated serial. This functionality is built into the trinket m0. The device is fine, it connects and is assigned a COM port. BTW this is the way quantumcross originally did his version and has been working fine for me. I can flash this device NP with other builds, just not with the current code as-is.

When you say take the 1 off the end of the fusee array and length, do you just mean changing "sendPayload(fuseeBin1, FUSEE_BIN_SIZE1);" to "sendPayload(fuseeBin, FUSEE_BIN_SIZE);" for 1-8? If not, could you please specify which line the array and length is referenced? I searched for "array" and "length" there are no matches.
 

mattytrog

You don`t want to listen to anything I say.
OP
Member
Joined
Apr 27, 2018
Messages
3,708
Trophies
0
Age
48
XP
4,328
Country
United Kingdom
No, i am flashing via USB via I assume emulated serial. This functionality is built into the trinket m0. The device is fine, it connects and is assigned a COM port. BTW this is the way quantumcross originally did his version and has been working fine for me. I can flash this device NP with other builds, just not with the current code as-is.

When you say take the 1 off the end of the fusee array and length, do you just mean changing "sendPayload(fuseeBin1, FUSEE_BIN_SIZE1);" to "sendPayload(fuseeBin, FUSEE_BIN_SIZE);" for 1-8? If not, could you please specify which line the array and length is referenced? I searched for "array" and "length" there are no matches.

Oh if it being assigned a serial port then of course that's a way. I assumed you was having driver problems with Windows 7 and it wasn't recognising it at all.

Look best thing to do is just hang on until tomorrow until I've sorted it. I been chopping and changing a lot today and I've just had enough today. It's 2:48am here.

I'll be on it in the morning. :)
 
  • Like
Reactions: iriez

mattytrog

You don`t want to listen to anything I say.
OP
Member
Joined
Apr 27, 2018
Messages
3,708
Trophies
0
Age
48
XP
4,328
Country
United Kingdom
No, i am flashing via USB via I assume emulated serial. This functionality is built into the trinket m0. The device is fine, it connects and is assigned a COM port. BTW this is the way quantumcross originally did his version and has been working fine for me. I can flash this device NP with other builds, just not with the current code as-is.

When you say take the 1 off the end of the fusee array and length, do you just mean changing "sendPayload(fuseeBin1, FUSEE_BIN_SIZE1);" to "sendPayload(fuseeBin, FUSEE_BIN_SIZE);" for 1-8? If not, could you please specify which line the array and length is referenced? I searched for "array" and "length" there are no matches.
Source URL added to OP
 

mattytrog

You don`t want to listen to anything I say.
OP
Member
Joined
Apr 27, 2018
Messages
3,708
Trophies
0
Age
48
XP
4,328
Country
United Kingdom
Added alternative 01.s2 to OP that looks for "start.bin" on root of SD card. Just download, and replace your 01.s2 with the new one.

See people? These changes are a lot easier to implement. No messing around with UF2 anymore!
 

Quicksilver88

Well-Known Member
Member
Joined
Jan 26, 2013
Messages
618
Trophies
1
Age
54
XP
753
Country
United States
@mattytrog

Hey thanks for the good work.

Bought one of the RCM_X86 dongles back last month and found your post here thru their Github page. On their page they have a sd_bin_reload1.1.uf2 file. Any idea what V1.1 is as you have a version 1 and version 2 so not sure what they compiled as v1.1? Also they have another file in the dir called x86.load?

Also not sure if you have seen the NS-Atmosphere dongle, it has a payload.bin writing tool (pc) and you just program it with that. Is there anyway you could make build as a payload.bin that could be used with that dongle as well as tegrasmash and other non-dongle injectors?

Again thanks for your clever thinking and work on making it happen.
 

mattytrog

You don`t want to listen to anything I say.
OP
Member
Joined
Apr 27, 2018
Messages
3,708
Trophies
0
Age
48
XP
4,328
Country
United Kingdom
@mattytrog

Hey thanks for the good work.

Bought one of the RCM_X86 dongles back last month and found your post here thru their Github page. On their page they have a sd_bin_reload1.1.uf2 file. Any idea what V1.1 is as you have a version 1 and version 2 so not sure what they compiled as v1.1? Also they have another file in the dir called x86.load?

Also not sure if you have seen the NS-Atmosphere dongle, it has a payload.bin writing tool (pc) and you just program it with that. Is there anyway you could make build as a payload.bin that could be used with that dongle as well as tegrasmash and other non-dongle injectors?

Again thanks for your clever thinking and work on making it happen.
I haven`t got the foggiest. But they all use the same chip. I can make any version. Give it a try. Back up your current "CURRENT.UF2" first.

If you supply me a link to source or even a UF2, should be able to do something with it :)
 

iriez

Well-Known Member
Member
Joined
Oct 27, 2016
Messages
549
Trophies
0
Age
49
Website
www.xbins.org
XP
1,867
Country
United States
Source URL added to OP

I clicked on the trinket download for version 2 and still cannot compile with the same errors. This the DL URL -

https://github.com/mattytrog/GBATEM...tchME/TRINKET_METH123_REBUG_SHAX.zip?raw=true

I checked OP for a note or diff link, didn't see one?

Error -

C:\adafruit\main\test\main\main.ino: In function 'void pushpayload()':

main:253: error: 'fuseeBin1' was not declared in this scope

sendPayload(fuseeBin1, FUSEE_BIN_SIZE1);

Not sure where the corrected main.ino is?
 

mattytrog

You don`t want to listen to anything I say.
OP
Member
Joined
Apr 27, 2018
Messages
3,708
Trophies
0
Age
48
XP
4,328
Country
United Kingdom
I have just downloaded from that exact link... screenshot.png Compiles fine.

Something is wrong in your setup or your IDE.

--------------------- MERGED ---------------------------

You have got ALL the files in there haven`t you?

It seems you have JUST the main.ino

You also need the payload.h and usb_setup.h in the same folder BEFORE YOU EDIT.
 

iriez

Well-Known Member
Member
Joined
Oct 27, 2016
Messages
549
Trophies
0
Age
49
Website
www.xbins.org
XP
1,867
Country
United States
I have just downloaded from that exact link... View attachment 144719 Compiles fine.

Something is wrong in your setup or your IDE.

--------------------- MERGED ---------------------------

You have got ALL the files in there haven`t you?

It seems you have JUST the main.ino

You also need the payload.h and usb_setup.h in the same folder BEFORE YOU EDIT.

I did say in a previous post that I do have all the files in the folder. Yes, I have usb_setup.h and payload.h in the same folder as main.ino.

Unsure what the problem is then. Its super annoying this particular trinket doesn't show up as a trinketboot drive. I much prefer using the UF2 files, arduino can be a pain.
 

mattytrog

You don`t want to listen to anything I say.
OP
Member
Joined
Apr 27, 2018
Messages
3,708
Trophies
0
Age
48
XP
4,328
Country
United Kingdom
I did say in a previous post that I do have all the files in the folder. Yes, I have usb_setup.h and payload.h in the same folder as main.ino.

Unsure what the problem is then. Its super annoying this particular trinket doesn't show up as a trinketboot drive. I much prefer using the UF2 files, arduino can be a pain.
I don`t get it.

If it ennumerates a COM port, the MCU is working...

If you have flashed something to it previously, it should work.

The only thing I can suggest is reflash the bootloader via serial. That has to be your problem.

And regarding it not compiling, it is difficult to diagnose because I have just unzipped and opened main.ino from the unzipped file and compiled again. It went fine.

It is definitely something your end. Ensure the trinket bootloader is on there. It might have inadvertently been left blank (by accident) at the factory.

Try a different Trinket if possible. If you can set up a Teamviewer session, I don`t mind taking a look if you wish.
 

iriez

Well-Known Member
Member
Joined
Oct 27, 2016
Messages
549
Trophies
0
Age
49
Website
www.xbins.org
XP
1,867
Country
United States
I don`t get it.

If it ennumerates a COM port, the MCU is working...

If you have flashed something to it previously, it should work.

The only thing I can suggest is reflash the bootloader via serial. That has to be your problem.

And regarding it not compiling, it is difficult to diagnose because I have just unzipped and opened main.ino from the unzipped file and compiled again. It went fine.

It is definitely something your end. Ensure the trinket bootloader is on there. It might have inadvertently been left blank (by accident) at the factory.

Try a different Trinket if possible. If you can set up a Teamviewer session, I don`t mind taking a look if you wish.


Likely it's an issue with the libraries or with a specific version of the software. Which would explain why it compiles for you and not for me. It has nothing to do with Hardware since it's failing in compilation.

What version is your Arduino, libraries, OS?
 

mattytrog

You don`t want to listen to anything I say.
OP
Member
Joined
Apr 27, 2018
Messages
3,708
Trophies
0
Age
48
XP
4,328
Country
United Kingdom
Likely it's an issue with the libraries or with a specific version of the software. Which would explain why it compiles for you and not for me. It has nothing to do with Hardware since it's failing in compilation.

What version is your Arduino, libraries, OS?

Win10, Arduino 1.8.6
Xubuntu Arduino 1.8.6
 

mattytrog

You don`t want to listen to anything I say.
OP
Member
Joined
Apr 27, 2018
Messages
3,708
Trophies
0
Age
48
XP
4,328
Country
United Kingdom
OK... Made a Hekate version. Just literally 3 lines I`ve changed / added. Credits to Mr. CTCAER as usual for Hekate.

Just added a default launch option - no editing inis or anything.

Launches start.bin. Hold vol- to go to menu.

Anyone want it?
 

Maupiti

Hacking is so « Nice »
Member
Joined
Sep 16, 2018
Messages
1,042
Trophies
0
XP
2,467
Country
France
OK... Made a Hekate version. Just literally 3 lines I`ve changed / added. Credits to Mr. CTCAER as usual for Hekate.

Just added a default launch option - no editing inis or anything.

Launches start.bin. Hold vol- to go to menu.

Anyone want it?
Yep...me too
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    The Real Jdbye @ The Real Jdbye: @Xdqwerty :creep: +1