Create your own CD-Player around a CDM2

Another idea grow in my mind for a while… the plan to re-develop the faulty uProc board with the microcontrollers of the tape deck and CD-Player.

I successfully replaced the tape MCU and added a better error handling and more features but always thought to use the MCU of the CD-Player as it is. However, there are a couple of feature I miss in the current firmware. Like to display the remaining time of a track or to shuffle the tracks for playback.

The service manuals point out a I2C bus is used for the communication with the CDM2 Servo. The MCU on the CMD2 Servo is a MAB8441P/T012 and, as far as I have seen, also gets used in some CDM4. The uProc panel of the CD555 contains a MAB8441-TC18 which is of course the same MCU but with a different firmware. A couple of months later I have seen Philips combined more functions into one MCU, like handling of the Servo and decoder.

The idea was to hack into the I2C bus and to analyse the communicating between those MCUs. Since only the Servo MCU is important I used a Philips CD150 as it is easier to handle on the desk. To get the content of the I2C bus I used my breakout board of a ATmega 1284P and a sniffer – there are plenty of sources available in the net. In generell, the ATmega 1284P is also used in Ardunios and therefore there are a lot of libraries available. I did not want to make life harder as it is, that’s why I am using this 8-Bit MPU. Another requirement was the existence of a DIP case since does not only looks identical as the used MCUs but they are easier to handle on a board when you need to solder or replace them.

First I used my Oscilloscope to check the content of the I2C bus. Philips invented this serial bus for internal communication between components for TVs. I was not sure if there were any changes in the I2C standard (except for the speed) in the last 40 years which might prevent to connect modern devices. That would have made the communication a little bit more complex. Luckily there are no changes and the I2C data can be extracted from both MCUs.

It took me some time to figure out the required data to control a CDM2 but I finally came up with a full working feature set. At least the features used and provided by a CD150. After sending the initialising command the TOC got loaded and it took a while to identify the parameters. At the end it was quite simple since minutes and seconds got provided and it was not necessary to calculate them from frames or sectors. Although the content of some parameters are still unknown it is possible to display the correct TOC.

 

A little bit of a challenge was the fact that the CDM2 Servo MCU required a checksum of the received data. Since the information consists of only three bytes is was quite easy and took about 15 minutes to figure out how the checksum gets calculated. With a wrong checksum the CDM2 would have ignored the command. Until know I was not able to figure out if the CDM2 includes a checksum when it sends data. I think so but I was not able to figure out the math behind. There might be no checksum at all and I am hunting a dead horse. 

 

 

After developing a CD Player with standard functions it was time to add some nice features which the CD555 was not able to deliver. One new feature got added like to show the remaining time. During playback the MCU of the servo returns minutes and seconds, therefore this feature was quite easy to implement based on the known TOC.

After developing a CD Player with standard functions it was time to add some nice features which the CD555 was not able to deliver. One new feature got added like to show the remaining time. During playback the MCU of the servo returns minutes and seconds, therefore this feature was quite easy to implement based on the known TOC.

 

To shuffle through the CD we just need to create a randomised playlist of all tracks. When I bought a new CD I liked another feature called “Intro” which plays each track of your new bargain for 10 or 15 seconds. Another boring thing was to every time create the same playlist when you want to listen to your favourite tracks. CD Player from the late 80s got a feature called FTS – Feature Track Selection. It was possible to store a playlist and to load it. I never had this feature on any of my devices therefore the exact process was not clear for me. I saw stickers you can put on your AudioCD with a number referring to the FTS program which you have to load playback.

This revealed another problem – there are only a limited number of buttons available and I have no itention to add any others. Same is valid for the LCD display. The driver can handle 31 bits – with four 7-segment elements for displaying track and index you can imagine there are no major other options available. The LCD of the CD555 can also display: Error, Time and Repeat. This fact requires a little bit of thinking how to optimise the user interface to overcome such issues.

I decided to calculate a disc id based on the contents of the TOC to identify an AudioCD and to load there FTS programs automatically when the disc gets inserted. We will see if they are unique enough. Philips used an EEPROMs to store playlists up to 20 tracks. The ATmega 1284P has a build in 4kB of EEPROM which is a little bit odd. Philips CD Players used a 16kB EEPROM to store the information. I had only 64kB EEPROMs at home with 32 Bytes per page. Finally I am using 4 Bytes for the disc id and 27 Bytes for the playlist whilst the lowest byte contains the length of the playlist. Well, it is not really necessary to store the length of the playlist since 0x00 values could be used for a not assigned track and with some calculate the length could have been calculated. However, it is still possible to store more than the usual 20 tracks and life is getting a little bit easier with having the length of the playlist at hand.

Before I used a LCD display and keypad but later on replaced them with the LCD and keypad from the CD555. I publish the source code when it has a “little bit” more structure…

 

Standard features of the CDM2 Servo:

  • Init
  • Play
  • Stop
  • Pause
  • Next
  • Prior
  • Rapid Search Forwards/Backwards
  • Service Mode 0-3 (need to be done)

 

Standard features rebuild 1:1:

  • Jump between tracks (2 seconds)
  • Press on play during playback restarts the playback of the track
  • Create a program (26 tracks instead of 20 tracks)

 

Added features:

  • Show remaining time of a track
  • Shuffle playback
  • Intro – play each track for about 15 seconds
  • FTS – store a preferred playlist

Leave a Reply

Your email address will not be published. Required fields are marked *