Commit Graph

63 Commits

Author SHA1 Message Date
Jeff Wang
9fc462ca94 bugfix for backspacing from exp entry all the back to significand entry
check for '.' needs to be after entry_i--
2019-10-02 22:47:32 -04:00
Jeff Wang
5a3dc2337d more checks for NaN/errors before performing operations 2019-10-02 22:46:26 -04:00
Jeff Wang
23e49a0405 NUM_A_ARRAY cannot be less than num_lsu 2019-10-02 22:45:02 -04:00
Jeff Wang
ac1aaac096 initial natural log implementation 2019-10-02 22:43:23 -04:00
Jeff Wang
acc9c4821f prototyping of reciprocal and log functions 2019-10-02 02:52:08 -04:00
Jeff Wang
6eb48de844 more comments 2019-09-24 00:11:51 -04:00
Jeff Wang
4f020da222 use global registers for division, have sub_mag() operate directly on Accum and B 2019-09-23 23:46:58 -04:00
Jeff Wang
747355222d try to remove more trailing 0s 2019-09-23 23:06:43 -04:00
Jeff Wang
9dcb16681e fix desktop build warnings 2019-09-23 22:57:34 -04:00
Jeff Wang
eccd89807a improve initial estimate for division newton raphson iteration 2019-09-23 22:48:06 -04:00
Jeff Wang
52ddf7dd96 do not require BDecn to be preserved (frees up some xdata and code space) 2019-05-02 03:49:21 -04:00
Jeff Wang
0049f3df98 do not compile with stack auto, change functions to be nonreentrant, use fixed parameters
- frees up ~4KB of code space
2019-05-02 03:27:01 -04:00
Jeff Wang
6399cbf44f modify code to use accumulator architecture to minimize pointer usage 2019-05-01 03:54:57 -04:00
Jeff Wang
96c762aeed missed change for making number of exponent bits settable 2019-05-01 01:49:16 -04:00
Jeff Wang
60ed369c47 compare exponent directly for determining NaN 2019-05-01 01:40:23 -04:00
Jeff Wang
58a162fe4d allow number of exponent bits to be adjustable 2019-05-01 01:37:14 -04:00
Jeff Wang
4b87ad27c8 speed up division 2019-05-01 01:11:25 -04:00
Jeff Wang
fcf16153f6 change exponent from int16_t to int8_t to free up some space 2019-04-05 02:39:09 -04:00
Jeff Wang
836d4fc122 fix emulator lcd/calculator thread startup race 2019-04-05 02:10:10 -04:00
Jeff Wang
20946c44d4 detect division by 0 2019-04-05 01:07:42 -04:00
Jeff Wang
ef298cddd0 fix crash when displaying numbers between [0.1, 1) 2019-04-05 00:52:56 -04:00
Jeff Wang
66c611795e allow printing unknown characters in lcd emulator 2019-04-05 00:47:21 -04:00
Jeff Wang
ee917a71e5 add version string at poweron, also check for poweroff keys in interrupt 2019-04-05 00:47:07 -04:00
Jeff Wang
8af9701e15 bugfix for entering numbers such as 0.33
this is a partial revert of commit 8550049335
2019-04-04 03:36:35 -04:00
Jeff Wang
240dd570ae fix for LCD row tracking, fix for "phantom" keypress at powerup 2019-04-04 03:01:33 -04:00
Jeff Wang
4734fe5a0e add keyboard, fix display of negative numbers 2019-04-04 02:46:10 -04:00
Jeff Wang
8550049335 fix bug for entering numbers such as 0.01 2019-04-04 02:29:11 -04:00
Jeff Wang
5e04a18cd2 use semaphores for keyboard and lcd, add lcd thread for calling updateLcd() 2019-04-04 01:54:02 -04:00
Jeff Wang
89c5f0dc6c only process calculator keys and update lcd if keys pressed 2019-04-04 00:33:46 -04:00
Jeff Wang
fc6d8efc5f work on Qt GUI, still not working properly 2019-04-04 00:33:42 -04:00
Jeff Wang
8f39958679 start working on gui 2019-04-03 00:07:15 -04:00
Jeff Wang
1be980d85b fix reciprocol convergence 2019-04-02 23:57:28 -04:00
Jeff Wang
0278165339 remove unused funtion 2019-04-02 23:56:54 -04:00
Jeff Wang
bb102add67 add exponent character 2019-04-01 02:38:17 -04:00
Jeff Wang
f5d8d601a2 bugfix for keys
- initialize count, so that there is no initial keypress at powerup
- use int8_t instead of uint32_t to pass new key, since only 1 new key
used
2019-04-01 01:55:47 -04:00
Jeff Wang
8aec2ae134 fix exponent display 2019-04-01 01:12:02 -04:00
Jeff Wang
75a9c92b7d fix desktop build 2019-03-31 23:34:25 -04:00
Jeff Wang
fa0afa726b update readme 2019-03-31 23:34:13 -04:00
Jeff Wang
12e7f010e6 bugfix: latch on immediately, to ensure calculator stays on after poweron 2019-03-31 19:37:55 -04:00
Jeff Wang
d1ec11cad8 allow correct building/syntax highlighting on desktop 2019-03-31 19:37:55 -04:00
Jeff Wang
4ed3d1654e various bugfixes for decn arithmetic 2019-03-31 19:37:55 -04:00
Jeff Wang
43edb291cf attempt to reduce space usage
- remove unecessary code
- ifdef "extra" code
- pass data through globals instead of functions accessing static data
- functions non-reentrant, locate tmps in xdata
2019-03-31 19:37:52 -04:00
Jeff Wang
ecb0492534 initial calculator code 2019-03-31 19:33:59 -04:00
Jeff Wang
bdecc32b86 use global Buf everywhere for debugging 2019-03-28 00:41:54 -04:00
Jeff Wang
91b7b82462 add normal number display, number display bug fixes 2019-03-28 00:34:41 -04:00
Jeff Wang
4405ee7c8f division 2019-03-27 05:23:26 -04:00
Jeff Wang
b3c73cbdb5 style fixes 2019-03-27 05:22:47 -04:00
Jeff Wang
116b6ed2e6 bugfixes for multiply 2019-03-27 05:22:21 -04:00
Jeff Wang
0ba2ca7710 bugfixes for addition/subtraction 2019-03-27 05:22:19 -04:00
Jeff Wang
a742bb2059 separate out set_exponent function 2019-03-27 05:17:32 -04:00