1divert(-1)
2
3dnl Define macro for siggen widget
4DECLARE_SOF_RT_UUID("tone", tone_uuid, 0x04e3f894, 0x2c5c, 0x4f2e,
5		 0x8d, 0xc1, 0x69, 0x4e, 0xea, 0xab, 0x53, 0xfa)
6
7dnl N_TONE(name)
8define(`N_TONE', `TONE'PIPELINE_ID`.'$1)
9
10dnl W_TONE(name, format, periods_sink, periods_source, core, kcontrols_list)
11define(`W_TONE',
12`SectionVendorTuples."'N_TONE($1)`_tuples_uuid" {'
13`	tokens "sof_comp_tokens"'
14`	tuples."uuid" {'
15`		SOF_TKN_COMP_UUID'		STR(tone_uuid)
16`	}'
17`}'
18`SectionData."'N_TONE($1)`_data_uuid" {'
19`	tuples "'N_TONE($1)`_tuples_uuid"'
20`}'
21`SectionVendorTuples."'N_TONE($1)`_tuples_w" {'
22`	tokens "sof_comp_tokens"'
23`	tuples."word" {'
24`		SOF_TKN_COMP_PERIOD_SINK_COUNT'		STR($3)
25`		SOF_TKN_COMP_PERIOD_SOURCE_COUNT'	STR($4)
26`		SOF_TKN_COMP_CORE_ID'			STR($5)
27`	}'
28`}'
29`SectionVendorTuples."'N_TONE($1)`_tone_tuples_w" {'
30`	tokens "sof_tone_tokens"'
31`	tuples."word" {'
32`		SOF_TKN_TONE_SAMPLE_RATE'		ifdef(TONE_SAMPLE_RATE, STR(TONE_SAMPLE_RATE), "48000")
33`	}'
34`}'
35`SectionData."'N_TONE($1)`_data_w" {'
36`	tuples "'N_TONE($1)`_tuples_w"'
37`	tuples "'N_TONE($1)`_tone_tuples_w"'
38`}'
39`SectionVendorTuples."'N_TONE($1)`_tuples_str" {'
40`	tokens "sof_comp_tokens"'
41`	tuples."string" {'
42`		SOF_TKN_COMP_FORMAT'	STR($2)
43`	}'
44`}'
45`SectionData."'N_TONE($1)`_data_str" {'
46`	tuples "'N_TONE($1)`_tuples_str"'
47`}'
48`SectionWidget."'N_TONE($1)`" {'
49`	index "'PIPELINE_ID`"'
50`	type "siggen"'
51`	no_pm "true"'
52`	data ['
53`		"'N_TONE($1)`_data_uuid"'
54`		"'N_TONE($1)`_data_w"'
55`		"'N_TONE($1)`_data_str"'
56`	]'
57`	mixer ['
58		$6
59`	]'
60`}')
61
62divert(0)dnl
63