1
+ <?xml version =" 1.0" encoding =" utf-8" ?>
2
+ <ContentPage xmlns =" http://schemas.microsoft.com/dotnet/2021/maui"
3
+ xmlns : x =" http://schemas.microsoft.com/winfx/2009/xaml"
4
+ xmlns : chart =" clr-namespace:Syncfusion.Maui.Toolkit.Charts;assembly=Syncfusion.Maui.Toolkit"
5
+ xmlns : local =" clr-namespace:RealTimeChart"
6
+ x : Class =" RealTimeChart.MainPage" >
7
+
8
+ <ContentPage .BindingContext>
9
+ <local : RealTimeChartViewModel x : Name =" realTimeChartViewModel" />
10
+ </ContentPage .BindingContext>
11
+
12
+ <Grid >
13
+ <chart : SfCartesianChart x : Name =" realTimeChart"
14
+ HorizontalOptions =" Fill"
15
+ VerticalOptions =" Fill" >
16
+
17
+ <chart : SfCartesianChart .Title>
18
+ <Label Text =" Live ECG Monitor (100Hz)"
19
+ Margin =" 0,0,0,5"
20
+ Padding =" 0,20,0,0"
21
+ HorizontalOptions =" Fill"
22
+ HorizontalTextAlignment =" Center"
23
+ VerticalOptions =" Center"
24
+ FontSize =" 16" />
25
+ </chart : SfCartesianChart .Title>
26
+
27
+ <chart : SfCartesianChart .XAxes>
28
+ <chart : NumericalAxis ShowMajorGridLines =" false"
29
+ EdgeLabelsDrawingMode =" Center" >
30
+ <chart : NumericalAxis .Title>
31
+ <chart : ChartAxisTitle Text =" Samples" />
32
+ </chart : NumericalAxis .Title>
33
+ <chart : NumericalAxis .LabelStyle>
34
+ <chart : ChartAxisLabelStyle />
35
+ </chart : NumericalAxis .LabelStyle>
36
+ </chart : NumericalAxis >
37
+ </chart : SfCartesianChart .XAxes>
38
+
39
+ <chart : SfCartesianChart .YAxes>
40
+ <chart : NumericalAxis ShowMajorGridLines =" false"
41
+ Minimum =" 500"
42
+ Maximum =" 1100" >
43
+ <chart : NumericalAxis .Title>
44
+ <chart : ChartAxisTitle Text =" Amplitude" />
45
+ </chart : NumericalAxis .Title>
46
+ </chart : NumericalAxis >
47
+ </chart : SfCartesianChart .YAxes>
48
+
49
+ <chart : SfCartesianChart .Series>
50
+ <chart : FastLineSeries ItemsSource =" {Binding LiveData}"
51
+ EnableAntiAliasing =" True"
52
+ XBindingPath =" Value"
53
+ YBindingPath =" Size" >
54
+ </chart : FastLineSeries >
55
+ </chart : SfCartesianChart .Series>
56
+
57
+ </chart : SfCartesianChart >
58
+ </Grid >
59
+
60
+ </ContentPage >
0 commit comments