mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-15 08:31:57 -05:00
d431e2cecd
Re-factor the JT4, JT65 and JT9 decoders as Fortran modules using type bound procedures, the decoder types implement a callback procedure such that he client of the decoder can interpret the decode results as they need. The JT4 decoder has a second callback that delivers message averaging status. Also the previously separate source files lib/jt4a.f90 and lib/avg4.f90 have been merged into lib/jt4_decode.f90 as private type bound procedures of the new jt4_decoder type. Re-factored the lib/decoder.f90 subroutine to utilize the new decoder types. Added local procedures to process decodes and averaging results including the necessary OpenMP synchronization directives for parallel JT9+JT65 decoding. Added the jt65_test module which is a basic test harness for JT65 decoding. Re-factored the jt65 utility to utilize the new jt65_test module. Changed a few integers to logical variables where their meaning is clearly binary. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6324 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
51 lines
1.5 KiB
Fortran
51 lines
1.5 KiB
Fortran
use, intrinsic :: iso_c_binding, only: c_int, c_short, c_float, c_char, c_bool
|
|
|
|
include 'constants.f90'
|
|
|
|
!
|
|
! these structures must be kept in sync with ../commons.h
|
|
!
|
|
type, bind(C) :: params_block
|
|
integer(c_int) :: nutc
|
|
logical(c_bool) :: ndiskdat
|
|
integer(c_int) :: ntr
|
|
integer(c_int) :: nfqso
|
|
logical(c_bool) :: newdat
|
|
integer(c_int) :: npts8
|
|
integer(c_int) :: nfa
|
|
integer(c_int) :: nfsplit
|
|
integer(c_int) :: nfb
|
|
integer(c_int) :: ntol
|
|
integer(c_int) :: kin
|
|
integer(c_int) :: nzhsym
|
|
integer(c_int) :: nsubmode
|
|
logical(c_bool) :: nagain
|
|
integer(c_int) :: ndepth
|
|
integer(c_int) :: ntxmode
|
|
integer(c_int) :: nmode
|
|
integer(c_int) :: minw
|
|
integer(c_int) :: nclearave
|
|
integer(c_int) :: minsync
|
|
real(c_float) :: emedelay
|
|
real(c_float) :: dttol
|
|
integer(c_int) :: nlist
|
|
integer(c_int) :: listutc(10)
|
|
integer(c_int) :: n2pass
|
|
integer(c_int) :: nranera
|
|
integer(c_int) :: naggressive
|
|
logical(c_bool) :: nrobust
|
|
integer(c_int) :: nexp_decode
|
|
character(kind=c_char, len=20) :: datetime
|
|
character(kind=c_char, len=12) :: mycall
|
|
character(kind=c_char, len=6) :: mygrid
|
|
character(kind=c_char, len=12) :: hiscall
|
|
character(kind=c_char, len=6) :: hisgrid
|
|
end type params_block
|
|
|
|
type, bind(C) :: dec_data
|
|
real(c_float) :: ss(184,NSMAX)
|
|
real(c_float) :: savg(NSMAX)
|
|
integer(c_short) :: id2(NMAX)
|
|
type(params_block) :: params
|
|
end type dec_data
|