Re: [M100] BASIC syntax question

2018-02-05 Thread Ken Pettit

Okay I submitted NUMAZE to my Pesonal Libraries section at Club100.

Ken

On 2/5/18 6:47 PM, Josh Malone wrote:

Way to make us all look bad, Ken. :)

On Feb 5, 2018 9:43 PM, "Ken Pettit" > wrote:


Today I also submitted one of the 3 games I wrote.  I have a game
written/working for each of the PUR-80, PUR-120 and EXTREM-256
categories.  I wrote these this past weekend. The one I submitted
today is the PUR-120 game ... it is a Number Maze (NUMAZE.BA
) for the T200 only.  I have not posted it to my
Personal Libraries section at Club100 yet but will soon (maybe
tonight or tomorrow night).

For the other 2 games, I still need to do a write up for game
rules / running in VT, etc.

Ken


On 2/5/18 6:37 PM, Kevin Becker wrote:

I'm really having trouble squeezing my original idea down to 10
lines in a form that is at all fun to play.  I may put it on hold
and try to recreate a game that I originally wrote for my TRS-80
PC-3 way back in the day.  I'm certain that one can be done in 10
lines.

On Mon, Feb 5, 2018 at 9:22 PM, Josh Malone
> wrote:

My entry is submitted.

https://github.com/48kRAM/m100-codebreaker


It's a code breaker game in the style of Master Mind. I once
wrote a
version of the game for GW-basic back in the DOS days. This was a
complete re-write as I lost that game decades ago :)

Who else is going to enter?

-Josh

On Thu, Feb 1, 2018 at 7:52 PM, Josh Malone
> wrote:
> On Thu, Feb 1, 2018 at 6:31 PM, Ken Pettit
> wrote:
>> This little game is actually kinda fun to play, especially
on T200.  I
>> wonder what the 10-Liner rules are about sharing prior to
judging :)
>>
>> Ken
>
> I seem to recall they're cool with it - esp since I know
previous
> players have collaborated and reviewed e/o's code. Kevin
mentioned his
> experience on the Antic podcast last year.








Re: [M100] BASIC syntax question

2018-02-05 Thread Ken Pettit
Okay, in all honesty, I wrote the EXTREME-256 game on Wednesday night 
and really only wrote the PUR-80 and PUR-120 games this weekend, so no 
need to feel like you "look bad" :)


Ken

On 2/5/18 6:47 PM, Josh Malone wrote:

Way to make us all look bad, Ken. :)

On Feb 5, 2018 9:43 PM, "Ken Pettit" > wrote:


Today I also submitted one of the 3 games I wrote.  I have a game
written/working for each of the PUR-80, PUR-120 and EXTREM-256
categories.  I wrote these this past weekend. The one I submitted
today is the PUR-120 game ... it is a Number Maze (NUMAZE.BA
) for the T200 only.  I have not posted it to my
Personal Libraries section at Club100 yet but will soon (maybe
tonight or tomorrow night).

For the other 2 games, I still need to do a write up for game
rules / running in VT, etc.

Ken


On 2/5/18 6:37 PM, Kevin Becker wrote:

I'm really having trouble squeezing my original idea down to 10
lines in a form that is at all fun to play.  I may put it on hold
and try to recreate a game that I originally wrote for my TRS-80
PC-3 way back in the day.  I'm certain that one can be done in 10
lines.

On Mon, Feb 5, 2018 at 9:22 PM, Josh Malone
> wrote:

My entry is submitted.

https://github.com/48kRAM/m100-codebreaker


It's a code breaker game in the style of Master Mind. I once
wrote a
version of the game for GW-basic back in the DOS days. This was a
complete re-write as I lost that game decades ago :)

Who else is going to enter?

-Josh

On Thu, Feb 1, 2018 at 7:52 PM, Josh Malone
> wrote:
> On Thu, Feb 1, 2018 at 6:31 PM, Ken Pettit
> wrote:
>> This little game is actually kinda fun to play, especially
on T200.  I
>> wonder what the 10-Liner rules are about sharing prior to
judging :)
>>
>> Ken
>
> I seem to recall they're cool with it - esp since I know
previous
> players have collaborated and reviewed e/o's code. Kevin
mentioned his
> experience on the Antic podcast last year.








Re: [M100] BASIC syntax question

2018-02-05 Thread Josh Malone
Way to make us all look bad, Ken. :)

On Feb 5, 2018 9:43 PM, "Ken Pettit"  wrote:

> Today I also submitted one of the 3 games I wrote.  I have a game
> written/working for each of the PUR-80, PUR-120 and EXTREM-256 categories.
> I wrote these this past weekend.  The one I submitted today is the PUR-120
> game ... it is a Number Maze (NUMAZE.BA) for the T200 only.  I have not
> posted it to my Personal Libraries section at Club100 yet but will soon
> (maybe tonight or tomorrow night).
>
> For the other 2 games, I still need to do a write up for game rules /
> running in VT, etc.
>
> Ken
>
>
> On 2/5/18 6:37 PM, Kevin Becker wrote:
>
> I'm really having trouble squeezing my original idea down to 10 lines in a
> form that is at all fun to play.  I may put it on hold and try to recreate
> a game that I originally wrote for my TRS-80 PC-3 way back in the day.  I'm
> certain that one can be done in 10 lines.
>
> On Mon, Feb 5, 2018 at 9:22 PM, Josh Malone  wrote:
>
>> My entry is submitted.
>>
>> https://github.com/48kRAM/m100-codebreaker
>>
>> It's a code breaker game in the style of Master Mind. I once wrote a
>> version of the game for GW-basic back in the DOS days. This was a
>> complete re-write as I lost that game decades ago :)
>>
>> Who else is going to enter?
>>
>> -Josh
>>
>> On Thu, Feb 1, 2018 at 7:52 PM, Josh Malone 
>> wrote:
>> > On Thu, Feb 1, 2018 at 6:31 PM, Ken Pettit  wrote:
>> >> This little game is actually kinda fun to play, especially on T200.  I
>> >> wonder what the 10-Liner rules are about sharing prior to judging :)
>> >>
>> >> Ken
>> >
>> > I seem to recall they're cool with it - esp since I know previous
>> > players have collaborated and reviewed e/o's code. Kevin mentioned his
>> > experience on the Antic podcast last year.
>>
>
>
>


Re: [M100] BASIC syntax question

2018-02-05 Thread Ken Pettit
Today I also submitted one of the 3 games I wrote.  I have a game 
written/working for each of the PUR-80, PUR-120 and EXTREM-256 
categories.  I wrote these this past weekend.  The one I submitted today 
is the PUR-120 game ... it is a Number Maze (NUMAZE.BA) for the T200 
only.  I have not posted it to my Personal Libraries section at Club100 
yet but will soon (maybe tonight or tomorrow night).


For the other 2 games, I still need to do a write up for game rules / 
running in VT, etc.


Ken


On 2/5/18 6:37 PM, Kevin Becker wrote:
I'm really having trouble squeezing my original idea down to 10 lines 
in a form that is at all fun to play.  I may put it on hold and try to 
recreate a game that I originally wrote for my TRS-80 PC-3 way back in 
the day.  I'm certain that one can be done in 10 lines.


On Mon, Feb 5, 2018 at 9:22 PM, Josh Malone > wrote:


My entry is submitted.

https://github.com/48kRAM/m100-codebreaker


It's a code breaker game in the style of Master Mind. I once wrote a
version of the game for GW-basic back in the DOS days. This was a
complete re-write as I lost that game decades ago :)

Who else is going to enter?

-Josh

On Thu, Feb 1, 2018 at 7:52 PM, Josh Malone > wrote:
> On Thu, Feb 1, 2018 at 6:31 PM, Ken Pettit > wrote:
>> This little game is actually kinda fun to play, especially on
T200.  I
>> wonder what the 10-Liner rules are about sharing prior to
judging :)
>>
>> Ken
>
> I seem to recall they're cool with it - esp since I know previous
> players have collaborated and reviewed e/o's code. Kevin
mentioned his
> experience on the Antic podcast last year.






Re: [M100] BASIC syntax question

2018-02-05 Thread Kevin Becker
I'm really having trouble squeezing my original idea down to 10 lines in a
form that is at all fun to play.  I may put it on hold and try to recreate
a game that I originally wrote for my TRS-80 PC-3 way back in the day.  I'm
certain that one can be done in 10 lines.

On Mon, Feb 5, 2018 at 9:22 PM, Josh Malone  wrote:

> My entry is submitted.
>
> https://github.com/48kRAM/m100-codebreaker
>
> It's a code breaker game in the style of Master Mind. I once wrote a
> version of the game for GW-basic back in the DOS days. This was a
> complete re-write as I lost that game decades ago :)
>
> Who else is going to enter?
>
> -Josh
>
> On Thu, Feb 1, 2018 at 7:52 PM, Josh Malone  wrote:
> > On Thu, Feb 1, 2018 at 6:31 PM, Ken Pettit  wrote:
> >> This little game is actually kinda fun to play, especially on T200.  I
> >> wonder what the 10-Liner rules are about sharing prior to judging :)
> >>
> >> Ken
> >
> > I seem to recall they're cool with it - esp since I know previous
> > players have collaborated and reviewed e/o's code. Kevin mentioned his
> > experience on the Antic podcast last year.
>


Re: [M100] BASIC syntax question

2018-02-05 Thread Josh Malone
My entry is submitted.

https://github.com/48kRAM/m100-codebreaker

It's a code breaker game in the style of Master Mind. I once wrote a
version of the game for GW-basic back in the DOS days. This was a
complete re-write as I lost that game decades ago :)

Who else is going to enter?

-Josh

On Thu, Feb 1, 2018 at 7:52 PM, Josh Malone  wrote:
> On Thu, Feb 1, 2018 at 6:31 PM, Ken Pettit  wrote:
>> This little game is actually kinda fun to play, especially on T200.  I
>> wonder what the 10-Liner rules are about sharing prior to judging :)
>>
>> Ken
>
> I seem to recall they're cool with it - esp since I know previous
> players have collaborated and reviewed e/o's code. Kevin mentioned his
> experience on the Antic podcast last year.


Re: [M100] BASIC syntax question

2018-02-01 Thread Josh Malone
On Thu, Feb 1, 2018 at 6:31 PM, Ken Pettit  wrote:
> This little game is actually kinda fun to play, especially on T200.  I
> wonder what the 10-Liner rules are about sharing prior to judging :)
>
> Ken

I seem to recall they're cool with it - esp since I know previous
players have collaborated and reviewed e/o's code. Kevin mentioned his
experience on the Antic podcast last year.


Re: [M100] BASIC syntax question

2018-02-01 Thread Ken Pettit
This little game is actually kinda fun to play, especially on T200. I 
wonder what the 10-Liner rules are about sharing prior to judging :)


Ken

On 2/1/18 8:38 AM, Josh Malone wrote:
Yeah! I have no aspirations to place anywhere in the results - I just 
want to enter for the experience of it and to learn M100 BASIC.


On Feb 1, 2018 10:55 AM, "Ken Pettit" > wrote:


I guess I can submit an entry.  Last and a bit this morning, I
coded up a game using 7 BASIC line.  That means I have 3 more
lines for added functionality.  I wonder if they give
consideration for only using 7 lines instead of 10?

Heck, even if my entry doesn't win, at least it means we have a
new game for the Model T!  :)

Ken

On 1/31/18 6:53 PM, ke...@kevinbecker.org
 wrote:

I'm surprised there aren't more CoCo entries.  That was my machine
growing up but I don't have one anymore. I'm always tempted to
pick one
up but it'd mostly just take up space.  The model Ts are
perfect for a
retro hobby computer.  It'd be nice to get a strong showing of
M100
entries.

On Wed, 2018-01-31 at 21:43 -0500, Josh Malone wrote:

Awesome! The Tandy machines are horribly underrepresented
in this
contest it seems. Let's show those Atari and Commodore
people a thing
or two. Lol!

(He says, being also an avid Atari fan)






Re: [M100] BASIC syntax question

2018-02-01 Thread Josh Malone
Yeah! I have no aspirations to place anywhere in the results - I just want
to enter for the experience of it and to learn M100 BASIC.

On Feb 1, 2018 10:55 AM, "Ken Pettit"  wrote:

> I guess I can submit an entry.  Last and a bit this morning, I coded up a
> game using 7 BASIC line.  That means I have 3 more lines for added
> functionality.  I wonder if they give consideration for only using 7 lines
> instead of 10?
>
> Heck, even if my entry doesn't win, at least it means we have a new game
> for the Model T!  :)
>
> Ken
>
> On 1/31/18 6:53 PM, ke...@kevinbecker.org wrote:
>
>> I'm surprised there aren't more CoCo entries.  That was my machine
>> growing up but I don't have one anymore. I'm always tempted to pick one
>> up but it'd mostly just take up space.  The model Ts are perfect for a
>> retro hobby computer.  It'd be nice to get a strong showing of M100
>> entries.
>>
>> On Wed, 2018-01-31 at 21:43 -0500, Josh Malone wrote:
>>
>>> Awesome! The Tandy machines are horribly underrepresented in this
>>> contest it seems. Let's show those Atari and Commodore people a thing
>>> or two. Lol!
>>>
>>> (He says, being also an avid Atari fan)
>>>
>>>
>


Re: [M100] BASIC syntax question

2018-02-01 Thread Ken Pettit
I guess I can submit an entry.  Last and a bit this morning, I coded up 
a game using 7 BASIC line.  That means I have 3 more lines for added 
functionality.  I wonder if they give consideration for only using 7 
lines instead of 10?


Heck, even if my entry doesn't win, at least it means we have a new game 
for the Model T!  :)


Ken

On 1/31/18 6:53 PM, ke...@kevinbecker.org wrote:

I'm surprised there aren't more CoCo entries.  That was my machine
growing up but I don't have one anymore. I'm always tempted to pick one
up but it'd mostly just take up space.  The model Ts are perfect for a
retro hobby computer.  It'd be nice to get a strong showing of M100
entries.

On Wed, 2018-01-31 at 21:43 -0500, Josh Malone wrote:

Awesome! The Tandy machines are horribly underrepresented in this
contest it seems. Let's show those Atari and Commodore people a thing
or two. Lol!

(He says, being also an avid Atari fan)





Re: [M100] BASIC syntax question

2018-01-31 Thread kevin
I'm surprised there aren't more CoCo entries.  That was my machine
growing up but I don't have one anymore. I'm always tempted to pick one
up but it'd mostly just take up space.  The model Ts are perfect for a
retro hobby computer.  It'd be nice to get a strong showing of M100
entries.

On Wed, 2018-01-31 at 21:43 -0500, Josh Malone wrote:
> Awesome! The Tandy machines are horribly underrepresented in this
> contest it seems. Let's show those Atari and Commodore people a thing
> or two. Lol!
> 
> (He says, being also an avid Atari fan)
> 


Re: [M100] BASIC syntax question

2018-01-31 Thread Josh Malone
Awesome! The Tandy machines are horribly underrepresented in this contest
it seems. Let's show those Atari and Commodore people a thing or two. Lol!

(He says, being also an avid Atari fan)

On Jan 31, 2018 9:41 PM, "Ken Pettit"  wrote:

> Well, if I could get my R's in gear, I could write a 10-line game. I
> thought of one that I could code in 10 lines.  Actually I thought of two,
> but who's counting.  The cool thing with 10 lines is that it is only about
> 2.5 hours of effort.  That's only 15 minutes per line! :)
>
> Ken
>
> On 1/31/18 3:25 PM, Daryl Tester wrote:
>
>> On Wed, 31 Jan 2018 11:33:43 -0800, Ken Pettit wrote:
>>
>> Got my R's and S's mixed up there!
>>>
>>
>> "Ah, Gitfinger, still falling down on your R's I see!"
>>  -- Kremmen, of the Star Corp.
>>
>>
>>
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Ken Pettit
Well, if I could get my R's in gear, I could write a 10-line game. I 
thought of one that I could code in 10 lines.  Actually I thought of 
two, but who's counting.  The cool thing with 10 lines is that it is 
only about 2.5 hours of effort.  That's only 15 minutes per line! :)


Ken

On 1/31/18 3:25 PM, Daryl Tester wrote:

On Wed, 31 Jan 2018 11:33:43 -0800, Ken Pettit wrote:


Got my R's and S's mixed up there!


"Ah, Gitfinger, still falling down on your R's I see!"
 -- Kremmen, of the Star Corp.






Re: [M100] BASIC syntax question

2018-01-31 Thread Daryl Tester

On Wed, 31 Jan 2018 11:33:43 -0800, Ken Pettit wrote:


Got my R's and S's mixed up there!


"Ah, Gitfinger, still falling down on your R's I see!"
 -- Kremmen, of the Star Corp.


--
Regards,
  Daryl Tester
  Handcrafted Computers Pty. Ltd.


Re: [M100] BASIC syntax question

2018-01-31 Thread Kevin Becker
Alright thanks, that's the same address I found then.

On Wed, Jan 31, 2018 at 3:30 PM, Ken Pettit  wrote:

> Hey Kevin,
>
> To convert to unsigned, just add 65536.  So it would be 0xF92F.  That is
> part of the RST 7.5 background tick ISR.  It is a 2Hz countdown timer that
> counts from 127 down to 0 over a 2 second period.
>
> Ken
>
>
> On 1/31/18 12:13 PM, Kevin Becker wrote:
>
> Nice. That works for me, thanks!
>
> Just out of curiosity, what is at -1745?  I’m not even sure how to convert
> that to an unsigned hex value
>
> On Jan 31, 2018, at 3:04 PM, Ken Pettit  wrote:
>
> Ahh, okay.  Then for brevity, how about just:
>
> 10 POKE-902,PEEK(-1745)
>
> Done!
> Ken
>
> On 1/31/18 12:02 PM, Kevin Becker wrote:
>
> Thanks, that seems more reasonable, although for the purposes of the 10
> line contest my for loop is actually a little shorter.  I may sacrifice
> some randomness for brevity in this case.
>
> On Wed, Jan 31, 2018 at 2:33 PM, Ken Pettit  wrote:
>
>> Oop,
>>
>> I think that should have been:
>>
>> 10 R=-1745:S=-902:POKE S,PEEK(R):POKE S+1,PEEK(R+1)
>>
>> Got my R's and S's mixed up there!
>> Ken
>>
>>
>> On 1/31/18 11:22 AM, Ken Pettit wrote:
>>
>> On M100/T102, you can seed the RND function by poking the RAM.  It is
>> stored as an 8-byte floating point number represented in BCD format.  Your
>> first may look like garbage characters if printed, but will work in
>> calculations:
>>
>> 10 R=-1745:S=-902:POKE R,PEEK(S):POKE R+1,PEEK(S+1)
>>
>> That should seed the random number generator with about 1664 different
>> possible values.
>>
>> Ken
>>
>> On 1/31/18 10:44 AM, Kevin Becker wrote:
>>
>> Now that I haver Virtual T running, I hit my first snag on the first line
>> of my program.
>>
>> Is there a good way to seed the random number generator in M100 BASIC?
>> The only method I've found so far is to do a for loop based on the
>> "seconds" portion of the current time.  That seems inefficient, especially
>> in a 10 line program.
>>
>> On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker 
>> wrote:
>>
>>> I hadn't found CloudT before but that is very cool.
>>>
>>> I got the precompiled VirtualT binary working on Fedora 27 by
>>> downloading the source from http://ijg.org and compiling it myself and
>>> then, instead of doing a "make install", I just copied the single
>>> libjpeg.so.9 binary to /usr/local/lib64/ and added that path with ldconfig.
>>>
>>> It's working now.
>>>
>>>
>>> On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis 
>>> wrote:
>>>

 On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker 
 wrote:

> So I gave it a go on a fresh Fedora 27 VM and the binary is
> complaining that it wants libjpeg.so.9 and I have libjpeg.so.62.  I tried 
> a
> symlink but it really wants that specific version.
>
>
 Well when you decide to give the build a shot again I suggest asking on
 the list for help from another Fedora user. VirtualT build is always a
 little bit of messing about to build but it always comes together after
 figuring out what packages and make command line to use.

 But I will say I’ve never had much luck with the canned binary except
 in Windows.

 Also if you just want to play in BASIC I created a JavaScript emulator

 http://bitchin100.com/CloudT

 — John.

>>>
>>>
>>
>>
>>
>
>
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Ken Pettit

Hey Kevin,

To convert to unsigned, just add 65536.  So it would be 0xF92F. That is 
part of the RST 7.5 background tick ISR.  It is a 2Hz countdown timer 
that counts from 127 down to 0 over a 2 second period.


Ken

On 1/31/18 12:13 PM, Kevin Becker wrote:

Nice. That works for me, thanks!

Just out of curiosity, what is at -1745?  I’m not even sure how to 
convert that to an unsigned hex value


On Jan 31, 2018, at 3:04 PM, Ken Pettit > wrote:



Ahh, okay.  Then for brevity, how about just:

10 POKE-902,PEEK(-1745)

Done!
Ken

On 1/31/18 12:02 PM, Kevin Becker wrote:
Thanks, that seems more reasonable, although for the purposes of the 
10 line contest my for loop is actually a little shorter.  I may 
sacrifice some randomness for brevity in this case.


On Wed, Jan 31, 2018 at 2:33 PM, Ken Pettit > wrote:


Oop,

I think that should have been:

10 R=-1745:S=-902:POKE S,PEEK(R):POKE S+1,PEEK(R+1)

Got my R's and S's mixed up there!
Ken


On 1/31/18 11:22 AM, Ken Pettit wrote:
On M100/T102, you can seed the RND function by poking the RAM. 
It is stored as an 8-byte floating point number represented in

BCD format.  Your first may look like garbage characters if
printed, but will work in calculations:

10 R=-1745:S=-902:POKE R,PEEK(S):POKE R+1,PEEK(S+1)

That should seed the random number generator with about 1664
different possible values.

Ken

On 1/31/18 10:44 AM, Kevin Becker wrote:

Now that I haver Virtual T running, I hit my first snag on the
first line of my program.

Is there a good way to seed the random number generator in
M100 BASIC? The only method I've found so far is to do a for
loop based on the "seconds" portion of the current time.  That
seems inefficient, especially in a 10 line program.

On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker
> wrote:

I hadn't found CloudT before but that is very cool.

I got the precompiled VirtualT binary working on Fedora 27
by downloading the source from http://ijg.org and
compiling it myself and then, instead of doing a "make
install", I just copied the single libjpeg.so.9 binary to
/usr/local/lib64/ and added that path with ldconfig.

It's working now.


On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis
> wrote:


On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker
>
wrote:

So I gave it a go on a fresh Fedora 27 VM and the
binary is complaining that it wants libjpeg.so.9
and I have libjpeg.so.62.  I tried a symlink but
it really wants that specific version.


Well when you decide to give the build a shot again I
suggest asking on the list for help from another
Fedora user. VirtualT build is always a little bit of
messing about to build but it always comes together
after figuring out what packages and make command line
to use.

But I will say I’ve never had much luck with the
canned binary except in Windows.

Also if you just want to play in BASIC I created a
JavaScript emulator

http://bitchin100.com/CloudT

— John.














Re: [M100] BASIC syntax question

2018-01-31 Thread Kevin Becker
Nice. That works for me, thanks!

Just out of curiosity, what is at -1745?  I’m not even sure how to convert
that to an unsigned hex value

On Jan 31, 2018, at 3:04 PM, Ken Pettit  wrote:

Ahh, okay.  Then for brevity, how about just:

10 POKE-902,PEEK(-1745)

Done!
Ken

On 1/31/18 12:02 PM, Kevin Becker wrote:

Thanks, that seems more reasonable, although for the purposes of the 10
line contest my for loop is actually a little shorter.  I may sacrifice
some randomness for brevity in this case.

On Wed, Jan 31, 2018 at 2:33 PM, Ken Pettit  wrote:

> Oop,
>
> I think that should have been:
>
> 10 R=-1745:S=-902:POKE S,PEEK(R):POKE S+1,PEEK(R+1)
>
> Got my R's and S's mixed up there!
> Ken
>
>
> On 1/31/18 11:22 AM, Ken Pettit wrote:
>
> On M100/T102, you can seed the RND function by poking the RAM.  It is
> stored as an 8-byte floating point number represented in BCD format.  Your
> first may look like garbage characters if printed, but will work in
> calculations:
>
> 10 R=-1745:S=-902:POKE R,PEEK(S):POKE R+1,PEEK(S+1)
>
> That should seed the random number generator with about 1664 different
> possible values.
>
> Ken
>
> On 1/31/18 10:44 AM, Kevin Becker wrote:
>
> Now that I haver Virtual T running, I hit my first snag on the first line
> of my program.
>
> Is there a good way to seed the random number generator in M100 BASIC?
> The only method I've found so far is to do a for loop based on the
> "seconds" portion of the current time.  That seems inefficient, especially
> in a 10 line program.
>
> On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker 
> wrote:
>
>> I hadn't found CloudT before but that is very cool.
>>
>> I got the precompiled VirtualT binary working on Fedora 27 by downloading
>> the source from http://ijg.org and compiling it myself and then, instead
>> of doing a "make install", I just copied the single libjpeg.so.9 binary to
>> /usr/local/lib64/ and added that path with ldconfig.
>>
>> It's working now.
>>
>>
>> On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis 
>> wrote:
>>
>>>
>>> On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker 
>>> wrote:
>>>
 So I gave it a go on a fresh Fedora 27 VM and the binary is complaining
 that it wants libjpeg.so.9 and I have libjpeg.so.62.  I tried a symlink but
 it really wants that specific version.


>>> Well when you decide to give the build a shot again I suggest asking on
>>> the list for help from another Fedora user. VirtualT build is always a
>>> little bit of messing about to build but it always comes together after
>>> figuring out what packages and make command line to use.
>>>
>>> But I will say I’ve never had much luck with the canned binary except in
>>> Windows.
>>>
>>> Also if you just want to play in BASIC I created a JavaScript emulator
>>>
>>> http://bitchin100.com/CloudT
>>>
>>> — John.
>>>
>>
>>
>
>
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Ken Pettit

Ahh, okay.  Then for brevity, how about just:

10 POKE-902,PEEK(-1745)

Done!
Ken

On 1/31/18 12:02 PM, Kevin Becker wrote:
Thanks, that seems more reasonable, although for the purposes of the 
10 line contest my for loop is actually a little shorter.  I may 
sacrifice some randomness for brevity in this case.


On Wed, Jan 31, 2018 at 2:33 PM, Ken Pettit > wrote:


Oop,

I think that should have been:

10 R=-1745:S=-902:POKE S,PEEK(R):POKE S+1,PEEK(R+1)

Got my R's and S's mixed up there!
Ken


On 1/31/18 11:22 AM, Ken Pettit wrote:
On M100/T102, you can seed the RND function by poking the RAM. 
It is stored as an 8-byte floating point number represented in

BCD format.  Your first may look like garbage characters if
printed, but will work in calculations:

10 R=-1745:S=-902:POKE R,PEEK(S):POKE R+1,PEEK(S+1)

That should seed the random number generator with about 1664
different possible values.

Ken

On 1/31/18 10:44 AM, Kevin Becker wrote:

Now that I haver Virtual T running, I hit my first snag on the
first line of my program.

Is there a good way to seed the random number generator in M100
BASIC?  The only method I've found so far is to do a for loop
based on the "seconds" portion of the current time.  That seems
inefficient, especially in a 10 line program.

On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker
> wrote:

I hadn't found CloudT before but that is very cool.

I got the precompiled VirtualT binary working on Fedora 27
by downloading the source from http://ijg.org and compiling
it myself and then, instead of doing a "make install", I
just copied the single libjpeg.so.9 binary to
/usr/local/lib64/ and added that path with ldconfig.

It's working now.


On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis
> wrote:


On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker
>
wrote:

So I gave it a go on a fresh Fedora 27 VM and the
binary is complaining that it wants libjpeg.so.9 and
I have libjpeg.so.62.  I tried a symlink but it
really wants that specific version.


Well when you decide to give the build a shot again I
suggest asking on the list for help from another Fedora
user. VirtualT build is always a little bit of messing
about to build but it always comes together after
figuring out what packages and make command line to use.

But I will say I’ve never had much luck with the canned
binary except in Windows.

Also if you just want to play in BASIC I created a
JavaScript emulator

http://bitchin100.com/CloudT

— John.












Re: [M100] BASIC syntax question

2018-01-31 Thread Kevin Becker
Thanks, that seems more reasonable, although for the purposes of the 10
line contest my for loop is actually a little shorter.  I may sacrifice
some randomness for brevity in this case.

On Wed, Jan 31, 2018 at 2:33 PM, Ken Pettit  wrote:

> Oop,
>
> I think that should have been:
>
> 10 R=-1745:S=-902:POKE S,PEEK(R):POKE S+1,PEEK(R+1)
>
> Got my R's and S's mixed up there!
> Ken
>
>
> On 1/31/18 11:22 AM, Ken Pettit wrote:
>
> On M100/T102, you can seed the RND function by poking the RAM.  It is
> stored as an 8-byte floating point number represented in BCD format.  Your
> first may look like garbage characters if printed, but will work in
> calculations:
>
> 10 R=-1745:S=-902:POKE R,PEEK(S):POKE R+1,PEEK(S+1)
>
> That should seed the random number generator with about 1664 different
> possible values.
>
> Ken
>
> On 1/31/18 10:44 AM, Kevin Becker wrote:
>
> Now that I haver Virtual T running, I hit my first snag on the first line
> of my program.
>
> Is there a good way to seed the random number generator in M100 BASIC?
> The only method I've found so far is to do a for loop based on the
> "seconds" portion of the current time.  That seems inefficient, especially
> in a 10 line program.
>
> On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker 
> wrote:
>
>> I hadn't found CloudT before but that is very cool.
>>
>> I got the precompiled VirtualT binary working on Fedora 27 by downloading
>> the source from http://ijg.org and compiling it myself and then, instead
>> of doing a "make install", I just copied the single libjpeg.so.9 binary to
>> /usr/local/lib64/ and added that path with ldconfig.
>>
>> It's working now.
>>
>>
>> On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis 
>> wrote:
>>
>>>
>>> On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker 
>>> wrote:
>>>
 So I gave it a go on a fresh Fedora 27 VM and the binary is complaining
 that it wants libjpeg.so.9 and I have libjpeg.so.62.  I tried a symlink but
 it really wants that specific version.


>>> Well when you decide to give the build a shot again I suggest asking on
>>> the list for help from another Fedora user. VirtualT build is always a
>>> little bit of messing about to build but it always comes together after
>>> figuring out what packages and make command line to use.
>>>
>>> But I will say I’ve never had much luck with the canned binary except in
>>> Windows.
>>>
>>> Also if you just want to play in BASIC I created a JavaScript emulator
>>>
>>> http://bitchin100.com/CloudT
>>>
>>> — John.
>>>
>>
>>
>
>
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Jonathan Yuen
Hello,

Is the latest version of VirtualT 1.7?  On SourceForge?  I I had the same 
problem with the binary and libjpeg.so.9, but compiling 1.7 from source on my 
Gentoo system wasn't too bad, I just had to emerge fltk with the the 
static-libs use flag.  That system is due to be updated, it is the older gcc 
(4.9.4).  I can try it on an almost brand new one

Jonathan

jonathan.y...@mykopat.slu.se

Från: M100 [m100-boun...@lists.bitchin100.com] för Kevin Becker 
[ke...@kevinbecker.org]
Skickat: den 31 januari 2018 19:15
Till: m...@bitchin100.com
Ämne: Re: [M100] BASIC syntax question

I hadn't found CloudT before but that is very cool.

I got the precompiled VirtualT binary working on Fedora 27 by downloading the 
source from http://ijg.org and compiling it myself and then, instead of doing a 
"make install", I just copied the single libjpeg.so.9 binary to 
/usr/local/lib64/ and added that path with ldconfig.

It's working now.


On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis 
<jho...@pobox.com<mailto:jho...@pobox.com>> wrote:

On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker 
<ke...@kevinbecker.org<mailto:ke...@kevinbecker.org>> wrote:
So I gave it a go on a fresh Fedora 27 VM and the binary is complaining that it 
wants libjpeg.so.9 and I have libjpeg.so.62.  I tried a symlink but it really 
wants that specific version.


Well when you decide to give the build a shot again I suggest asking on the 
list for help from another Fedora user. VirtualT build is always a little bit 
of messing about to build but it always comes together after figuring out what 
packages and make command line to use.

But I will say I’ve never had much luck with the canned binary except in 
Windows.

Also if you just want to play in BASIC I created a JavaScript emulator

http://bitchin100.com/CloudT

— John.



Re: [M100] BASIC syntax question

2018-01-31 Thread Ken Pettit

Oop,

I think that should have been:

10 R=-1745:S=-902:POKE S,PEEK(R):POKE S+1,PEEK(R+1)

Got my R's and S's mixed up there!
Ken

On 1/31/18 11:22 AM, Ken Pettit wrote:
On M100/T102, you can seed the RND function by poking the RAM.  It is 
stored as an 8-byte floating point number represented in BCD format.  
Your first may look like garbage characters if printed, but will work 
in calculations:


10 R=-1745:S=-902:POKE R,PEEK(S):POKE R+1,PEEK(S+1)

That should seed the random number generator with about 1664 different 
possible values.


Ken

On 1/31/18 10:44 AM, Kevin Becker wrote:
Now that I haver Virtual T running, I hit my first snag on the first 
line of my program.


Is there a good way to seed the random number generator in M100 
BASIC?  The only method I've found so far is to do a for loop based 
on the "seconds" portion of the current time.  That seems 
inefficient, especially in a 10 line program.


On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker > wrote:


I hadn't found CloudT before but that is very cool.

I got the precompiled VirtualT binary working on Fedora 27 by
downloading the source from http://ijg.org and compiling it
myself and then, instead of doing a "make install", I just copied
the single libjpeg.so.9 binary to /usr/local/lib64/ and added
that path with ldconfig.

It's working now.


On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis
> wrote:


On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker
> wrote:

So I gave it a go on a fresh Fedora 27 VM and the binary
is complaining that it wants libjpeg.so.9 and I have
libjpeg.so.62.  I tried a symlink but it really wants
that specific version.


Well when you decide to give the build a shot again I suggest
asking on the list for help from another Fedora user.
VirtualT build is always a little bit of messing about to
build but it always comes together after figuring out what
packages and make command line to use.

But I will say I’ve never had much luck with the canned
binary except in Windows.

Also if you just want to play in BASIC I created a JavaScript
emulator

http://bitchin100.com/CloudT

— John.









Re: [M100] BASIC syntax question

2018-01-31 Thread Kevin Becker
So I came up with this, which seems slightly better than parsing out the
seconds portion of time$.  It gives a larger range of numbers and uses a
little less code.  Still seems like a terrible way to get a pseudo random
number though.

100 FOR I=1 TO PEEK(63791):J=RND(1):NEXT

63791 is some sort of clock-related counter that keeps cycling down from
125 to 0.


On Wed, Jan 31, 2018 at 1:54 PM, Josh Malone  wrote:

> You only need to see once I think. RND is basically terrible on these
> tiny machines, but.. hey what to you expect in 10 lines :)
>
> On Wed, Jan 31, 2018 at 1:44 PM, Kevin Becker 
> wrote:
> > Now that I haver Virtual T running, I hit my first snag on the first
> line of
> > my program.
> >
> > Is there a good way to seed the random number generator in M100 BASIC?
> The
> > only method I've found so far is to do a for loop based on the "seconds"
> > portion of the current time.  That seems inefficient, especially in a 10
> > line program.
> >
> > On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker 
> wrote:
> >>
> >> I hadn't found CloudT before but that is very cool.
> >>
> >> I got the precompiled VirtualT binary working on Fedora 27 by
> downloading
> >> the source from http://ijg.org and compiling it myself and then,
> instead of
> >> doing a "make install", I just copied the single libjpeg.so.9 binary to
> >> /usr/local/lib64/ and added that path with ldconfig.
> >>
> >> It's working now.
> >>
> >>
> >> On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis 
> >> wrote:
> >>>
> >>>
> >>> On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker 
> >>> wrote:
> 
>  So I gave it a go on a fresh Fedora 27 VM and the binary is
> complaining
>  that it wants libjpeg.so.9 and I have libjpeg.so.62.  I tried a
> symlink but
>  it really wants that specific version.
> 
> >>>
> >>> Well when you decide to give the build a shot again I suggest asking on
> >>> the list for help from another Fedora user. VirtualT build is always a
> >>> little bit of messing about to build but it always comes together after
> >>> figuring out what packages and make command line to use.
> >>>
> >>> But I will say I’ve never had much luck with the canned binary except
> in
> >>> Windows.
> >>>
> >>> Also if you just want to play in BASIC I created a JavaScript emulator
> >>>
> >>> http://bitchin100.com/CloudT
> >>>
> >>> — John.
> >>
> >>
> >
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Ken Pettit
On M100/T102, you can seed the RND function by poking the RAM.  It is 
stored as an 8-byte floating point number represented in BCD format.  
Your first may look like garbage characters if printed, but will work in 
calculations:


10 R=-1745:S=-902:POKE R,PEEK(S):POKE R+1,PEEK(S+1)

That should seed the random number generator with about 1664 different 
possible values.


Ken

On 1/31/18 10:44 AM, Kevin Becker wrote:
Now that I haver Virtual T running, I hit my first snag on the first 
line of my program.


Is there a good way to seed the random number generator in M100 
BASIC?  The only method I've found so far is to do a for loop based on 
the "seconds" portion of the current time.  That seems inefficient, 
especially in a 10 line program.


On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker > wrote:


I hadn't found CloudT before but that is very cool.

I got the precompiled VirtualT binary working on Fedora 27 by
downloading the source from http://ijg.org and compiling it myself
and then, instead of doing a "make install", I just copied the
single libjpeg.so.9 binary to /usr/local/lib64/ and added that
path with ldconfig.

It's working now.


On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis
> wrote:


On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker
> wrote:

So I gave it a go on a fresh Fedora 27 VM and the binary
is complaining that it wants libjpeg.so.9 and I have
libjpeg.so.62.  I tried a symlink but it really wants that
specific version.


Well when you decide to give the build a shot again I suggest
asking on the list for help from another Fedora user. VirtualT
build is always a little bit of messing about to build but it
always comes together after figuring out what packages and
make command line to use.

But I will say I’ve never had much luck with the canned binary
except in Windows.

Also if you just want to play in BASIC I created a JavaScript
emulator

http://bitchin100.com/CloudT

— John.







Re: [M100] BASIC syntax question

2018-01-31 Thread Josh Malone
You only need to see once I think. RND is basically terrible on these
tiny machines, but.. hey what to you expect in 10 lines :)

On Wed, Jan 31, 2018 at 1:44 PM, Kevin Becker  wrote:
> Now that I haver Virtual T running, I hit my first snag on the first line of
> my program.
>
> Is there a good way to seed the random number generator in M100 BASIC?  The
> only method I've found so far is to do a for loop based on the "seconds"
> portion of the current time.  That seems inefficient, especially in a 10
> line program.
>
> On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker  wrote:
>>
>> I hadn't found CloudT before but that is very cool.
>>
>> I got the precompiled VirtualT binary working on Fedora 27 by downloading
>> the source from http://ijg.org and compiling it myself and then, instead of
>> doing a "make install", I just copied the single libjpeg.so.9 binary to
>> /usr/local/lib64/ and added that path with ldconfig.
>>
>> It's working now.
>>
>>
>> On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis 
>> wrote:
>>>
>>>
>>> On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker 
>>> wrote:

 So I gave it a go on a fresh Fedora 27 VM and the binary is complaining
 that it wants libjpeg.so.9 and I have libjpeg.so.62.  I tried a symlink but
 it really wants that specific version.

>>>
>>> Well when you decide to give the build a shot again I suggest asking on
>>> the list for help from another Fedora user. VirtualT build is always a
>>> little bit of messing about to build but it always comes together after
>>> figuring out what packages and make command line to use.
>>>
>>> But I will say I’ve never had much luck with the canned binary except in
>>> Windows.
>>>
>>> Also if you just want to play in BASIC I created a JavaScript emulator
>>>
>>> http://bitchin100.com/CloudT
>>>
>>> — John.
>>
>>
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Kevin Becker
Now that I haver Virtual T running, I hit my first snag on the first line
of my program.

Is there a good way to seed the random number generator in M100 BASIC?  The
only method I've found so far is to do a for loop based on the "seconds"
portion of the current time.  That seems inefficient, especially in a 10
line program.

On Wed, Jan 31, 2018 at 1:15 PM, Kevin Becker  wrote:

> I hadn't found CloudT before but that is very cool.
>
> I got the precompiled VirtualT binary working on Fedora 27 by downloading
> the source from http://ijg.org and compiling it myself and then, instead
> of doing a "make install", I just copied the single libjpeg.so.9 binary to
> /usr/local/lib64/ and added that path with ldconfig.
>
> It's working now.
>
>
> On Wed, Jan 31, 2018 at 11:56 AM, John R. Hogerhuis 
> wrote:
>
>>
>> On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker 
>> wrote:
>>
>>> So I gave it a go on a fresh Fedora 27 VM and the binary is complaining
>>> that it wants libjpeg.so.9 and I have libjpeg.so.62.  I tried a symlink but
>>> it really wants that specific version.
>>>
>>>
>> Well when you decide to give the build a shot again I suggest asking on
>> the list for help from another Fedora user. VirtualT build is always a
>> little bit of messing about to build but it always comes together after
>> figuring out what packages and make command line to use.
>>
>> But I will say I’ve never had much luck with the canned binary except in
>> Windows.
>>
>> Also if you just want to play in BASIC I created a JavaScript emulator
>>
>> http://bitchin100.com/CloudT
>>
>> — John.
>>
>
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Ken Pettit
Yeah, I saw that 80-character line category.  It made me wonder on the 
Model T if that means 80 LCD characters or 80 RAM characters. For 
instance, PRINT takes 5 LCD characters but only 1 RAM byte since it is 
encoded.


Ken

On 1/31/18 10:05 AM, Josh Malone wrote:

There are some really impressive ones in the 2017 and 2016 archives -
but mostly for Atari, C64 or MSX. I'm trying to figure it out, too :)
A lot of the games only use 80-char lines, too.

On Wed, Jan 31, 2018 at 1:00 PM, Ken Pettit  wrote:

Ahh, if that is the case, then I guess this trick won't work as it requres
either 4 or 5 bytes of "self-written" ML code.  I couldn't find any
"Microsoft-written" ROM code to which one could jump which will perform the
same function.

I'm still trying to figure out how you write a game in only 10 lines of
code.  Typically if a program has anything less than 30,000 lines, I don't
even think about writing it!  ;)

Ken


On 1/30/18 7:57 PM, John R. Hogerhuis wrote:

Yeah based on those guidelines I would interpret self written as any non
rom code. I think Ken is interpreting it as a prohibition on self modifying
code.

I suspect if you fiddle with for loops you can do anything with a for loop
and calculations you can with if else statements. So you can probably
accomplish the same thing just with more code.

— John.






Re: [M100] BASIC syntax question

2018-01-31 Thread Josh Malone
There are some really impressive ones in the 2017 and 2016 archives -
but mostly for Atari, C64 or MSX. I'm trying to figure it out, too :)
A lot of the games only use 80-char lines, too.

On Wed, Jan 31, 2018 at 1:00 PM, Ken Pettit  wrote:
> Ahh, if that is the case, then I guess this trick won't work as it requres
> either 4 or 5 bytes of "self-written" ML code.  I couldn't find any
> "Microsoft-written" ROM code to which one could jump which will perform the
> same function.
>
> I'm still trying to figure out how you write a game in only 10 lines of
> code.  Typically if a program has anything less than 30,000 lines, I don't
> even think about writing it!  ;)
>
> Ken
>
>
> On 1/30/18 7:57 PM, John R. Hogerhuis wrote:
>>
>> Yeah based on those guidelines I would interpret self written as any non
>> rom code. I think Ken is interpreting it as a prohibition on self modifying
>> code.
>>
>> I suspect if you fiddle with for loops you can do anything with a for loop
>> and calculations you can with if else statements. So you can probably
>> accomplish the same thing just with more code.
>>
>> — John.
>
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Ken Pettit
Ahh, if that is the case, then I guess this trick won't work as it 
requres either 4 or 5 bytes of "self-written" ML code.  I couldn't find 
any "Microsoft-written" ROM code to which one could jump which will 
perform the same function.


I'm still trying to figure out how you write a game in only 10 lines of 
code.  Typically if a program has anything less than 30,000 lines, I 
don't even think about writing it!  ;)


Ken

On 1/30/18 7:57 PM, John R. Hogerhuis wrote:
Yeah based on those guidelines I would interpret self written as any 
non rom code. I think Ken is interpreting it as a prohibition on self 
modifying code.


I suspect if you fiddle with for loops you can do anything with a for 
loop and calculations you can with if else statements. So you can 
probably accomplish the same thing just with more code.


— John.




Re: [M100] BASIC syntax question

2018-01-31 Thread John R. Hogerhuis
Oh yeah.

Files are staged on a virtualized tape. From basic, CLOAD or CLOADM.

I think from applications you can specify CAS: to load from cassette.

— John.

On Wed, Jan 31, 2018 at 9:45 AM Jim Anderson  wrote:

> > -Original Message-
> >
> > Also if you just want to play in BASIC I created a JavaScript emulator
> >
> > http://bitchin100.com/CloudT
>
> Very cool.  I'm having trouble figuring out how the mechanism for getting
> files in/out of the VM is supposed to work.  I can stage or create files
> which show up at the bottom of the page, and download them to my local PC,
> but how do I get them into the VM's filesystem?
>
>
>
>
>
>
>
> jim
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Jim Anderson
> -Original Message-
> 
> Also if you just want to play in BASIC I created a JavaScript emulator
> 
> http://bitchin100.com/CloudT

Very cool.  I'm having trouble figuring out how the mechanism for getting files 
in/out of the VM is supposed to work.  I can stage or create files which show 
up at the bottom of the page, and download them to my local PC, but how do I 
get them into the VM's filesystem?







jim


Re: [M100] BASIC syntax question

2018-01-31 Thread Josh Malone
http://gkanold.wixsite.com/homeputerium/basic-10liners-2018.

Contest runs until March 24 so plenty of time!

My challenge with 2048 was implementing the tile sliding mechanics. I
can't find a way to use a single routine for both horizontal and
vertical sliding, and my slide-and-merge routine takes 4 lines. I'll
probably still write it, but I'm looking at some other games now.

-Josh


Re: [M100] BASIC syntax question

2018-01-31 Thread John R. Hogerhuis
Btw for best results with CloudT use Chrome or Safari.

— John.


Re: [M100] BASIC syntax question

2018-01-31 Thread John R. Hogerhuis
On Wed, Jan 31, 2018 at 8:48 AM Kevin Becker  wrote:

> So I gave it a go on a fresh Fedora 27 VM and the binary is complaining
> that it wants libjpeg.so.9 and I have libjpeg.so.62.  I tried a symlink but
> it really wants that specific version.
>
>
Well when you decide to give the build a shot again I suggest asking on the
list for help from another Fedora user. VirtualT build is always a little
bit of messing about to build but it always comes together after figuring
out what packages and make command line to use.

But I will say I’ve never had much luck with the canned binary except in
Windows.

Also if you just want to play in BASIC I created a JavaScript emulator

http://bitchin100.com/CloudT

— John.


Re: [M100] BASIC syntax question

2018-01-31 Thread Kevin Becker
So I gave it a go on a fresh Fedora 27 VM and the binary is complaining
that it wants libjpeg.so.9 and I have libjpeg.so.62.  I tried a symlink but
it really wants that specific version.




On Wed, Jan 31, 2018 at 9:56 AM, Kevin Becker  wrote:

> I feel like I tried the binary at one point and had some sort of issue,
> but maybe I just dove right into the source.  I messed with it for a while
> at one point and don't even remember where I gave up.  I'm running Fedora
> 27.  I don't have my laptop at work with me but I'm setting up a fresh
> Fedora VM right now so I can get paid to figure it out, lol.
>
>
>
> On Tue, Jan 30, 2018 at 9:48 PM, Josh Malone 
> wrote:
>
>> There are binaries for VT for Linux now. Unless you have a really
>> weird Linux distro, it should work.
>>
>> On Tue, Jan 30, 2018 at 9:33 PM,   wrote:
>> > Sounds fun.  I might enter but I doubt my entry would be very
>> > impressive.  Now I finally need to sit down figure out how to compile
>> > VirtualT on my linux machine.
>> >
>> > On Tue, 2018-01-30 at 19:39 -0500, Josh Malone wrote:
>> >> Hi all,
>> >>
>> >> The 2018 Basic 10-liner contest has started and I've decided to
>> >> attempt an entry on my T102, but, I'm running into a major obstacle
>> >> in
>> >> the model-T basic syntax. It appears that the only way to end an
>> >> IF-THEN-ELSE clause is to start a new line. I can't find any way to
>> >> END IF in the 102 BASIC.
>> >>
>> >> Is there a good reference for the actual syntax of the 100/102 BASIC?
>> >> I've been through the "Applications and BASIC Reference" for the 102
>> >> and it doesn't cover the details of IF-THEN-ELSE very well.
>> >>
>> >> Is anybody else partaking in this contest?
>> >>
>> >> -Josh
>>
>
>


Re: [M100] BASIC syntax question

2018-01-31 Thread Kevin Becker
I feel like I tried the binary at one point and had some sort of issue, but
maybe I just dove right into the source.  I messed with it for a while at
one point and don't even remember where I gave up.  I'm running Fedora 27.
I don't have my laptop at work with me but I'm setting up a fresh Fedora VM
right now so I can get paid to figure it out, lol.



On Tue, Jan 30, 2018 at 9:48 PM, Josh Malone  wrote:

> There are binaries for VT for Linux now. Unless you have a really
> weird Linux distro, it should work.
>
> On Tue, Jan 30, 2018 at 9:33 PM,   wrote:
> > Sounds fun.  I might enter but I doubt my entry would be very
> > impressive.  Now I finally need to sit down figure out how to compile
> > VirtualT on my linux machine.
> >
> > On Tue, 2018-01-30 at 19:39 -0500, Josh Malone wrote:
> >> Hi all,
> >>
> >> The 2018 Basic 10-liner contest has started and I've decided to
> >> attempt an entry on my T102, but, I'm running into a major obstacle
> >> in
> >> the model-T basic syntax. It appears that the only way to end an
> >> IF-THEN-ELSE clause is to start a new line. I can't find any way to
> >> END IF in the 102 BASIC.
> >>
> >> Is there a good reference for the actual syntax of the 100/102 BASIC?
> >> I've been through the "Applications and BASIC Reference" for the 102
> >> and it doesn't cover the details of IF-THEN-ELSE very well.
> >>
> >> Is anybody else partaking in this contest?
> >>
> >> -Josh
>


Re: [M100] BASIC syntax question

2018-01-31 Thread George Rimakis
I too was looking to write a clone if 2048(it’s a game where you combine 
numbered tiles, and ultimately need to make a tile with the number 2048)

However it seemed difficult due to the screen height limitations of the 100. 
Everything would definitely be close together

~George

> On Jan 31, 2018, at 5:27 AM, VANDEN BOSSCHE JAN 
> <jan.vandenboss...@vivaqua.be> wrote:
> 
> I have 2 questions:
> 
> 1. where is that 10-lines BASIC contest, and can I still enter ?
> 
> 2. regarding your statement:
>> My original goal was to implement 2048 on the 100,
>> which I might still do, just not in 10 lines
> Implementing 2048 ???
> 
> Greetings from the TyRannoSaurus / Jan-80@work
> 
> -Original Message-
> From: M100 [mailto:m100-boun...@lists.bitchin100.com] On Behalf Of Josh Malone
> Sent: woensdag 31 januari 2018 04:52
> To: m...@bitchin100.com
> Subject: Re: [M100] BASIC syntax question
> 
> Wow. That's super clever. I had actually read the rules as
> "self-written" equating to any ML code that I wrote. So, it was legal
> to call ROM routines, but not legal to embed my own ML. But, maybe I'm
> wrong. It's clearly translated from German so reading the true intent
> is difficult.
> 
> In either case, I found a better way to write my routine but
> eventually realized that what I wanted to do wouldn't fit in 10 lines
> no matter what. (My original goal was to implement 2048 on the 100,
> which I might still do, just not in 10 lines). I'm *super* ignorant of
> ML stuff on the 100 so seeing your test code would be very cool.
> 
> I'm shooting for the PUR-80 category, since the M100 only has a
> built-in BASIC anyway :)
> 
> Thanks for the pointers!
> 
> -Josh
> 
>> On Tue, Jan 30, 2018 at 10:10 PM, Ken Pettit <petti...@gmail.com> wrote:
>> Josh,
>> 
>> Turns out it actually *IS* possible to execute code past the end of an ELSE
>> block from the IF cod block.  And I believe it doesn't violate the
>> programming contest rules.  If you are very careful that is.
>> 
>> The Rules state:
>> 
>> 2. The 10 lines must not contain any self-written machine programs
>> 3. All code must be visible in the listing: self-modifying code or hidden
>> initializations are not allowed
>> 
>> So running a machine language routine is okay as long as it is not
>> self-written or self-modifying.  Initializing A$="blah" with a 5 byte ML
>> routine and then jumping to it should be okay, so long as it doesn't modify
>> anything.  Given this, it is possible to use a CALL instruction as the last
>> operation in an IF statement and have it skip over the ELSE code.
>> 
>> A CALL operation will push the address of the next BASIC instruction to be
>> executed to the stack (normally held in HL) prior to executing the CALL.
>> You can pass parameters in A and HL as part of the CALL instruction.  So the
>> idea is to pre-calculate the number of bytes the ELSE code occupies and then
>> simply skip it by popping that "next instruction address" from the stack,
>> adding to it and simply returning.  A DAD D or DAD B instruction would be
>> needed, but these don't actually *appear* in the listing and can't be used.
>> But there is a DAD D, RET at address 4598H that can be used.  So the ML code
>> in A$ would be:
>> 
>>POP D Pop ret address
>>POP D Get BASIC line address   (These are all characters
>> that will "appear" in a listing of the program.)
>>JMP 4598H
>> 
>> 4598H:
>>DAD D   Add offset to BASIC line
>>RET   Return to BASIC execution at new line location
>> 
>> Then issue a CALL 0,offset BASIC instruction.  The only tricky part is to
>> get "offset" right or the BASIC intrepreter will get lost in it's parsing of
>> the code.  I tested this out with a simple program that I could provide.
>> 
>> Ken
>> 
>> 
>>> On 1/30/18 6:16 PM, John R. Hogerhuis wrote:
>>> 
>>> Download some The Rainbow coco magazines online. They had a one liner
>>> contest ongoing and they printed the winners to fill dead space in the
>>> magazine. Lots of tricks there.
>>> 
>>> Some things I can think of:
>>> 
>>> Compute complicated logic and do one IF then else. Traditional Microsoft
>>> basic is “unstructured” definitely no endif.
>>> Use loops even if it’s kind of inappropriate since you can have multiple
>>> loops in the same line.
>>> Tail recursion with goto. Idea is that your single conditional is at the
>>> end of the line and you go back

Re: [M100] BASIC syntax question

2018-01-31 Thread VANDEN BOSSCHE JAN
I have 2 questions:

1. where is that 10-lines BASIC contest, and can I still enter ?

2. regarding your statement:
> My original goal was to implement 2048 on the 100,
> which I might still do, just not in 10 lines
Implementing 2048 ???

Greetings from the TyRannoSaurus / Jan-80@work

-Original Message-
From: M100 [mailto:m100-boun...@lists.bitchin100.com] On Behalf Of Josh Malone
Sent: woensdag 31 januari 2018 04:52
To: m...@bitchin100.com
Subject: Re: [M100] BASIC syntax question

Wow. That's super clever. I had actually read the rules as
"self-written" equating to any ML code that I wrote. So, it was legal
to call ROM routines, but not legal to embed my own ML. But, maybe I'm
wrong. It's clearly translated from German so reading the true intent
is difficult.

In either case, I found a better way to write my routine but
eventually realized that what I wanted to do wouldn't fit in 10 lines
no matter what. (My original goal was to implement 2048 on the 100,
which I might still do, just not in 10 lines). I'm *super* ignorant of
ML stuff on the 100 so seeing your test code would be very cool.

I'm shooting for the PUR-80 category, since the M100 only has a
built-in BASIC anyway :)

Thanks for the pointers!

-Josh

On Tue, Jan 30, 2018 at 10:10 PM, Ken Pettit <petti...@gmail.com> wrote:
> Josh,
>
> Turns out it actually *IS* possible to execute code past the end of an ELSE
> block from the IF cod block.  And I believe it doesn't violate the
> programming contest rules.  If you are very careful that is.
>
> The Rules state:
>
> 2. The 10 lines must not contain any self-written machine programs
> 3. All code must be visible in the listing: self-modifying code or hidden
> initializations are not allowed
>
> So running a machine language routine is okay as long as it is not
> self-written or self-modifying.  Initializing A$="blah" with a 5 byte ML
> routine and then jumping to it should be okay, so long as it doesn't modify
> anything.  Given this, it is possible to use a CALL instruction as the last
> operation in an IF statement and have it skip over the ELSE code.
>
> A CALL operation will push the address of the next BASIC instruction to be
> executed to the stack (normally held in HL) prior to executing the CALL.
> You can pass parameters in A and HL as part of the CALL instruction.  So the
> idea is to pre-calculate the number of bytes the ELSE code occupies and then
> simply skip it by popping that "next instruction address" from the stack,
> adding to it and simply returning.  A DAD D or DAD B instruction would be
> needed, but these don't actually *appear* in the listing and can't be used.
> But there is a DAD D, RET at address 4598H that can be used.  So the ML code
> in A$ would be:
>
> POP D Pop ret address
> POP D Get BASIC line address   (These are all characters
> that will "appear" in a listing of the program.)
> JMP 4598H
>
> 4598H:
> DAD D   Add offset to BASIC line
> RET   Return to BASIC execution at new line location
>
> Then issue a CALL 0,offset BASIC instruction.  The only tricky part is to
> get "offset" right or the BASIC intrepreter will get lost in it's parsing of
> the code.  I tested this out with a simple program that I could provide.
>
> Ken
>
>
> On 1/30/18 6:16 PM, John R. Hogerhuis wrote:
>>
>> Download some The Rainbow coco magazines online. They had a one liner
>> contest ongoing and they printed the winners to fill dead space in the
>> magazine. Lots of tricks there.
>>
>> Some things I can think of:
>>
>> Compute complicated logic and do one IF then else. Traditional Microsoft
>> basic is “unstructured” definitely no endif.
>> Use loops even if it’s kind of inappropriate since you can have multiple
>> loops in the same line.
>> Tail recursion with goto. Idea is that your single conditional is at the
>> end of the line and you go back to the same line or proceed to the next
>> line.
>> I think the Basic Stack is pretty limited for actual GOSUB recursion but
>> you could try it
>> Model 100 basic has some ability to create interrupt / events handlers.
>> For example, on serial data. I think maybe keys and timers too.
>> On goto / on GOSUB are good for major control flow.
>> I don’t know if your contest has limitations on embedded ML. Of course in
>> ml you can do any possible control flow.  You can embed machine code using
>> data statements or, more efficiently as static strings, dynamic strings or
>> REM statements.
>> Also there’s the ROM you can call into.
>>
>> — John.
>>
>>
>
VIVAQUA et HYDROBRU ont fusionné.
VIVAQUA est votre société d'eau e

Re: [M100] BASIC syntax question

2018-01-30 Thread John R. Hogerhuis
Yeah based on those guidelines I would interpret self written as any non
rom code. I think Ken is interpreting it as a prohibition on self modifying
code.

I suspect if you fiddle with for loops you can do anything with a for loop
and calculations you can with if else statements. So you can probably
accomplish the same thing just with more code.

— John.


Re: [M100] BASIC syntax question

2018-01-30 Thread Josh Malone
Wow. That's super clever. I had actually read the rules as
"self-written" equating to any ML code that I wrote. So, it was legal
to call ROM routines, but not legal to embed my own ML. But, maybe I'm
wrong. It's clearly translated from German so reading the true intent
is difficult.

In either case, I found a better way to write my routine but
eventually realized that what I wanted to do wouldn't fit in 10 lines
no matter what. (My original goal was to implement 2048 on the 100,
which I might still do, just not in 10 lines). I'm *super* ignorant of
ML stuff on the 100 so seeing your test code would be very cool.

I'm shooting for the PUR-80 category, since the M100 only has a
built-in BASIC anyway :)

Thanks for the pointers!

-Josh

On Tue, Jan 30, 2018 at 10:10 PM, Ken Pettit  wrote:
> Josh,
>
> Turns out it actually *IS* possible to execute code past the end of an ELSE
> block from the IF cod block.  And I believe it doesn't violate the
> programming contest rules.  If you are very careful that is.
>
> The Rules state:
>
> 2. The 10 lines must not contain any self-written machine programs
> 3. All code must be visible in the listing: self-modifying code or hidden
> initializations are not allowed
>
> So running a machine language routine is okay as long as it is not
> self-written or self-modifying.  Initializing A$="blah" with a 5 byte ML
> routine and then jumping to it should be okay, so long as it doesn't modify
> anything.  Given this, it is possible to use a CALL instruction as the last
> operation in an IF statement and have it skip over the ELSE code.
>
> A CALL operation will push the address of the next BASIC instruction to be
> executed to the stack (normally held in HL) prior to executing the CALL.
> You can pass parameters in A and HL as part of the CALL instruction.  So the
> idea is to pre-calculate the number of bytes the ELSE code occupies and then
> simply skip it by popping that "next instruction address" from the stack,
> adding to it and simply returning.  A DAD D or DAD B instruction would be
> needed, but these don't actually *appear* in the listing and can't be used.
> But there is a DAD D, RET at address 4598H that can be used.  So the ML code
> in A$ would be:
>
> POP D Pop ret address
> POP D Get BASIC line address   (These are all characters
> that will "appear" in a listing of the program.)
> JMP 4598H
>
> 4598H:
> DAD D   Add offset to BASIC line
> RET   Return to BASIC execution at new line location
>
> Then issue a CALL 0,offset BASIC instruction.  The only tricky part is to
> get "offset" right or the BASIC intrepreter will get lost in it's parsing of
> the code.  I tested this out with a simple program that I could provide.
>
> Ken
>
>
> On 1/30/18 6:16 PM, John R. Hogerhuis wrote:
>>
>> Download some The Rainbow coco magazines online. They had a one liner
>> contest ongoing and they printed the winners to fill dead space in the
>> magazine. Lots of tricks there.
>>
>> Some things I can think of:
>>
>> Compute complicated logic and do one IF then else. Traditional Microsoft
>> basic is “unstructured” definitely no endif.
>> Use loops even if it’s kind of inappropriate since you can have multiple
>> loops in the same line.
>> Tail recursion with goto. Idea is that your single conditional is at the
>> end of the line and you go back to the same line or proceed to the next
>> line.
>> I think the Basic Stack is pretty limited for actual GOSUB recursion but
>> you could try it
>> Model 100 basic has some ability to create interrupt / events handlers.
>> For example, on serial data. I think maybe keys and timers too.
>> On goto / on GOSUB are good for major control flow.
>> I don’t know if your contest has limitations on embedded ML. Of course in
>> ml you can do any possible control flow.  You can embed machine code using
>> data statements or, more efficiently as static strings, dynamic strings or
>> REM statements.
>> Also there’s the ROM you can call into.
>>
>> — John.
>>
>>
>


Re: [M100] BASIC syntax question

2018-01-30 Thread Josh Malone
There are binaries for VT for Linux now. Unless you have a really
weird Linux distro, it should work.

On Tue, Jan 30, 2018 at 9:33 PM,   wrote:
> Sounds fun.  I might enter but I doubt my entry would be very
> impressive.  Now I finally need to sit down figure out how to compile
> VirtualT on my linux machine.
>
> On Tue, 2018-01-30 at 19:39 -0500, Josh Malone wrote:
>> Hi all,
>>
>> The 2018 Basic 10-liner contest has started and I've decided to
>> attempt an entry on my T102, but, I'm running into a major obstacle
>> in
>> the model-T basic syntax. It appears that the only way to end an
>> IF-THEN-ELSE clause is to start a new line. I can't find any way to
>> END IF in the 102 BASIC.
>>
>> Is there a good reference for the actual syntax of the 100/102 BASIC?
>> I've been through the "Applications and BASIC Reference" for the 102
>> and it doesn't cover the details of IF-THEN-ELSE very well.
>>
>> Is anybody else partaking in this contest?
>>
>> -Josh


Re: [M100] BASIC syntax question

2018-01-30 Thread kevin
Sounds fun.  I might enter but I doubt my entry would be very
impressive.  Now I finally need to sit down figure out how to compile
VirtualT on my linux machine.

On Tue, 2018-01-30 at 19:39 -0500, Josh Malone wrote:
> Hi all,
> 
> The 2018 Basic 10-liner contest has started and I've decided to
> attempt an entry on my T102, but, I'm running into a major obstacle
> in
> the model-T basic syntax. It appears that the only way to end an
> IF-THEN-ELSE clause is to start a new line. I can't find any way to
> END IF in the 102 BASIC.
> 
> Is there a good reference for the actual syntax of the 100/102 BASIC?
> I've been through the "Applications and BASIC Reference" for the 102
> and it doesn't cover the details of IF-THEN-ELSE very well.
> 
> Is anybody else partaking in this contest?
> 
> -Josh


Re: [M100] BASIC syntax question

2018-01-30 Thread John R. Hogerhuis
Download some The Rainbow coco magazines online. They had a one liner
contest ongoing and they printed the winners to fill dead space in the
magazine. Lots of tricks there.

Some things I can think of:

Compute complicated logic and do one IF then else. Traditional Microsoft
basic is “unstructured” definitely no endif.
Use loops even if it’s kind of inappropriate since you can have multiple
loops in the same line.
Tail recursion with goto. Idea is that your single conditional is at the
end of the line and you go back to the same line or proceed to the next
line.
I think the Basic Stack is pretty limited for actual GOSUB recursion but
you could try it
Model 100 basic has some ability to create interrupt / events handlers. For
example, on serial data. I think maybe keys and timers too.
On goto / on GOSUB are good for major control flow.
I don’t know if your contest has limitations on embedded ML. Of course in
ml you can do any possible control flow.  You can embed machine code using
data statements or, more efficiently as static strings, dynamic strings or
REM statements.
Also there’s the ROM you can call into.

— John.


Re: [M100] BASIC syntax question

2018-01-30 Thread Ken Pettit

Hi Josh,

Can't be done.  The BASIC ROM will either execute everything between 
"IF" and "ELSE" or everything after "ELSE" to the end of the line. The 
best you could do is put your code that you want to run unconditionally 
after the imaginary "END IF" in a separate line/lines and call GOSUB 
from both the "IF" code block as well as the "ELSE" code block.


10 IF A=1THEN B=2:GOSUB50:PRINT"DO SOME MORE STUFF":GOSUB80 ELSE 
B=3:GOSUB50:PRINT "DO SOME DIFFERENT STUFF":GOSUB80


50 IFB=2THEN PRINT"Do stuff when B is 2":RETURN:ELSE PRINT"Do stuff when 
B is 3":RETURN

80 ETC.

Ken

On 1/30/18 4:39 PM, Josh Malone wrote:

Hi all,

The 2018 Basic 10-liner contest has started and I've decided to
attempt an entry on my T102, but, I'm running into a major obstacle in
the model-T basic syntax. It appears that the only way to end an
IF-THEN-ELSE clause is to start a new line. I can't find any way to
END IF in the 102 BASIC.

Is there a good reference for the actual syntax of the 100/102 BASIC?
I've been through the "Applications and BASIC Reference" for the 102
and it doesn't cover the details of IF-THEN-ELSE very well.

Is anybody else partaking in this contest?

-Josh