6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Tue Apr 30, 2024 6:17 am

All times are UTC




Post new topic Reply to topic  [ 18 posts ]  Go to page Previous  1, 2
Author Message
PostPosted: Sat Jan 09, 2016 3:32 pm 
Offline

Joined: Sat Dec 12, 2015 7:48 pm
Posts: 123
Location: Lake Tahoe
If you're interested in the floating point routines I wrote for VM02, The Apple II Java VM, the opcode implementation is here:

http://vm02.cvs.sourceforge.net/viewvc/ ... iew=markup

Search for FLOATING_POINT. It implements the Java IEEE 32-bit format, but doesn't handle exceptional cases. Good enough for playing around, though.

Dave...


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 12, 2016 1:15 pm 
Offline

Joined: Sun Feb 23, 2014 2:43 am
Posts: 78
Thanks, I'm sure it will come in handy. I haven't tried it but VM02 looks amazing.


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 26, 2016 11:07 pm 
Offline

Joined: Sun Feb 23, 2014 2:43 am
Posts: 78
Worked on the 265SXB API over the weekend. There are routines for printing text, keyboard input, and I/O ports. The demo project (subject to change) currently prints some text and flashes an LED when a button is pressed:

https://github.com/mikeakohn/java_grind ... nkLED.java

Printing signed integers was a challenge. I borrowed an algorithm from a stack overflow answer (lost the link, sorry), which uses repeated subtraction to divide by 10000, 1000, 100, 10, etc. It's still pretty rough, but here it is anyway:

https://github.com/mikeakohn/java_grind ... B.cxx#L155

Edit: found the algorithm:
http://electronics.stackexchange.com/qu ... 2633#12633


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 18 posts ]  Go to page Previous  1, 2

All times are UTC


Who is online

Users browsing this forum: AndrewP, Firefox6502, Yuri and 28 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: