Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.sys.acorn.programmer > #1525
| Path | csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!newsfeed1.swip.net!news.astraweb.com!border6.a.newsrouter.astraweb.com!border4.nntp.ams.giganews.com!border2.nntp.ams.giganews.com!border3.nntp.ams.giganews.com!Xl.tags.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!local2.nntp.ams.giganews.com!nntp.bt.com!news.bt.com.POSTED!not-for-mail |
|---|---|
| NNTP-Posting-Date | Thu, 22 Mar 2012 15:03:48 -0500 |
| From | Colin McDonagh <colmcdonagh@btinternet.com> |
| Subject | Re: *REFRESH |
| Newsgroups | comp.sys.acorn.programmer |
| Date | Thu, 22 Mar 2012 19:56:41 +0000 (GMT) |
| Message-ID | <527498f75bcolmcdonagh@btinternet.com> (permalink) |
| References | <52741d1e5dcolmcdonagh@btinternet.com> <469ff090-12eb-40a7-af37-62c79881d65e@v22g2000vby.googlegroups.com> <5a472327-24da-4f06-b92e-209ccb39afe8@j14g2000vbc.googlegroups.com> |
| User-Agent | Pluto/3.04e (RISC-OS/6.20) NewsHound/v1.50-32 |
| Organization | Home |
| Lines | 105 |
| X-Usenet-Provider | http://www.giganews.com |
| X-AuthenticatedUsername | NoAuthUser |
| X-Trace | sv3-UzPG5XHQqGb7lq8yqY6/I/W5/s3sa+SR9rRbiaF/R283gbxMFZP34h6gn0IY54vd3A7oiMofJG9YmuR!a5xXf3Dy3a3xzLXXTzDpwJ2A/zTnoN9bP1AMkhd6VLgmHGj0ovrND/oZlbNMJnzI4PH8X60QkQ== |
| X-Complaints-To | abuse@btinternet.com |
| X-DMCA-Complaints-To | abuse@btinternet.com |
| X-Abuse-and-DMCA-Info | Please be sure to forward a copy of ALL headers |
| X-Abuse-and-DMCA-Info | Otherwise we will be unable to process your complaint properly |
| X-Postfilter | 1.3.40 |
| X-Original-Bytes | 3358 |
| Xref | csiph.com comp.sys.acorn.programmer:1525 |
Show key headers only | View raw
In article <5a472327-24da-4f06-b92e-209ccb39afe8@j14g2000vbc.googlegroups.com>, jgharston <jgh@arcade.demon.co.uk> wrote: > > set up two screen banks ... Thanks JG, This is my prog, where do I put the WAIT etc.. Cheers Colin. REM Simulate hybrid coupler Wave. REM 15/03/2012 MODE 28 :REM 256-colour mode : ON ERROR PROCerror : END : REM**************************************** : GCOL 132 :REM Sets graphic background colour to (132-128) = 4, blue. CLG :REM Clears graphic screen to background colour GCOL 7 :REM Sets graphic foreground colour to 7, white. COLOUR132 REM**************************************** : LeftEdge% = 0 RightEdge% = 1279 TopEdge% = 1023 BottomEdge% = 0 PROCbox : VDU 28,5,50,80,60 :REM Set up a text viewport : COLOUR 1 xtemp = 0 ytemp = 0 : FOR Phase = 0 TO 359 STEP 2 loiter = INKEY(10) CLS PROCbox : FOR Angle = 0 TO 1280 STEP 1 : Colour = 3 :REM Yellow line PROCwave1(Colour, Angle, Phase, X, Y) xms = X^2 + xtemp yms = Y^2 + ytemp NEXT Angle xrms = SQR(xms) yrms = SQR(yms) PRINT TAB(50,20) "X = " xrms, TAB(50,40) " Y = " yrms NEXT Phase : END : DEF PROCerror REPORT PRINT " at Line " ; ERL ENDPROC : DEF PROCbox MOVE RightEdge% , TopEdge% REM Moves cursor to point (1279,1023), top right corner of 'standard' screen. : REM Next four lines draw line around edge of 'standard' screen. DRAW LeftEdge% , TopEdge% DRAW LeftEdge% , BottomEdge% DRAW RightEdge% , BottomEdge% DRAW RightEdge% , TopEdge% ENDPROC DEF PROCwave1(col, angle, phi, RETURN x, RETURN y) GCOL col TINT 0 :REM yellow lines or blue lines angleRad = (angle/(2*PI))/9 phaseRad = (phi/(2*PI))/9 A = 100*SIN(angleRad) :REM This is a wave, fixed to the right. B = 100*SIN(angleRad+phaseRad) :REM This is wave moving left. REM phase shift one by -90 degrees minusjA = 100*SIN(angleRad-PI/2) REM phase shift by -90 degress minusjB = 100*SIN(angleRad+phaseRad-PI/2) REM To the right PLOT &45, angle, A + 800 : PLOT &45, angle, B + 200 GCOL col+2 REM To the left x = 0.5*A + 0.5*minusjB y = 0.5*B + 0.5*minusjA REM The hybrid wave is the sum of two above. PLOT &45, angle, x+620 PLOT &45, angle, y+400 : ENDPROC
Back to comp.sys.acorn.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
*REFRESH Colin McDonagh <colmcdonagh@btinternet.com> - 2012-03-21 21:23 +0000
Re: *REFRESH jgharston <jgh@arcade.demon.co.uk> - 2012-03-21 15:39 -0700
Re: *REFRESH jgharston <jgh@arcade.demon.co.uk> - 2012-03-21 15:42 -0700
Re: *REFRESH Colin McDonagh <colmcdonagh@btinternet.com> - 2012-03-22 19:56 +0000
Re: *REFRESH Rick Murray <heyrickmail-usenet@yahoo.co.uk> - 2012-03-22 06:42 +0100
Re: *REFRESH Colin McDonagh <colmcdonagh@btinternet.com> - 2012-03-22 20:00 +0000
csiph-web