Shop OBEX P1 Docs P2 Docs Learn Events
Converting Hydra video drivers for Demoboard — Parallax Forums

Converting Hydra video drivers for Demoboard

localrogerlocalroger Posts: 3,452
edited 2009-04-01 13:44 in Propeller 1
Greetings everyone -- Prop N00b here, trying to do something useful while teaching myself Spin. I have rewritten PropDOS from the ground up, ditching the music functions but providing much better command parsing and functions for exploring the SD card. I would like to clean this up and release it to the obex on the MIT license. I'll also be doing this with my next project, which is a file system that can *gasp* access more than one file at a time.

My problem is that the aigeneric TV driver which propDOS uses isn't MIT licensed. I've converted to the tv_terminal driver, but that provides only 13 lines on screen. All of the 24 line drivers on the obex are written for the Hydra, and I am going quietly mad trying to get one of them to run on my demoboard. The Parallax drivers and aigeneric seem to have code to just take the lowest video pin as an argument and do the setup, but all of the obex 24-line drivers just say "edit the pasm." OK I've edited the pasm and I can't get any of the blasted things (or any of the other drivers that seem to be based on SimpleNTSC) to display video.

Original lines I know I need to change:

Hydra video is on the low nibble of the pin group at 24, demoboard on the high nibble at 12, so

movs vcfg, #%0000_0111 goes to
movs vcfg, #%0111_0000

and

movi vcfg, #%0_10_101_000 goes to
movi vcfg, #%0_11_101_000

pin 12 is in group 1 not group 3 so

movi vcfg, #3 goes to
movi vcfg, #1

and pin 12 isn't pin 24 so

tvport_mask = #%0000_0111<<24 goes to
tvport_mask = #%0000_0111<<12

I have gone through these drivers line by line looking for anything else that might be appropriate to change and I can't find anything. Does anybody have any idea what I am missing, or if you have a version that's working with the demoboard could you post it for me?

Thanks, and thanks to Parallax for creating the most amazing chip I have seen in years. I only learned that it existed two weeks ago and it's turning my entire job upside down.

--Roger Williams aka localroger

Comments

  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2009-03-26 19:00
    Great to see more power added to PropDOS.

    What TV driver are you using? Maybe I can wade in and assist?
    Post your code.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Visit the: The Propeller Pages @ Warranty Void.
  • ericballericball Posts: 774
    edited 2009-03-27 16:25
    First, the Demoboard has a 5MHz clock while the Hydra has a 10MHz clock so you need to update your clock setting (i.e. _XINFREQ = 5_000_000 + 0000·and _CLKMODE = XTAL1 + PLL16X )

    Second, the Demoboard uses pins 12-15 for video, versus pins 24-27 for the Hydra, so you need to update VCFG (vgroup & vpins) & DIRA.

    MOVS VCFG, #%01110000
    MOVD VCFG, #%001
    MOV DIRA, idira
    idira LONG $00007000

    You don't need to change VCFG[noparse][[/noparse]31..23].
  • Cluso99Cluso99 Posts: 18,069
    edited 2009-03-28 01:40
    I suspect AiGeneric was written by Hippy - ask him about using the code (with due acknowledgement of course).

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Links to other interesting threads:

    · Home of the MultiBladeProps: TriBladeProp, SixBladeProp, website (Multiple propeller pcbs)
    · Single Board Computer:·3 Propeller ICs·and a·TriBladeProp board (ZiCog Z80 Emulator)
    · Prop Tools under Development or Completed (Index)
    · Emulators: Micros eg Altair, and Terminals eg VT100 (Index)
    · Search the Propeller forums (via Google)
    My cruising website is: ·www.bluemagic.biz·· MultiBladeProp is: www.bluemagic.biz/cluso.htm
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2009-03-28 01:46
    @Roger,

    Not sure how you are making out, but this thread may be of interest to you.

    This where the 8x8 driver had it's humble beginnings.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Visit the: The Propeller Pages @ Warranty Void.
  • potatoheadpotatohead Posts: 10,261
    edited 2009-03-29 01:13
    I'm the author of the 8x8 drivers, built off of SIMPLE_NTSC. The license is "use it, have fun with it, modify it, and share it". I need to go back and update the license in OBEX. Sorry about that.

    In the 6502 emulation project thread, in the HYDRA sub-forum, the version of this driver attached to the later versions of the 6502 prototype emulation have been modified to use the nice and spiffy font file system built as part of AiGeneric. I would use those, if you are building something off of the drivers. Lots of fonts available, and most of them are ASCII compliant. (this will make your job easier)

    http://forums.parallax.com/forums/attach.aspx?a=27192

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Propeller Wiki: Share the coolness!
    Chat in real time with other Propellerheads on IRC #propeller @ freenode.net
    Safety Tip: Life is as good as YOU think it is!

    Post Edited (potatohead) : 3/29/2009 1:18:29 AM GMT
  • localrogerlocalroger Posts: 3,452
    edited 2009-04-01 01:04
    Thanks everyone, I just moved past the problem for now by converting to the tv_text driver supplied with the proptool and left inline docs for converting to aigeneric for anyone interested; now I have an actual application I need to get done and I'm wrestling with the serial port drivers. I have to be picky about the licenses and such because I'm doing this for an actual company. I've convinced them that some of the low level learning stuff I do like converting the FAT16 code to a form I can use for my own purposes should be shared with the community. It is Parallax's whole attitude, requiring the MIT on obex code so that we can *cough* lift it ourselves that has convinced them that this is a good idea. (The fact that I will be doing plenty of industry specific stuff I _won't_ be posting here helped a lot too.) The Propeller is unique and needs to be supported. There is so much we can do with it that can't be done any other way, except for maybe ten times the price.

    I'll be putting my first effort up in a few days, I'm in the cleaning it up for public consumption phase right now.
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2009-04-01 01:16
    Good news. The AiGeneric driver has been approved for MIT license.
    It will be posted officially soon. You are welcome use use the existing driver under MIT.

    Edit: Just posted 9:30pm

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Visit the: The Propeller Pages @ Warranty Void.

    Post Edited (Oldbitcollector) : 4/1/2009 1:40:48 AM GMT
  • KPRKPR Posts: 189
    edited 2009-04-01 13:44
    I'd love to see what you have done in your re-write of propdos.. Are you planing on sharing?

    k.
Sign In or Register to comment.