Hi! I have a VIC-20. And I'm going to turn it into an IRC client.
There'll be a lot of documentation here, but I expect a lot of the technical details to be moved to an external blog in the future as to not have multi-thousand word postings.
Consider this a "day to day" thread, other than this post -- if you only want the nitty gritty architectural stuff I'd recommend looking at the blog, which doesn't actually exist yet since I have no content for it yet, and this part will be updated in the future with the link.
FAQ:
"Why don't you use a raspberry pi?"
You spelled pie wrong. You're telling me this can run IRC?
Image shamelessly stolen from https://cosmocookie.blogspot.com/2011/10/raspberry-pie.html
"Why?"
Because using IRC on a computer from 1980 is pretty cool.
Ok, now for the actual post...
There are many architectural limitations to the 6502 and the VIC-20 hardware itself which will make this project painful and overcomplicated. And I have set some "rules" for myself:
Alright! Now that that's out of the way... Let's talk DMA!
Yes, DMA on a VIC-20. I did say I'm making my own expanded memory controller... 5K simply isn't enough to handle all of the scrollback for all of the channels, let alone have the code in it!
Pretty much, due to the very limited address space of the VIC-20 (~ 64k!) we're going to need windowed memory more than likely to handle this. And because getting things in and out of the (bitbanged) RS-232 would be... difficult, at maybe 2400 bits a second best case, DMA seems like a more logical answer. I will use the GPIO for window selection (Remember, need more than just the chip select for that!), various DMA control (undecided exactly ~how~) and other assistive functions, instead of using them to get a slow, stupid serial input/output.
Additional architecture to come with time.
Hardware to be used beyond a VIC-20
I expect to use two small microcontrollers (likely microchip PIC controllers or other TI/ST controllers) to handle the expanded memory, windowing, and the TCP/IP stack. One for the memory system and DMA handling, and the other one to run the IP stack.
IP stack stripping and processing is to be done entirely in a microcontroller. the 1500 byte MTU is just too big, I think, to eat entirely on a VIC-20 in any remotely efficient manner. I want to just get the IRC protocol to it.
I hope to find a microcontroller with an integrated ethernet PHY as that will make my life easier.
The memory handling was already discussed earlier.
The VIC-20 will handle the entire IRC protocol. Software architecture hasn't been defined yet.
What are your thoughts so far? Am I completely nuts?
There'll be a lot of documentation here, but I expect a lot of the technical details to be moved to an external blog in the future as to not have multi-thousand word postings.
Consider this a "day to day" thread, other than this post -- if you only want the nitty gritty architectural stuff I'd recommend looking at the blog, which doesn't actually exist yet since I have no content for it yet, and this part will be updated in the future with the link.
FAQ:
"Why don't you use a raspberry pi?"
You spelled pie wrong. You're telling me this can run IRC?
Image shamelessly stolen from https://cosmocookie.blogspot.com/2011/10/raspberry-pie.html
"Why?"
Because using IRC on a computer from 1980 is pretty cool.
Ok, now for the actual post...
There are many architectural limitations to the 6502 and the VIC-20 hardware itself which will make this project painful and overcomplicated. And I have set some "rules" for myself:
- All external circuitry must be designed, prototyped, and soldered by myself (I'll spare myself the pain of custom PCB manufacture, and IC development -- I'm not going to design an ethernet PHY, for example.)
- The limitations of the VIC-20 must be overcome WITHOUT modifying the internals of the VIC-20, and only the ports on the back may be used to modify the functionality.
- This is to ensure that the end goal of an IRC functionality cartridge may be available in the future, in a very, very limited, unsupported run.
- I am going to develop all software to be fully open-source with a permissive (BSD) license.
- External toolchains are permissible (I do not have to write the software in the 80s, I can use C compiled to a 6502 target with inline assembly where needed)
- External hardware faster than the VIC-20 is permissible
- However, it should be limited to where needed -- for example, not going to use an odroid instead of an ethernet PIC.
- The majority of the software MUST be written by myself.
- I understand there are OSes available for the VIC-20, some of which contain an IRC client. But that's not OVERCOMPLICATED, IS IT?!
- The cartridge must, in the end, contain everything needed: From memory expansion to ethernet to ROM, it simply must have it all!
- Fully compliant with IRC protocol v2.4.0 documented in IETF RFC 1459
- Scrollback of at least 50 lines per channel
- 5 channels or more
- One or more IRC server connections (Starting with one with a view to keep the code scalable to have more)
- Support 10/100 ethernet
- Fully compliant with all applicable networking standards used in a home network
- Fully text-based client, with the only input device being the keyboard of the VIC-20
Alright! Now that that's out of the way... Let's talk DMA!
Yes, DMA on a VIC-20. I did say I'm making my own expanded memory controller... 5K simply isn't enough to handle all of the scrollback for all of the channels, let alone have the code in it!
Pretty much, due to the very limited address space of the VIC-20 (~ 64k!) we're going to need windowed memory more than likely to handle this. And because getting things in and out of the (bitbanged) RS-232 would be... difficult, at maybe 2400 bits a second best case, DMA seems like a more logical answer. I will use the GPIO for window selection (Remember, need more than just the chip select for that!), various DMA control (undecided exactly ~how~) and other assistive functions, instead of using them to get a slow, stupid serial input/output.
Additional architecture to come with time.
Hardware to be used beyond a VIC-20
I expect to use two small microcontrollers (likely microchip PIC controllers or other TI/ST controllers) to handle the expanded memory, windowing, and the TCP/IP stack. One for the memory system and DMA handling, and the other one to run the IP stack.
IP stack stripping and processing is to be done entirely in a microcontroller. the 1500 byte MTU is just too big, I think, to eat entirely on a VIC-20 in any remotely efficient manner. I want to just get the IRC protocol to it.
I hope to find a microcontroller with an integrated ethernet PHY as that will make my life easier.
The memory handling was already discussed earlier.
The VIC-20 will handle the entire IRC protocol. Software architecture hasn't been defined yet.
What are your thoughts so far? Am I completely nuts?
Last edited: