To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.org.ca.rtltorontoOpen lugnet.org.ca.rtltoronto in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Organizations / Canada / rtlToronto / 10444
10443  |  10445
Subject: 
Re: Quite C and BrickOS (WAS: Re: Steve H, C$, me learning C Brick OS)
Newsgroups: 
lugnet.org.ca.rtltoronto
Date: 
Thu, 15 Jan 2004 17:48:35 GMT
Viewed: 
477 times
  
Calum Tsang wrote:

In lugnet.org.ca.rtltoronto, Chris Magno wrote:
ok, back to what is C

so if I take an example helloworld.c file from a demo section of my current
nightmare (brickos)

Well, the general syntax and structure of C are the same.  But how you call the
motors, sensors and other hardware is different from platform to platform,
unless someone deliberately tried to make them all common, which I'm not sure.

Think of it like this.  On your C64, programs that said:

10 PRINT "CHRIS IS THE BEST"
20 GOTO 10

worked exactly the same way on the Apple II or another computer, because print
and goto are generic BASIC tokens for almost all platforms.

But if you had a program that was like:

10 PRINT "CHRIS IS THE BEST"
15 POKE 53280,6
20 GOTO 10

where line 15 changes the border colour on the display, this won't port clean to
the Apple II, because that poke calls specific hardware (the 64's VIC graphics
chip) in a specific way.

How Quite C and legOS do non generic stuff would be part of the porting
exercise.  I don't think is is nontrivial.

Calum

wow calum, I take back some of those nasty things i said about you to the reporter
at dinner.

your 64 example explained it very well.

thanks.

so based on what calum said, I wont even bother trying to install QC.  cause my
marble prg might not work.



Chris
There's no 'I' in 'team'.  There's four in 'platitude-quoting idiot'.



Message has 1 Reply:
  Re: Quite C and BrickOS (WAS: Re: Steve H, C$, me learning C Brick OS)
 
(...) What's his number? I have to retract my "how we met and started the group" story now. Damn! Calum (21 years ago, 15-Jan-04, to lugnet.org.ca.rtltoronto)

Message is in Reply To:
  Re: Quite C and BrickOS (WAS: Re: Steve H, C$, me learning C Brick OS)
 
(...) Well, the general syntax and structure of C are the same. But how you call the motors, sensors and other hardware is different from platform to platform, unless someone deliberately tried to make them all common, which I'm not sure. Think of (...) (21 years ago, 15-Jan-04, to lugnet.org.ca.rtltoronto)

41 Messages in This Thread:













Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact

This Message and its Replies on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR