ASM colour chart

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
User avatar
Touch
Member
Member
Posts: 56
Joined: Sun Oct 22, 2006 10:33 am
Location: England

ASM colour chart

Post by Touch »

Hey, my OS is in 16-bit and unfortuantley, I can never remember any of the colour codes. Do any of you have a chart of colours or something that might help?

Thanks

~Touch
"We cannot trust the sword in the hands of a n00b!" - Southpark
User avatar
gaf
Member
Member
Posts: 349
Joined: Thu Oct 21, 2004 11:00 pm
Location: Munich, Germany

Post by gaf »

Bran's tutorials contain a colour chart along with some more general information about console printing.

cheers,
gaf
Last edited by gaf on Tue Oct 24, 2006 9:43 am, edited 1 time in total.
User avatar
Touch
Member
Member
Posts: 56
Joined: Sun Oct 22, 2006 10:33 am
Location: England

Post by Touch »

Hey thanks!

This is really gonna help!

~Touch
"We cannot trust the sword in the hands of a n00b!" - Southpark
User avatar
Dex
Member
Member
Posts: 1444
Joined: Fri Jan 27, 2006 12:00 am
Contact:

Post by Dex »

Remember you can use upto 256 colors, but you can only show 16 at a time.
User avatar
Touch
Member
Member
Posts: 56
Joined: Sun Oct 22, 2006 10:33 am
Location: England

Post by Touch »

@Dex I will remember that!

Btw, I was speaking to this guy from Linux Format, he gave me a link to all good colours and how to use them. Its reall simple.
"We cannot trust the sword in the hands of a n00b!" - Southpark
xsix
Member
Member
Posts: 59
Joined: Tue Oct 24, 2006 10:52 am

Post by xsix »

you can define colors as variables, like: blue db 1 ant then use it. it may be a bit bit bit bit slower because of an access to memory bet you later you can just use notepad function REPLACE :)
User avatar
Candy
Member
Member
Posts: 3882
Joined: Tue Oct 17, 2006 11:33 pm
Location: Eindhoven

Post by Candy »

xsix wrote:you can define colors as variables, like: blue db 1 ant then use it. it may be a bit bit bit bit slower because of an access to memory bet you later you can just use notepad function REPLACE :)
if you're really worried about performance (the delay would be on the order of 5 nanoseconds - in case of a cache miss on a recent computer, which you won't have because your code most likely is smaller than the cache) you can use equ instead of db. db reserves space for it (a byte to be exact) and equ just tells the assembler that blue would be equal to 1. It's then equally fast.
User avatar
Touch
Member
Member
Posts: 56
Joined: Sun Oct 22, 2006 10:33 am
Location: England

Post by Touch »

Yeah, that would work.

But its all settled and done now because I was sent this link in an email:

http://www.emu8086.com/assembly_languag ... tml#attrib

Couldnt get links working??
"We cannot trust the sword in the hands of a n00b!" - Southpark
Post Reply