01 November 2011, 08:46 | #1 |
Phone Homer
Join Date: Jun 2006
Location: 5150
Posts: 5,773
|
Blitz Basic 2 & Peek
Hi finaly decided to give Blitz ago
I just want to do a simple script Load File Bank 1 A=Peek Bank 1 Address !00 Print A Does "Deek" exist in BB2 Ive found the manual not much use and getting info hard |
02 November 2011, 00:49 | #2 |
A1200 040 SAM440EP 667
Join Date: Jan 2008
Location: Lisbon / Portugal
Posts: 873
|
|
02 November 2011, 20:19 | #3 |
Phone Homer
Join Date: Jun 2006
Location: 5150
Posts: 5,773
|
If I
LOADBANK 1,"TEST.DATA" How do can I PEEK this or know what memory address its loaded into? |
02 November 2011, 21:14 | #4 |
Total Chaos forever!
Join Date: Aug 2007
Location: Waterville, MN, USA
Age: 49
Posts: 2,186
|
I didn't know there were even Bank commands in Blitz. Maybe switching from Amos to Blitz will be difficult for you.
Usually you use structures in Blitz and C instead of Peeking memory addresses manually. What can you tell us about the layout of your data file? |
02 November 2011, 21:17 | #5 |
Phone Homer
Join Date: Jun 2006
Location: 5150
Posts: 5,773
|
Probably will be a challenge
"http://amiga.sourceforge.net/amigadevhelp/phpwebdev.php?keyword=LoadBank&funcgroup=BlitzBasic&action=Search" LoadBank command is there Or necessary Command to load the file into memory so I can then PEEK it |
02 November 2011, 21:33 | #6 |
Total Chaos forever!
Join Date: Aug 2007
Location: Waterville, MN, USA
Age: 49
Posts: 2,186
|
value=Deek(address) is just Amos' version of value=Peek.w(address)
|
02 November 2011, 21:36 | #7 | |
Phone Homer
Join Date: Jun 2006
Location: 5150
Posts: 5,773
|
Basicly all I want to do
Is load a file into memory then Peek that address Quote:
(although irrelevant to the question a quick google shows deek in other languages where it originated I dont know) Last edited by Retro1234; 02 November 2011 at 22:06. |
|
02 November 2011, 22:51 | #8 |
Registered User
Join Date: Sep 2008
Location: Gainesville U.S.A.
Posts: 771
|
Boo Boo - Try some variant of this. Don't feel bad. I was stymied for quite a long time on one of my programs because I neglected to put the U on the COLOUR command.
Code:
LoadBank 1, "test.data" a.l = Bank (1) ; a.l is lower case L NPrint a.l, "=address of first byte" NPrint Peek.b(a.l),"=1st byte of file" ;also a peek.w peek.l to mess with. Code:
LoadBank 1, "test.data" DEFTYPE.l a a = Bank (1) NPrint a, "=address of first byte" NPrint Peek.b(a),"=1st byte of file" Last edited by clenched; 03 November 2011 at 00:26. |
02 November 2011, 22:54 | #9 |
Phone Homer
Join Date: Jun 2006
Location: 5150
Posts: 5,773
|
Thank You! ill give it a shot
|
03 November 2011, 00:38 | #10 |
Phone Homer
Join Date: Jun 2006
Location: 5150
Posts: 5,773
|
What am I doing wrong? the "Bank" command is always giving me Syntax
|
03 November 2011, 13:04 | #11 |
Phone Homer
Join Date: Jun 2006
Location: 5150
Posts: 5,773
|
I cut and pasted the above but always got a Syntax with line 2
The manual states - Bank (Bank#) Returns the meniory location of the given memory Bank, replaces the older and more stupidly named BankLoc command. As soon as I changed Bank to BankLoc it seems to work? Thanks again clenched now I can have a bit of a play |
28 February 2016, 19:34 | #12 |
Phone Homer
Join Date: Jun 2006
Location: 5150
Posts: 5,773
|
Nothing to see
Last edited by Retro1234; 28 February 2016 at 19:48. Reason: seems to work |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Blitz basic 2 Help | Havie | Coders. Blitz Basic | 30 | 08 September 2013 09:15 |
Blitz Basic 1 & 2 | Twiggy | Coders. General | 14 | 21 February 2009 15:29 |
blitz basic | petza | request.Apps | 11 | 08 April 2007 01:49 |
Blitz Basic 2 anyone? | jobro | request.Apps | 12 | 28 November 2005 18:15 |
Blitz Basic 2 | LaundroMat | Retrogaming General Discussion | 5 | 24 July 2001 08:10 |
|
|