So long and thanks for all the fishes
Pages: 1 2
Steve Pampling (1551) 8170 posts |
Hmm, I showed the item to my wife, and she laughed almost immediately. That’s what long association with a character like me does to people. |
Rick Murray (539) 13840 posts |
Wait, Steve’s wife got the binary joke? Oh, Clive, the shame, the shame… :-) :-) PS: I’d like to think mom would have got it too. Same reason as you Steve, some nerdiness rubs off. Just wait for the day she argues with somebody (like in a supermarket) that their router is the problem, and is correct (mom, local library, several times 1). 1 Stupid woman would rather have the taxpayer cough up a hundred euros to have some guy come out to fix it, rather than following our suggestion of turning it off and back on again. Guess what the expensive technician did within one minute of arrival, handed her a paper, and left. |
Clive Semmens (2335) 3276 posts |
As you say, the shame 8~( 8~( At least I’m in good company – unless Mr Ruck is just providing kindly solidarity! |
Steve Drain (222) 1620 posts |
;-) It is fire-fighting, quashing unattractive code so it does not set a bad example. That does set me up for a fall, though. Some of the things I do with BASIC would scare the pants off the community. ;-) |
Clive Semmens (2335) 3276 posts |
Hear, hear! My sentiments/behaviour exactly. |
Steve Drain (222) 1620 posts |
You want arcane; you could not stand arcane: DEFFNBinString(|&8300):REM removes leading zeros SYS"OS_ConvertBinary4",|&8300,&8310,33 TO $&8310 =$(&83B0-?&8304) ;-) |
Rick Murray (539) 13840 posts |
Whuh? So on a 32 bit machine you allocate sufficient space for a 16 bit value and then issue a call that only outputs 8 bit values? My head hurts. |
Steve Pampling (1551) 8170 posts |
Blow the dust off that one. |
Stuart Swales (1481) 351 posts |
MODE 28? Luxury! |
Steve Pampling (1551) 8170 posts |
M.P.F.C – Yorkshiremen. The follow-up line to Stuarts comment should be along the lines of “We used t’ dream of Mode 28” |
Rick Murray (539) 13840 posts |
Mode 28?! We used t’ dream of colour. |
Stuart Swales (1481) 351 posts |
Eeh, we had to make do with black-and-black displays. Lick chalkboard clean wi’t tongue. |
Steve Pampling (1551) 8170 posts |
I’m afraid you’re still missing the running joke, but it’s too much fun to give you more than the pointers we already have. TV. M.P.F.C – Yorkshiremen. Oh, and Stuart is slightly off – it would be closer written as: “Eee, we had t’ make do wi’ black-and-black displays. Lick t’ chalkboard clean wi’ t’ tongue.” Plus, the likes of t’ are actually not a pronounced "t |
David J. Ruck (33) 1635 posts |
Chalkboard? You don’t know you were born, we had to get up at 4am, be beaten wi’ belt by our dad, sent to work down pit to mine coal for the black pixels, beaten wi’ broken bottle by our dad, and have to scrape lines off middle t’ motorway in rush hour for the white pixels, when we got home our Dad would slice us in two wit’ bread knife. |
Steve Pampling (1551) 8170 posts |
Definitely made it to the US The origin of Spam, spam, spam… That’s it for me. Good night |
Paolo Fabio Zaino (28) 1882 posts |
He is back!!!! :D You know who1 has returned! :) 1 because he said shhh in another post, and that he is lurking… |
Chris Hall (132) 3554 posts |
Still do not have the entire picture. It is a Python reference. Google is your friend – look up ‘Python’ and ‘lived in a shoe box’ or ‘The Four Yorkshireman’. It relies on cultural references to traits of thos who live in Yorkshire… |
Stuart Swales (1481) 351 posts |
Python 3? |
Chris Hall (132) 3554 posts |
I think it may have been before Python 1. |
Steve Drain (222) 1620 posts |
Sorry folks, but this has been buzzing round my head and it has to get out. ;-(
Here is an assembly routine for the binary string. It is just as written, but I have stripped out the comments: PROCUSR_BinStr PRINT USR_BinStr,-200.1 END DEFPROCUSR_BinStr _BinStr=_BinStr:LOCAL zero,char,return FOR F%=0 TO 2 STEP 2:P%=END:[OPT F% ._BinStr STR lr,[sp,#-4]! LDR r11,[sp,#16] ADD r11,r11,#1 LDR r10,[sp] MOV lr,pc ADD pc,r10,#&44 SUB r11,r11,#1 STR r11,[sp,#16] SUB r6,r8,#&600 MOV r7,#ASC"0" MOVeq r2,r6 Beq return LDRmi r10,[sp] MOVmi lr,pc ADDmi pc,r10,#&74 TEQ r0,#0 MOVeq r2,r6 STReqB r7,[r2],#1 Beq return ADD r1,r6,#&40 MOV r2,#&21 SWI "OS_ConvertBinary4" .zero LDRB r1,[r0],#1 TEQ r1,r7 Beq zero MOV r2,r6 STRB r1,[r2],#1 .char LDRB r1,[r0],#1 STRB r1,[r2],#1 TEQ r1,#0 Bne char .return STR pc,[sp,#24] MOV r9,#0 LDR pc,[sp],#4 ]:NEXT F%:!&8674=P% ENDPROC
Note that USR here takes a parameter and returns a string! There is quite a lot in there that might actually be useful in a general sense for those writing code interacting with BASIC. |
Colin Ferris (399) 1814 posts |
Would this be any different in ARM 64- except for the moveq etc? |
Steve Drain (222) 1620 posts |
Should I say touché or answer sensibly and say that the code is so intimately tied into BASIC that ARM 64 is impossible? ;-) |
Pages: 1 2