Commit graph

360 commits

Author SHA1 Message Date
TT f581317d68 Merge branch 'levermode' 2020-02-23 00:09:28 +09:00
TT 12085146ae
Merge pull request #120 from DiSlord/master
Big code redisign (increase CELL draw size, more faster screen render)
2020-02-23 00:08:16 +09:00
TT 10e5578c8c Merge branch 'levermode' into DiSlord-master 2020-02-23 00:05:47 +09:00
TT 93d1233d8b feat: change the operations to select lever mode 2020-02-22 22:41:50 +09:00
TT fb3c9cf82f fix: adjust width of space and triangle 2020-02-22 22:40:06 +09:00
TT 863691c554 fix: adjust spaces frequency and marker values 2020-02-22 22:37:25 +09:00
DiSlord 02a5715bb4 Big code redisign (increase CELL draw size, more faster screen render), also save about 4-5kB flash size
Try remove all hardcoded values from code (use definition if set)
Some error fix

main.c:
Rewrite Shell, now it run on main thread and require less RAM (not need stack)
 (possible run it as thread if define VNA_SHELL_THREAD
Remove not used trace_info[].scale_unit in set_trace_scale/get_trace_scale (it just divede on set and multiple on get, better use it for default scale set)

Replace some hardcoded values
 MARKERS_MAX
 SAVEAREA_MAX
 TRACES_MAX

plot.c
Rewrite CELLWIDTH and CELLHEIGHT use, now possible set any CELL width and height (CELLWIDTH * CELLHEIGHT <= spi_buffer size)
Free RAM from shell stack use fore increase spi_buffer size now it have 2048 pixel (64x32)
Rewrite cell index and markmap use (now correct use cell size, and more faster), correct use CELLWIDTH and CELLHEIGHT in calculation
Fore set update area use invalidateRect (still need use some hardcoded values :( )
Rewrite cell_draw_line
Rewrite many hardcoded size definitions
Refrence point now draw as bitmap (less size, more costumable)
Fix drag marker (now correct search closest index in search_nearest_index)
Rewrite plot_into_index, now correct use size definitions, moe

ui.c
Small rewrite keyboard definitions, for use less flash size
Define KP_WIDTH, KP_HEIGHT for set key size
Better look some big font symvols

All:
use static fore some local functions (use less space on calls)
replace tabs on spaces (code style)
Use M_PI from math.h fore define pi value

Fix printf on print HEX values
2020-02-22 10:50:54 +03:00
TT 2381e338eb fix: adjust spaces frequency and marker values 2020-02-22 12:24:32 +09:00
TT 2c231bab15 Merge pull request #119 from DiSlord/master 2020-02-22 12:23:26 +09:00
DiSlord e9f65b1426 Huge rework chsnprintf function (basic functional more compact and faster):
I can`t upload my version chprintf.c to ChibiOS\os\hal\lib\streams upload it to root :(
 now support print float and Suffix if use example %.1F on 1.234e-3 print 1.234m, %F print 1.23m
 now support + flag %+d on 8 print +8, %+d on -8 print -8
 now support freq output if use %q example %q on 1234567890 print 1.234 567 890 GHz, %.8q print 1.234567GHz
 fix rounding errors on print float example if print use %.2f on 2.199 print 2.20 (before 2.19)
Use it in code - made more compact (save about 2k bytes) and easy display values (set output more digits after . for some values)
Made some font glyph more compact, allow 3px glyph

More correct create frequencies table on big span (not use float operations), also produce more compact code
Use double value input from keyboard (not lost Hz on input)
Set sweep_points as uint Optimize set_sweep_frequency size

Fix freq commands broken after freq set as uint32 (add str to uint32 functions for freq bigger then 2 147 483 647):
 cmd_freq
 cmd_offset
 cmd_threshold
 cmd_scan
 cmd_sweep

Define _isdigit macro (replace isdigit() function, its too big)

Rewrite std universal atoi() to more compact my_atoi and write new unsigned variant my_atoui
2020-02-11 11:54:05 +03:00
TT ae38c9794d view: pack smith marker value 2020-02-01 00:24:28 +09:00
TT dd4074d501 fix: gain table covers 2.7GHz 2020-02-01 00:18:38 +09:00
TT 14dfe97557 fix: revert color of traces to the original 2020-02-01 00:18:38 +09:00
TT 51c3980e1b
Merge pull request #116 from DiSlord/master
Some old code fixes
2020-02-01 00:08:25 +09:00
DiSlord 6a1d05321d Disable unused ChibiOS features:
- Threads registry APIs
- I/O Queues APIs
- SHELL_CMD_INFO
- SHELL_CMD_THREADS
2020-01-30 21:58:18 +03:00
DiSlord a46a20028f Remove unused global variable (fgrid)
Set areasize as int16
2020-01-30 21:43:49 +03:00
DiSlord 1ec7faca2a Fix warning
Use __REV16 instruction for set display x y coordinates (faster and more compact)
2020-01-29 23:47:58 +03:00
DiSlord 3639b7bb14 Revert marker SPAN callback changes 2020-01-27 07:00:13 +03:00
DiSlord 91cc17eb04 Remove compilation warning 2020-01-27 06:55:41 +03:00
TT 3961418b72
Update README.md
add @DisLord as contributor
2020-01-27 07:28:10 +09:00
DiSlord 1d6f09a355 Fix warning 2020-01-26 21:36:13 +03:00
DiSlord b10e29c01f Fix velocity factor on numeric value input multiple
Remove comments
Little code optimisation
2020-01-26 20:56:45 +03:00
TT 836ed2a7fb
Merge pull request #113 from DiSlord/master
Change font size, more compact and faster code for LCD
2020-01-26 22:29:44 +09:00
ВшЫдщкв d3f4ef5dc1 Fix my tupo on frequency string 2020-01-26 09:09:11 +03:00
ВшЫдщкв 5a4d02208f define POINTS_COUNT in nanovna.h
fix 'micro' char in font
fix draw STOP distance in frequency field
fix x position calc in plot_into_index
fix frequencies delta defined as int in plot.c
fix frequencies defined as int in ui.c
2020-01-25 20:54:03 +03:00
ВшЫдщкв 4a0ba6741e Continue size optimization (save 700-900 bytes)
Set menuitem_t size align as WORD (more compact on flash)
Add data to menuitem_t (more easy use callback functions, and save its sizing)
Rewrite some ui callback functions for use data field

More better look infinity and delta symbols
Fix grid sizing in update_grid (broken after frequency0 and frequency1 set as uint)
2020-01-25 15:46:09 +03:00
ВшЫдщкв 992e51cf8b Optimize size of groupdelay_from_array function 2020-01-23 22:05:32 +03:00
ВшЫдщкв df5a655cd0 Remove comment, fix last add 2020-01-21 20:47:53 +03:00
DiSlord e7bdead77a
Merge branch 'master' into master 2020-01-21 20:45:02 +03:00
TT 066027f5b5 fix: prototype mismatch 2020-01-21 21:43:58 +09:00
ВшЫдщкв 4b9c348a1a Fix typos 2020-01-19 16:47:50 +03:00
ВшЫдщкв 90dc36418d Remove test code
Optimize size trace command function
2020-01-19 16:14:22 +03:00
ВшЫдщкв 6f666cf31b Change Font size (more readable)
Rework display spi driver:
 use DMA for read, write
 add blitBitmap functions
 Use DMA for color fill
 More correct SPI bus control
Move color definitions to nanovna.h
Some code optimization for speed and size (save about 3k bytes)
Change grid Y resolution to 10
Fix convert from float to int (fix some rounding errors on plot)
Disable unused HAL serial
Change battery icon
2020-01-19 11:16:18 +03:00
TT 18a1ca4e6e feat: add marker tracking 2020-01-18 22:27:56 +09:00
TT 2d8be205d0 fix: broken display of cw frequency 2020-01-18 14:26:21 +09:00
TT c4edbee973 fix: boundary check of center/span 2020-01-18 14:25:37 +09:00
TT e1ba0c77f0 chore: store velocity factor in float 2020-01-18 13:03:38 +09:00
TT c4495b6d58 chore: add reserved room in properties and config 2020-01-18 12:34:59 +09:00
TT fcb0be6def fix: remove upper limit of signed int32 for frequency setting 2020-01-18 12:07:21 +09:00
TT 38e64a616f chore: remove keypad icon 2020-01-10 00:26:07 +09:00
TT 0e59f0a82b
Merge pull request #104 from damib/issue79
Issue79
2020-01-10 00:20:07 +09:00
TT 9bd034bc45
Merge pull request #103 from damib/bugfix
Bugfix: disabling all the markers causes the GUI to freeze
2020-01-10 00:19:46 +09:00
Damiano Bortolato f9ef7efd39 BUGFIX: deselecting all markers freezes the gui.
A index check on current_marker value was missing.
2019-12-26 18:44:22 +01:00
Damiano Bortolato aa503ceb96 BUGFIX #79: Numpad editor freeze
There code was exiting from ui_process_keypad without redrawing and switching ui_mode.
2019-12-26 18:38:33 +01:00
TT 6a88f8ed8f feat: improve frequency accuracy 2019-12-10 03:00:06 +09:00
TT 75ea464c91 chore: delta symbol 2019-11-30 13:47:34 +09:00
TT 481fa990db feat: draw marker value in white 2019-11-30 10:18:17 +09:00
TT 0bfa2c073e feat: add marker smith value format menu 2019-11-30 10:17:14 +09:00
TT 14a130c24b Merge branch 'master' of github.com:ttrftech/NanoVNA 2019-11-29 22:22:08 +09:00
TT b2f2ec3320 fix: show channel in marker info 2019-11-29 22:18:47 +09:00