Hybrid SID Player

A place to document your own projects.

Re: Hybrid SID Player

Postby bluehash » Fri Nov 11, 2011 11:16 am

Could I ask what font is being used for the OLED?
bluehash
Newbie
Newbie
 
Posts: 5
Joined: Fri Jun 17, 2011 7:13 am

Re: Hybrid SID Player

Postby Markus Gritsch » Fri Nov 11, 2011 2:05 pm

Yes you could :) But you could also download the firmware archive and look into the 'oled' folder. There you would find a file named 'tahomabd.h', which holds the bitmaps of Tahoma bold, 11 pixel in size. I generated the pixel data with some Python script which parsed an image containing all glyphs of the windows-1252 encoding. The font is used with proportional spacing, which is much nicer looking than the fixed-width fonts found everywhere.

The same directory also contains a file named 'oled.c' which contains the routines to draw a text string at an arbitrary x,y position into the off-screen frame buffer. The positioning is really arbitrary, as is demonstrated for example here [1]. The byte twiddling is a bit involved, but not too difficult to understand. The API could have been a bit cleaner, I suppose.

Hope that helped you, for the rest you should really take a look into the source code. It's all there.

[1] http://www.youtube.com/watch?v=xbbnZvbWwqU
User avatar
Markus Gritsch
Sr. Member
Sr. Member
 
Posts: 297
Joined: Tue Feb 09, 2010 6:54 am

Re: Hybrid SID Player

Postby bluehash » Fri Nov 11, 2011 2:12 pm

Thanks Markus.
bluehash
Newbie
Newbie
 
Posts: 5
Joined: Fri Jun 17, 2011 7:13 am

Re: Hybrid SID Player

Postby Markus Gritsch » Tue Jan 24, 2012 2:32 am

I found a LiPo battery, which matches quite nicely into the empty space beneath the heat sinks, so I mounted some acrylic glass to my player to hold everything together. One full charge lasts for about 2.5 hours of mobile music playing. I also added some code to monitor the battery voltage to have an indicator for how much power is left.
Attachments
firmware_2012-01-17.zip
(359.69 KiB) Downloaded 351 times
IMG_6355.JPG
IMG_6357.JPG
IMG_6364.JPG
IMG_6385.JPG
User avatar
Markus Gritsch
Sr. Member
Sr. Member
 
Posts: 297
Joined: Tue Feb 09, 2010 6:54 am

Re: Hybrid SID Player

Postby Markus Gritsch » Tue Mar 06, 2012 4:44 am

The CUI32Stem board is now available form SeeedStudio: http://www.seeedstudio.com/depot/cui32stem-p-1100.html
Attachments
CUI32StemFront.jpg
User avatar
Markus Gritsch
Sr. Member
Sr. Member
 
Posts: 297
Joined: Tue Feb 09, 2010 6:54 am

Re: Hybrid SID Player

Postby Markus Gritsch » Thu Jun 14, 2012 3:09 pm

Hi,

when using HybridSID in stand-alone mode, the TinySID library is used to emulate the C64 CPU and drive the real SID chip. The problem is, this library can only handle tunes in PSID format. Since HVSC #50, digi-tunes have been converted to the newer RSID format, and some new tunes are also released in RSID format, without any PSID version at all.

After adding the alternative 'Network SID Device' firmware [1], it is possible to play those tunes while having the HybridSID device being connected to the PC by using 'ACID 64'.

Wilfred Bos, the author of ACID 64, tipped me to his ACID 64 DLL library, which can be used to load SID tunes and obtain the SID register values together with the appropriate time stamps of the SID register writes. So I wrote a Python script to convert all my RSID tunes to some custom dump format and added support to the regular HybridSID firmware so that it can stream those .dmp files to the SID, cycle exact, and without being connected to a PC.

Please find the firmware with added .dmp support attached. The Python script to convert SID tunes to .dmp format is also included. Before using the script, the file 'HVSC\C64Music\DOCUMENTS\Songlengths.txt' must be copied into the 'acid64_library_v136' folder.

A video is available here: http://youtu.be/BqSh8N5aNfI

Have fun,
Markus

[1] viewtopic.php?f=56&t=2197&start=15#p24515
Attachments
firmware_2013-03-22.zip
(466.83 KiB) Downloaded 276 times
firmware_2012-05-16.zip
(479.01 KiB) Downloaded 324 times
Last edited by Markus Gritsch on Fri Mar 22, 2013 9:42 am, edited 1 time in total.
User avatar
Markus Gritsch
Sr. Member
Sr. Member
 
Posts: 297
Joined: Tue Feb 09, 2010 6:54 am

Re: Hybrid SID Player

Postby bl4rk » Wed Sep 05, 2012 9:14 pm

I am in awe. This is amazing and inspirational! Good work.

I just got 3 C64s with intact SID chips. I have yet to test them, but I have high hopes they will work. I'd love to make one of these and will probably be back with some questions!

Now off to Seeedstudio to buy one of those CUI32Stems :)

Blark
bl4rk
Newbie
Newbie
 
Posts: 18
Joined: Wed Aug 22, 2012 10:30 am

Re: Hybrid SID Player

Postby datalex » Fri Feb 28, 2014 1:58 am

Hi! Marcus you have done EXCELLENT work with 6502 & CIA emulation my friend!
I was looking for ages for a cheap diy native 6581 player!
I start designing a PCB Shield from your schematic. I will let you know if/when I finished my/your project!

Cheers!

Alexandros
GREECE
a.k.a DAT-alex
datalex
Newbie
Newbie
 
Posts: 1
Joined: Fri Feb 28, 2014 1:45 am

Re: Hybrid SID Player

Postby Zytryx » Fri Dec 19, 2014 8:39 pm

I've been trying to build this and while I am good with older electronics, I seem to always fail at the newer microcontrollers. I've tried flashing the firmware but keep getting this error:

ERROR: address 0x1fc03000 out of range at line 32778

Ideas?

I'm using the Seeedstudio board, do I need to flash this with a pickit?

I tried the simple sid.hex firmware, it flashes but then stays in bootloader mode.
Zytryx
Newbie
Newbie
 
Posts: 5
Joined: Fri Dec 19, 2014 8:35 pm

Re: Hybrid SID Player

Postby Markus Gritsch » Sat Dec 20, 2014 2:40 am

I used MPLAB IDE and a PICkit 3. Unfortunately I don't have any idea what might be wrong with your setup.
User avatar
Markus Gritsch
Sr. Member
Sr. Member
 
Posts: 297
Joined: Tue Feb 09, 2010 6:54 am

Re: Hybrid SID Player

Postby Zytryx » Sat Dec 20, 2014 12:32 pm

Ok I think it's the stock bootloader getting in the way, Just ordered a Pickit 3, time to ditch the Pickit 2.
Zytryx
Newbie
Newbie
 
Posts: 5
Joined: Fri Dec 19, 2014 8:35 pm

Re: Hybrid SID Player

Postby Zytryx » Mon Dec 22, 2014 9:06 pm

One more question, I have the screen, which I think should work, but it's labeled different then yours

http://smart-prototyping.com/OLED-0.96i ... -blue.html

Can't seem to get it working, seems to need a reset line.
Zytryx
Newbie
Newbie
 
Posts: 5
Joined: Fri Dec 19, 2014 8:35 pm

Re: Hybrid SID Player

Postby Markus Gritsch » Tue Dec 23, 2014 4:32 am

Zytryx wrote:Can't seem to get it working, seems to need a reset line.


I permanently tied the reset line to its non-active state -- I cannot remember if it's active-low or active-high.

Just to verify, that the display isn't broken, can you get it working with some arduino code? Here I had it connected to a Teensy:
https://www.youtube.com/watch?v=xbbnZvbWwqU
https://www.youtube.com/watch?v=u_rdroWi2ho
The links to the source code can be found in the video description.

If you have a Bus Pirate, here I wrote a quick Python script to driver it:
https://www.youtube.com/watch?v=IW9tv4I_nFg
https://www.youtube.com/watch?v=W0LWcp4OUJQ
Links again in the video description.

Hope this helps.
User avatar
Markus Gritsch
Sr. Member
Sr. Member
 
Posts: 297
Joined: Tue Feb 09, 2010 6:54 am

Re: Hybrid SID Player

Postby Zytryx » Tue Dec 23, 2014 11:45 am

Already tried it with an arduino, so I know it works. Was just trying to hook the screen up alone to make sure I have the firmware up and running, loaded it with a Pickit now, verified OK.
Zytryx
Newbie
Newbie
 
Posts: 5
Joined: Fri Dec 19, 2014 8:35 pm

Re: Hybrid SID Player

Postby Zytryx » Tue Dec 23, 2014 12:10 pm

I have DO to RG6, DI to RG8, DC to RF5, CS to RG9, Tried both low and high reset.
Zytryx
Newbie
Newbie
 
Posts: 5
Joined: Fri Dec 19, 2014 8:35 pm

PreviousNext

Return to Project logs