ApplesSoft BASIC code which includes assembly language: Twitter bot AppleIIBot could run it!
Posted by jpluimers on 2024/03/20
This was a trip down memory lane where I was totally unaware that you could embed 6502 assembly language inside AppleSoft BASIC code.
It turns you can, and even better: the Twitter bot named AppleIIBot could execute it too!
Though I bumped into AppleIIBot during winter 2021, I published the BBC equivalent last week (see BBC trip down memory lane – 8bitkick/BBCMicroBot: Runs your tweet on an 8-bit computer emulator) as that one got released earlier.
For the moment it is down because Elon blew up Twitter and shut down on 2022-11-05, but hopefully – like the BBC equivalent – it will resurface on a Mastodon instance somewhere in the future.
Luckily all old Tweets with code and rendering are still there, though you need a Twitter account to view them: Elon broke the feature of anonymous access seeing all messages in a thread.
Below the signature are the full Tweets that led me into it; the texts are these:
- [Wayback/Archive] Jason Scott on Twitter: “Ha ha holy fuck”
- [Wayback/Archive] Jason Scott on Twitter: “This is the BASIC program he sent the bot”
- [Wayback/Archive] deater on Twitter: “@AppleIIBot
{B11}1FORI=0TO139:POKE876+I,4*PEEK(2125+I)-192+(PEEK(2265+I/3)-35)/4^(I-INT(I/3)*3):NEXT2&",=n9D`V/QfOoP.QaNnUnInQoRmIbNnPBT0XlTU3O;8=mY9X0PnQmJ0N9VBmQjXnDnQmYnCnQlR>em9n:le/Z,:ZbQ<63nb`:bejh0SU0CK0CH0S+4HE[4(@Y-&U+6&''0@:8(<+4*?3'+#+#:8H4M.X'#40//“
- [Wayback/Archive] deater on Twitter: “@AppleIIBot
The bot ran from [Wayback/Archive] Apple II BASIC Bot (@AppleIIBot) / Twitter and supported both AppleSoft BASIC and Apple LOGO.
Run your Applesoft BASIC or Apple Logo code on an Apple II in Twitter. By @KaySavetz. (No sound yet.) Documentation at http://appleiibot.com
- [Wayback/Archive] Kay Savetz on Twitter: “@AppleIIBot
{L}to squarerepeat 4 [ fd 60 rt 90]endrepeat 10 [ square rt 36]“ - [Wayback/Archive] Apple II BASIC Bot on Twitter: “@KaySavetz …”
Given Elon blew up Twitter, the bot went out with a blast:
- [Waybacksave/Archive] deater on X: “@AppleIIBot 0REM…:GOTO5” / X
0REM~/$5*>0E3O4P-R(V$["d"h$k&t$o+w)o1o:lChKdQ_V[YS]H`=`4^*Y2Y;V@S;Q7O4K3H9H4E0A-;-70939/4-.-*/$! 1HGR2:HCOLOR=6:DEFFNP(X)=3*PEEK(2054+I+X)-99 2IFFNP(0)=279THENHPLOTFNP(1),FNP(2):I=I+3 4HPLOTTOFNP(0),FNP(1):I=I+2:IFFNP(0)GOTO2 5HCOLOR=5:HPLOTRND(1)*279,RND(1)*192TO140,96:GOTO5
- [Wayback/Archive] Apple II BASIC Bot on X: “@deater78”
[Wayback/Archive] video.twimg.com/ext_tw_video/1588678211571154944/pu/vid/364×270/jid0Xz9s7x4J79mH.mp4
(Larger images below the signature)
Like BBCMicroBot, it is open source and has documentation. However unlike BBCMicroBot there are other bots from the same person for BASIC dialects on Atari and PC as well.
So here are some more links:
[Wayback/Archive] savetz/AppleIIBot: The code that runs the Apple II Twitter bot at https://twitter.com/AppleIIBot
- [Wayback/Archive] @AppleIIBot – How to play with @AppleIIBot on Twitter
Send a tweet with a short program to @AppleIIBot and your program will run on an emulated Apple II computer. The bot will tweet you back with a video your program’s output!
…
- [Wayback/Archive] About the bot – @AppleIIBot
AppleIIBot is made by @KaySavetz. They took inspiration from @BBCMicroBot (which does a similar thing but with an emulated BBC Micro, a computer that was popular in the United Kingdom.) Kay also maintains Atari8BitBot and PCBasicBot.
…
- [Wayback/Archive] Apple Logo – @AppleIIBot
Logo is a fun language that was created to teach new programmers. The language was developed in 1967, the word logo derived from the Greek logos, meaning thought. Logo is best known for its “turtle graphics” — where the programmer can draw lines and shapes by controlling an on-screen “turtle. The bot runs Apple Logo II, which was released in 1984.
[Wayback/Archive] savetz/Atari8BitBot: Code that runs the Atari 8-bit Twitter bot at https://twitter.com/Atari8BitBot
- [Wayback/Archive] Atari 8-bit Bot (@Atari8BitBot) / Twitter
A bot by @KaySavetz & pals. Tweet Atari BASIC, TurboBASIC XL, Logo, PILOT, Action! or Assembly code and I’ll run it on an Atari 8bit. (Now with sound support!)
- [Wayback/Archive] Atari 8 Bit Bot – How to play with @Atari8BitBot on Twitter
Send a tweet with a short program to @Atari8BitBot and your program will run on an emulated Atari 8-bit computer. The bot will tweet you back with a video your program’s output!
and half a dozen more documentation pages.
[Wayback/Archive] savetz/PCBASICBot: The code that runs the PC BASIC bot at https://twitter.com/PCBASICBot
- [Wayback/Archive] PC BASIC Bot (@PCBASICBot) / Twitter
Tweet GW-BASIC code (default) or QBASIC code (use {Q} directive) at me and I’ll run it. No sound support. A project of @KaySavetz
- [Wayback/Archive] PC Basic Bot – How to play with @PCBASICBot on Twitter
Send a tweet with a short BASIC program to @PCBASICBot and your program will run on an emulated DOS PC. The bot will tweet you back with a video your program’s output!
The bot accepts programs in GW-BASIC by default (whose code is 100% compatible with BASICA). It also accepts programs in QBASIC: to do this, just start your tweet with {Q}
…
- [Wayback/Archive] visy ~ AbraKitten on Twitter: “@PCBASICBot
{Q}SCREEN 13:COLOR 16:PRINT "PCBASICBot" FOR y=0 TO 6: FOR x=0 TO 80: FOR i=1 TO 3: o=20+i*32 LINE(x*4,o+y*4)-(x*4+4,o+y*4+4),POINT(x,y)+(i+16),BF NEXT:NEXT:NEXT:LOCATE 1,1:a=969 FOR f=0 TO 512:OUT a-1,1:FOR j=1 TO 255 OUT a,f+j:OUT a,f+j+32:OUT a,f+j+64 NEXT:NEXT“ - [Wayback/Archive] PC BASIC Bot on Twitter: “@notyourusualcup”
AppleIIBot examples
Deater does has posted many cool scripts, for instance:
- [Wayback/Archive] deater on Twitter: “@AppleIIBot
10 GR:COLOR=920 FOR X=0 TO 3930 POKE 2138,X40 FOR Y=0 TO X 50 POKE 2140,Y:CALL 213760 PLOT X,PEEK(36)70 NEXT Y,X100 SPEED=$)L$`” / Twitter - [Wayback/Archive] deater on Twitter: “@AppleIIBot
1FORI=0TO143:POKE1013+I,4*PEEK(2126+I)-192+(PEEK(2270+I/3)-35)/4^(I-INT(I/3)*3):NEXT2&",clYe8jlQ0RQ`X0JhZ%NoW56F1QmZX#Vo74mU/^I16?=ZT0Z,70ki0U/Yo`7b1QbWoPo`,ac^l?4:1-?99=06=?1->0Y1-79:10389/-8900.00(02/80'02*21(38%/8%/3+-8(02.46'17S(/#G@W04,W'3#P33-3$+Z(T[7/,/UG/0VT#+M1L@W^^UM5Q" - [Wayback/Archive] deater on Twitter: “need to come up with a better place to display these @demosplash trophies”
Others too, for instance the fire at [Wayback/Archive] Roberto Peña on Twitter: “@AppleIIBot 1 FOR X=768TO832:READ A:POKE X,A:NEXT:CALL 768:DATA 44,80,192,44,82,192,32,112,252,169,255,145,42,136,16,251,169,22,133,37,32,34,252,160,39,104,240,5,10,240,4,144,2,73,29,72,48,10,177,40,41,7,170,189,57,3,145,40,136,16,230,198,37,16,221,48,205,0,187,0,170,0,153,0,221“
--jeroen
The blast
- [Wayback/Archive] video.twimg.com/ext_tw_video/1588678211571154944/pu/vid/364×270/jid0Xz9s7x4J79mH.mp4
- [Wayback/Archive] video.twimg.com/ext_tw_video/1588678211571154944/pu/vid/484×360/4jU3htO-XaNrR9y7.mp4
- [Wayback/Archive] video.twimg.com/ext_tw_video/1588678211571154944/pu/vid/850×630/yYoWWRnA3mXgW0oo.mp4
The tweets
Ha ha holy fuck https://t.co/1VGIgT8rhY
— Jason Scott (@textfiles) January 31, 2021
— Apple II BASIC Bot (@AppleIIBot) January 27, 2021
— Apple II BASIC Bot (@AppleIIBot) January 26, 2021
— Apple II BASIC Bot (@AppleIIBot) January 18, 2021
need to come up with a better place to display these @demosplash trophies pic.twitter.com/meAioHi5TS
— deater (@deater78) January 26, 2021
— Apple II BASIC Bot (@AppleIIBot) November 4, 2022
Rate this:
Share this:
- Click to share on Mastodon (Opens in new window) Mastodon
- Click to share on Bluesky (Opens in new window) Bluesky
- Share on Tumblr
- Click to share on Reddit (Opens in new window) Reddit
- Click to share on Threads (Opens in new window) Threads
- Tweet
- Click to share on Telegram (Opens in new window) Telegram
- Click to share on Nextdoor (Opens in new window) Nextdoor
- Click to share on WhatsApp (Opens in new window) WhatsApp
- Click to print (Opens in new window) Print
- Click to email a link to a friend (Opens in new window) Email
Related
This entry was posted on 2024/03/20 at 12:00 and is filed under //e, 6502, Apple, Apple ][, BASIC, Development, History, SocialMedia, Software Development, Twitter. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.
This site uses Akismet to reduce spam. Learn how your comment data is processed.











Leave a comment