MemCARDuino - Arduino PlayStation 1 Memory Card reader

Start a work log and update it occasionally with your projects progress
User avatar
CodeAsm
Verified
Active PSXDEV User
Active PSXDEV User
Posts: 69
Joined: Jan 13, 2012
I am a: Programmer, Student
Location: The Netherlands
Contact:

Post by CodeAsm » August 3rd, 2017, 10:15 pm

Well my arduino adapter dint work.. should retry to solder it someday. But Thanks for the awesome PS1Cardlink and an PSone I had, I dumped 6 memorycards (4 official) :D 1 non-official one dint liked to be read, it uses a AT89S4D12-12RC as controller and flash. it reads realy slow and the PSone said it was writing (??) about 1/6 progress. it does have a savedgame on it, the normal memortcard menu can read it. MemcardRex still sais its reading...

another memorycard doesnt respond at all (as if not inserted) (its black with "AR2" writen on it) it uses a PIC16C65B as controller and a 29LE010 as storage (and a 74HC164 as shift register between Pic and flash)
Development Console: SCPH-102, unkown clone Modchip, PAL , FTDI board build into the case (microUSB) for Serial I/O.
Development Computer: GNU/Linux, Arch x86_64 Linux 4.20.3, i7-3632QM [8x3.2GHz], 11,8GiB, 1366x768 GeForce GT 630M (Optimus tech), lots of gig of storage

Meta
Active PSXDEV User
Active PSXDEV User
Posts: 40
Joined: Dec 14, 2015

Post by Meta » August 3rd, 2017, 11:36 pm

Hi:

Can you upload photos?

The PIC16C65B is no longer sold. Microchip makes clear that this is its substitute or recommendable. (PIC16F724).

DataSheet:
AT89S4D12-12RC
29LE010
74HC164
;)

User avatar
CodeAsm
Verified
Active PSXDEV User
Active PSXDEV User
Posts: 69
Joined: Jan 13, 2012
I am a: Programmer, Student
Location: The Netherlands
Contact:

Post by CodeAsm » August 4th, 2017, 6:40 pm

Files are too big,
ive uploaded them here, if the site ever decides to shut it down, ill reup them somewhere else:
http://imgur.com/a/Duxc6
Development Console: SCPH-102, unkown clone Modchip, PAL , FTDI board build into the case (microUSB) for Serial I/O.
Development Computer: GNU/Linux, Arch x86_64 Linux 4.20.3, i7-3632QM [8x3.2GHz], 11,8GiB, 1366x768 GeForce GT 630M (Optimus tech), lots of gig of storage

Meta
Active PSXDEV User
Active PSXDEV User
Posts: 40
Joined: Dec 14, 2015

Post by Meta » August 5th, 2017, 1:08 am

Hello:

In this image using a PIC. Is it a Sony Original Memory Card?

I am going to disarm all the Memory Card I have to know your IC.

Maybe if I get the scheme I make myself a Memory Card. It is very difficult because you have to know how it behaves to program the PIC.

Thanks for the info.

User avatar
CodeAsm
Verified
Active PSXDEV User
Active PSXDEV User
Posts: 69
Joined: Jan 13, 2012
I am a: Programmer, Student
Location: The Netherlands
Contact:

Post by CodeAsm » August 5th, 2017, 1:44 am

@Meta, No these 2 in the photoalbum are both unofficial clones, there are images of official and licensed card out there and your best gues is to look at the pinout and (SPI?) protocol used in the PS1 itself and implement it in your choice of MCU.
for best compatibility I gues you should try to make it run on the 3.6(?) volt line only (just like these 2 clones I have)

I pictured these two unofficial ones for reverence to make them supported with the memCardDuino but also for you for instance, to see how they solved some problems. they are NOT official and probably not the best source of how to do it.
Image
Here you can see a Yaroze card (left) and a "normal" older memorycard on the right, both official. (not my picture).
as you see they used a MCU for the talking and a LV010 1Mbit storage flash ic in case of the memorycard (the same pcb for the yaroze card, but the MCU response diferently.
Development Console: SCPH-102, unkown clone Modchip, PAL , FTDI board build into the case (microUSB) for Serial I/O.
Development Computer: GNU/Linux, Arch x86_64 Linux 4.20.3, i7-3632QM [8x3.2GHz], 11,8GiB, 1366x768 GeForce GT 630M (Optimus tech), lots of gig of storage

Meta
Active PSXDEV User
Active PSXDEV User
Posts: 40
Joined: Dec 14, 2015

Post by Meta » August 5th, 2017, 2:43 am

Hello:

Here the data sheet of the AT29LV010A. Atmel bought it from Microchip.

The good thing is to have the electrical scheme of the official Memory Card from Sony to make my own card and be able to record the data in a Micro-SD or a higher capacity EEPROM.

It's like having 15 Memory Cards in the same package.

http://moberg-dybdal.dk/psxge/

Greetings.

User avatar
CodeAsm
Verified
Active PSXDEV User
Active PSXDEV User
Posts: 69
Joined: Jan 13, 2012
I am a: Programmer, Student
Location: The Netherlands
Contact:

Post by CodeAsm » August 5th, 2017, 7:17 am

Im afraid we are derailing here litle bit.
But whats the website about in context with your post? and a 29LV010 is just a 1Mbit flash organized as 128x8 and only runs at 3volts... wich is fine, even if its another brand with the same specs. and I think you dont even need it if your gonna use a MCU that has enough RAM to store a temporarely MU and read write it to on a SD card. any mcu that can run on 3,6volts or bit lower could do the job given enough program storage, pins for interfacing and your programming equipement.

see, the thirdparty that took the AT89S4D12 where smart, this mcu has enough internal storage for the memorycard and they can program the PS1 memorycard protocol in the mcu to access it. maybe some arduino like atmel can do the same, or an STM32 :D (those are cheap, and probably overkill).
Development Console: SCPH-102, unkown clone Modchip, PAL , FTDI board build into the case (microUSB) for Serial I/O.
Development Computer: GNU/Linux, Arch x86_64 Linux 4.20.3, i7-3632QM [8x3.2GHz], 11,8GiB, 1366x768 GeForce GT 630M (Optimus tech), lots of gig of storage

Meta
Active PSXDEV User
Active PSXDEV User
Posts: 40
Joined: Dec 14, 2015

Post by Meta » August 5th, 2017, 8:32 am

Hello:

Do you know the communication protocol to make a home memory card?

Make a homemade Memory Card without using the official one.

Image

No problem with working with 3.6V. The CD4050 transforms from 5V to 3.3V.

Greetings.

User avatar
CodeAsm
Verified
Active PSXDEV User
Active PSXDEV User
Posts: 69
Joined: Jan 13, 2012
I am a: Programmer, Student
Location: The Netherlands
Contact:

Post by CodeAsm » August 7th, 2017, 7:12 am

tried the AT89S4D12-12RC again today, 80% and then it started "writing" again (aka, stuck, not reading ) so maybe the PS1CardLink has some timeout or my card responds weirdly at some time?..

@Meta, its somewhat like SPI, look at the sources Shendo shared to what you can adapt your SPI code to.
https://github.com/ShendoXT/memcarduino ... RDuino.ino

You talk about a Hex Non-Inverting Buffer, but picture of a Hex Inverting Buffer. I think I know what you mean, you wanna double invert the lines but from 5v to 3.3v and back. an Hex Non-Inverting Buffer indeed seems correct, a CD4049. thats all nice, but why not choose a mcu thats already running at 3.3?
The ATmega328p can even run at 3.3v.
Development Console: SCPH-102, unkown clone Modchip, PAL , FTDI board build into the case (microUSB) for Serial I/O.
Development Computer: GNU/Linux, Arch x86_64 Linux 4.20.3, i7-3632QM [8x3.2GHz], 11,8GiB, 1366x768 GeForce GT 630M (Optimus tech), lots of gig of storage

Meta
Active PSXDEV User
Active PSXDEV User
Posts: 40
Joined: Dec 14, 2015

Post by Meta » August 7th, 2017, 6:32 pm

Hello:

What of the CD4050 or CD4049 is in case you have no choice. If the MCU or microcontroller works directly at 3.3V, the better.

Can you make an unofficial Memory Card using Arduino and Micro-SD?
Image

Image

Greetings.

User avatar
CodeAsm
Verified
Active PSXDEV User
Active PSXDEV User
Posts: 69
Joined: Jan 13, 2012
I am a: Programmer, Student
Location: The Netherlands
Contact:

Post by CodeAsm » August 9th, 2017, 2:31 am

Im not sure what mods or the original thread starter think but I suggest you start your own thread.
Yes those look good, and you could hook the ps1 on the same bus or bitbang SPI from other pins. (the PS1 SPI bus was running on a low speed tho, so not the same bus im afraid)
and your right if the voltages levels arent 3.3, an conversion might be nececairy. But there are diferent methods to accomplish this or even building your own memorycard ;)
Development Console: SCPH-102, unkown clone Modchip, PAL , FTDI board build into the case (microUSB) for Serial I/O.
Development Computer: GNU/Linux, Arch x86_64 Linux 4.20.3, i7-3632QM [8x3.2GHz], 11,8GiB, 1366x768 GeForce GT 630M (Optimus tech), lots of gig of storage

soulgriever
Interested PSXDEV User
Interested PSXDEV User
Posts: 5
Joined: Sep 11, 2017

Post by soulgriever » September 11th, 2017, 3:17 am

2 quick novice questions

1. Is it possible to use this on a raspberry pi and if so will memcardrex work on the pi?

2. Is it possible to use this for both memory cards and controllers on a single chip?

Put a raspberry pi inside of a ps1 shell and would love to retain as much original functionality as possible

likeabaus
Extreme PSXDEV User
Extreme PSXDEV User
Posts: 133
Joined: Jul 27, 2016

Post by likeabaus » September 11th, 2017, 4:14 am

My best guess would be that this would need to be recompiled to run on a pi (as far as I know there's only an arduino version). It might not be as simple as that though, it might need to be manually ported over the hard way, I have no idea....

soulgriever
Interested PSXDEV User
Interested PSXDEV User
Posts: 5
Joined: Sep 11, 2017

Post by soulgriever » September 11th, 2017, 7:05 am

Sorry should have clarified, I meant I would like to use a atmega328 nano for both controllers and memory cards plugged into my Pi via usb

User avatar
Shendo
Verified
C Programming Expert
C Programming Expert
Posts: 250
Joined: Mar 21, 2012
I am a: Programmer
Motto: Never settle
PlayStation Model: SCPH-7502
Discord: ShendoXT
Location: Croatia, EU

Post by Shendo » September 11th, 2017, 9:51 pm

Hi Soulgriever, interesting project (I googled your username and found the thread on retropie forums).

For controllers I believe you are already covered with GPIOs with the gamecon_gpio_rpi kernel module.
It supports many controllers including PS1 controllers (up to 4 at the same time). Link.

For memory card, yes you can use memcarduino with arduino board and hook it up to the memcard slot.

MemcardRex is a.net application and it works fine with mono on linux and macOS.
I'm not sure about raspberry pi but if mono works then I suppose it should work with MemcardRex, you'll have to try it.

If it's not working then you can use a python script from here for downloading/uploading .mcr files to your memory card.

Also make sure to remove PCB from the ports and wire everything manually, in the setup I proposed
controllers and memory card should't be connected together (which they are on a real ps1).


@CodeAsm: Glad to see that PS1CardLink came to rescue but I'm interested
in what went wrong with memcarduino. Did you get any errors or was it stuck reading/writing?


@Meta: pssst, don't tell anyone but I'm working on the thing you are trying to do.
Won't use atmega though but a different mcu.
Dev console: SCPH-7502, FreePSXBoot, CH340 serial cable.

Meta
Active PSXDEV User
Active PSXDEV User
Posts: 40
Joined: Dec 14, 2015

Post by Meta » September 12th, 2017, 10:04 am

@Shendo If you're doing what I want to do, you can do it with Arduino, Raspberry Pi and a simple PIC.

It is good that you make the project that everyone has access to the most common components near your home. No FPGA. I know you were with Android. ;)

Let me know when you finish the project.

soulgriever
Interested PSXDEV User
Interested PSXDEV User
Posts: 5
Joined: Sep 11, 2017

Post by soulgriever » September 19th, 2017, 2:48 pm

@Shendo Awesome thanks. I tried to use the gpio headers and had no luck, but plugged my adapter back up and it magically started working?(probably user error the first time)

I just received a Arduino in the mail today and plan to test it tommorow. Is it possible to connect both ps1 memory cards to a single Arduino Nano or will I have to get a nano for each memory card.

Also Im going to use a 3.3K and 9.1K resistor for my divider which should take me to 3.67 do you think that's close enough?
Shendo wrote: Also make sure to remove PCB from the ports and wire everything manually, in the setup I proposed
controllers and memory card should't be connected together (which they are on a real ps1).
I used a utility knife to cut the traces and plan to solder individually, left the pcb in place as it reinforces the port.

Meta
Active PSXDEV User
Active PSXDEV User
Posts: 40
Joined: Dec 14, 2015

Post by Meta » September 21st, 2017, 1:02 am

Hello:

If you want to control two Memory Cards with Arduino, you can prepare it. You gave me that idea, you can do it and I add an LCD display.

- Creates two slots on the Memory Card in parallel.
- The power card of the Memory Card GND, mass or negative (-) only Arduino activates in one card, the other one deactivates it.
- With a button from Arduino, also in the Visual Studio interface if you program it, change Memory Card, while MC1 is activated and MC2 is disabled, you make the switch contractio, deactivate the MC1 and activate the gorund of MC2.
- It is a way to combine Memory Card to select it.

Greetings.

User avatar
Shendo
Verified
C Programming Expert
C Programming Expert
Posts: 250
Joined: Mar 21, 2012
I am a: Programmer
Motto: Never settle
PlayStation Model: SCPH-7502
Discord: ShendoXT
Location: Croatia, EU

Post by Shendo » September 22nd, 2017, 1:19 am

@Soulgriever: Yes it's possible but there is no support for it in the software (yet).
As for power supply check out this post.

@Meta: No need to disconnect power supply. Each SPI device already has SS (slave select) line for that purpose.
So each card needs to be activated (by pulling the line low) when it's being read from/written to.

Each free pin that is left on Arduino can be used to attach yet another card to device.
Dev console: SCPH-7502, FreePSXBoot, CH340 serial cable.

Meta
Active PSXDEV User
Active PSXDEV User
Posts: 40
Joined: Dec 14, 2015

Post by Meta » September 24th, 2017, 6:10 pm

You do not have to feed several cards at the same time, you only activate one in the power supply and the other ones are deactivated so you do not have to spend energy consumption unnecessarily.

SPI is something else and I did not mean this.

Post Reply

Who is online

Users browsing this forum: No registered users and 4 guests