kalymos / PsNee

PsNee, an open source stealth modchip for the Sony Playstation 1
492 stars 71 forks source link

RPi Pico support? #40

Closed xslendix closed 2 months ago

xslendix commented 1 year ago

Those are some really cheap microcontrollers, and are easy to come by. I think having support for those would be quite cool.

VoxelTek commented 1 year ago

I agree, and I'm trying to port the code to it now. I literally have not tested this code and am not an Arduino or PS1 security guru by any means, but I figure I might as well give it a shot.

https://github.com/VoxelTek/PicoNee

kalymos commented 1 year ago

Good initiative, here I will keep the code for attiny and attmega. Tell me when the code will be functional I will put a link.

Le ven. 28 avr. 2023 à 01:06, VoxelTek @.***> a écrit :

I agree, and I'm trying to port the code to it now. I literally have not tested this code and am not an Arduino or PS1 security guru by any means, but I figure I might as well give it a shot.

https://github.com/VoxelTek/PicoNee

— Reply to this email directly, view it on GitHub https://github.com/kalymos/PsNee/issues/40#issuecomment-1526706038, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABDOKBGKLER3PDTPPWWAGPLXDL3WVANCNFSM6AAAAAAUJWXMDA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

remoitrix commented 1 year ago

Hi! I compiled the code and show this errors;

In file included from C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\variants\SEEED_XIAO_RP2040/pinmode_arduino.h:30:0, from C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/Arduino.h:26, from C:\Users\thesp\AppData\Local\Temp\arduino\sketches\05397FCBE827B03C5F7D492FE9E31C1C\sketch\sketch_jun14a.ino.cpp:1: C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino: In function 'void inject_SCEX(char)': C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:103:24: error: 'PINB' was not declared in this scope

define GATEWFCKPORT PINB // MCU port for the gate input (used for WFCK)

                    ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:67:32: note: in definition of macro 'bitClear'

define bitClear(value, bit) ((value) &= ~(1UL << (bit)))

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:174:16: note: in expansion of macro 'GATEWFCKPORT' bitClear(GATEWFCKPORT, DATABIT); // data low ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:103:24: note: suggested alternative: 'SING'

define GATEWFCKPORT PINB // MCU port for the gate input (used for WFCK)

                    ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:67:32: note: in definition of macro 'bitClear'

define bitClear(value, bit) ((value) &= ~(1UL << (bit)))

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:174:16: note: in expansion of macro 'GATEWFCKPORT' bitClear(GATEWFCKPORT, DATABIT); // data low ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:103:24: error: 'PINB' was not declared in this scope

define GATEWFCKPORT PINB // MCU port for the gate input (used for WFCK)

                    ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:65:32: note: in definition of macro 'bitRead'

define bitRead(value, bit) (((value) >> (bit)) & 0x01)

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:183:38: note: in expansion of macro 'GATEWFCKPORT' bool wfck_sample = bitRead(GATEWFCKPORT, GATEWFCKBIT); ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:103:24: note: suggested alternative: 'SING'

define GATEWFCKPORT PINB // MCU port for the gate input (used for WFCK)

                    ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:65:32: note: in definition of macro 'bitRead'

define bitRead(value, bit) (((value) >> (bit)) & 0x01)

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:183:38: note: in expansion of macro 'GATEWFCKPORT' bool wfck_sample = bitRead(GATEWFCKPORT, GATEWFCKBIT); ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:104:20: error: 'PORTB' was not declared in this scope

define DATAPORT PORTB // MCU port for the gate input (used for WFCK)

                ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:66:30: note: in definition of macro 'bitSet'

define bitSet(value, bit) ((value) |= (1UL << (bit)))

                          ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:184:11: note: in expansion of macro 'bitWrite' bitWrite(DATAPORT, DATABIT, wfck_sample); // output wfck signal on data pin ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:184:20: note: in expansion of macro 'DATAPORT' bitWrite(DATAPORT, DATABIT, wfck_sample); // output wfck signal on data pin ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:103:24: error: 'PINB' was not declared in this scope

define GATEWFCKPORT PINB // MCU port for the gate input (used for WFCK)

                    ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:67:32: note: in definition of macro 'bitClear'

define bitClear(value, bit) ((value) &= ~(1UL << (bit)))

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:196:12: note: in expansion of macro 'GATEWFCKPORT' bitClear(GATEWFCKPORT, DATABIT); // pull data low ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:103:24: note: suggested alternative: 'SING'

define GATEWFCKPORT PINB // MCU port for the gate input (used for WFCK)

                    ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:67:32: note: in definition of macro 'bitClear'

define bitClear(value, bit) ((value) &= ~(1UL << (bit)))

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:196:12: note: in expansion of macro 'GATEWFCKPORT' bitClear(GATEWFCKPORT, DATABIT); // pull data low ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino: In function 'void setup()': C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:296:3: error: 'ADCSRA' was not declared in this scope ADCSRA = ADCSRA & B01111111; ^~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:296:3: note: suggested alternative: 'ADC0' ADCSRA = ADCSRA & B01111111; ^~ ADC0 C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:298:3: error: 'ACSR' was not declared in this scope ACSR = B10000000; ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:300:3: error: 'DIDR0' was not declared in this scope DIDR0 = DIDR0 | B00111111; ^~~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:300:3: note: suggested alternative: 'DIR' DIDR0 = DIDR0 | B00111111; ^~~~~ DIR In file included from C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\variants\SEEED_XIAO_RP2040/pinmode_arduino.h:30:0, from C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/Arduino.h:26, from C:\Users\thesp\AppData\Local\Temp\arduino\sketches\05397FCBE827B03C5F7D492FE9E31C1C\sketch\sketch_jun14a.ino.cpp:1: C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino: In function 'void loop()': C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:100:20: error: 'PIND' was not declared in this scope

define SUBQPORT PIND // 1MCU port for the 2 SUBQ sampling inputs

                ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:65:32: note: in definition of macro 'bitRead'

define bitRead(value, bit) (((value) >> (bit)) & 0x01)

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:326:20: note: in expansion of macro 'SUBQPORT' while (bitRead(SUBQPORT, SQCKBIT) == 1) { ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:100:20: note: suggested alternative: 'PIN_D5'

define SUBQPORT PIND // 1MCU port for the 2 SUBQ sampling inputs

                ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:65:32: note: in definition of macro 'bitRead'

define bitRead(value, bit) (((value) >> (bit)) & 0x01)

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:326:20: note: in expansion of macro 'SUBQPORT' while (bitRead(SUBQPORT, SQCKBIT) == 1) { ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:100:20: error: 'PIND' was not declared in this scope

define SUBQPORT PIND // 1MCU port for the 2 SUBQ sampling inputs

                ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:65:32: note: in definition of macro 'bitRead'

define bitRead(value, bit) (((value) >> (bit)) & 0x01)

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:339:21: note: in expansion of macro 'SUBQPORT' while ((bitRead(SUBQPORT, SQCKBIT)) == 0); ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:100:20: note: suggested alternative: 'PIN_D5'

define SUBQPORT PIND // 1MCU port for the 2 SUBQ sampling inputs

                ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:65:32: note: in definition of macro 'bitRead'

define bitRead(value, bit) (((value) >> (bit)) & 0x01)

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:339:21: note: in expansion of macro 'SUBQPORT' while ((bitRead(SUBQPORT, SQCKBIT)) == 0); ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:100:20: error: 'PIND' was not declared in this scope

define SUBQPORT PIND // 1MCU port for the 2 SUBQ sampling inputs

                ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:65:32: note: in definition of macro 'bitRead'

define bitRead(value, bit) (((value) >> (bit)) & 0x01)

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:341:22: note: in expansion of macro 'SUBQPORT' sample = bitRead(SUBQPORT, SUBQBIT); ^~~~ C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:100:20: note: suggested alternative: 'PIN_D5'

define SUBQPORT PIND // 1MCU port for the 2 SUBQ sampling inputs

                ^

C:\Users\thesp\AppData\Local\Arduino15\packages\Seeeduino\hardware\rp2040\2.7.2\cores\arduino/api/Common.h:65:32: note: in definition of macro 'bitRead'

define bitRead(value, bit) (((value) >> (bit)) & 0x01)

                            ^~~~~

C:\Users\thesp\Desktop\mods\psone hard-softmod\Mod cambio Bios\PsNee-7.01\PsNee-7.01\test\sketch_jun14a\sketch_jun14a.ino:341:22: note: in expansion of macro 'SUBQPORT' sample = bitRead(SUBQPORT, SUBQBIT); ^~~~

exit status 1

Compilation error: 'PINB' was not declared in this scope

VoxelTek commented 1 year ago

Yeah, at the moment, the whole thing is on hold. I'm pretty busy, and I might get around to this again, but right atm, it's not getting any progress. Sorry.

remoitrix commented 1 year ago

Don´t worry. At this moment you are the only who try to adapt the mod to ours RPi Pico. I hope can be done. Thanks

dazzaXx commented 8 months ago

Is there any update on the ported pi version? I have a bunch of Picos and RP2040 Zeros that I would love to use with it.

remoitrix commented 8 months ago

Nothing yet. I think that is a forgiven project.

VoxelTek commented 8 months ago

Unfortunately, I didn't have the necessary hardware in order to test my code and such. I was unable to even get the original PSNee working, and as such testing and debugging my code is somewhat out of my reach.

Apologies to everyone involved, feel free to take over the project if you'd like to help continue my work.

dazzaXx commented 8 months ago

No worries, I did try to also compile kalymos's version of PicoNee and noticed some defines were apart of some sort of port manipulation being used, and because we try to compile for rp2040 boards, the code for them doesnt include this I assume, thats why it errors on PINB, PORTB, etc.

I'm no coder, but this is as far as I could get with figuring out why it doesnt like to compile.