Hardware Parameters.c 871 B

12345678910111213141516171819202122232425262728
  1. // Return the hardware parameter block as a list
  2. #define USE_TI89 // Compile for TI-89
  3. #define USE_TI92PLUS // Compile for TI-92 Plus
  4. #define USE_V200 // Compile for V200
  5. #define RETURN_VALUE // Return Pushed Expression
  6. #define MIN_AMS 100 // Compile for AMS 1.00 or higher
  7. #include <tigcclib.h> // Include All Header Files
  8. // Main Function
  9. void _main(void)
  10. {
  11. const HARDWARE_PARM_BLOCK *hpb = FL_getHardwareParmBlock ();
  12. const unsigned long *curptr;
  13. push_END_TAG ();
  14. for (curptr = (const unsigned long *) &(hpb->hardwareID) + hpb->len / 4 - 1; (unsigned long) curptr > (unsigned long) hpb; curptr--)
  15. {
  16. push_quantum (*curptr);
  17. push_quantum (1);
  18. push_quantum (POSINT_TAG);
  19. }
  20. push_quantum (hpb->len);
  21. push_quantum (1);
  22. push_quantum (POSINT_TAG);
  23. push_LIST_TAG ();
  24. }