A Compiler for Pocket Calculators
|
01-24-2017, 06:41 AM
Post: #8
|
|||
|
|||
RE: A Compiler for Pocket Calculators
Hi all,
I thought I might have a go at one so I uploaded a simple basic compiler for the HP-65 - available at teenix.org. It bound to have a bug or two as it is hard to traverse the maze of twists and turns the software could take depending on what source code is entered. Two files are created, one that is compatible with the CCE33 HP65 emulator and a text file as shown below. As a simple example loop(A, 3) // Label A - loop 3 times a=a+1 // just increment reg a endloop b=a+(2*c+LN(23.5)*e)/2 // fancy calculation stop Output... 1. 3 2. STO 8 3. LBL 4. A 5. RCL 1 6. 1 7. + 8. STO 1 9. g 10. . 11. GTO 12. A 13. RCL 1 14. 2 15. RCL 2 16. * 17. 2 18. 3 19. . 20. 5 21. f 22. 7 23. RCL 3 24. * 25. + 26. 2 27. / 28. + 29. STO 4 30. R/S cheers Tony |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
A Compiler for Pocket Calculators - Don Shepherd - 01-12-2017, 07:44 PM
RE: A Compiler for Pocket Calculators - toml_12953 - 01-13-2017, 01:16 AM
RE: A Compiler for Pocket Calculators - Don Shepherd - 01-13-2017, 02:57 AM
RE: A Compiler for Pocket Calculators - Marc van Lemmen - 01-15-2017, 09:59 PM
RE: A Compiler for Pocket Calculators - SlideRule - 01-16-2017, 02:26 AM
RE: A Compiler for Pocket Calculators - NetMage - 01-15-2017, 07:14 AM
RE: A Compiler for Pocket Calculators - Don Shepherd - 01-15-2017, 01:40 PM
RE: A Compiler for Pocket Calculators - teenix - 01-24-2017 06:41 AM
|
User(s) browsing this thread: