1 // Copyright 2023 Google LLC
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // https://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14
15 use frontend_proto::model::chip::Bluetooth as ProtoBluetoothChip;
16 use frontend_proto::model::chip::Radio as ProtoRadioChip;
17
18 use super::device::DeviceIdentifier;
19
20 pub type FacadeIdentifier = i32;
21
hci_get(facade_id: FacadeIdentifier) -> ProtoBluetoothChip22 pub fn hci_get(facade_id: FacadeIdentifier) -> ProtoBluetoothChip {
23 println!("hci_get({})", facade_id);
24 ProtoBluetoothChip::new()
25 }
26
wifi_get(facade_id: FacadeIdentifier) -> ProtoRadioChip27 pub fn wifi_get(facade_id: FacadeIdentifier) -> ProtoRadioChip {
28 println!("wifi_get({})", facade_id);
29 ProtoRadioChip::new()
30 }
31
hci_remove(facade_id: FacadeIdentifier)32 pub fn hci_remove(facade_id: FacadeIdentifier) {
33 println!("hci_remove({})", facade_id);
34 }
35
wifi_remove(facade_id: FacadeIdentifier)36 pub fn wifi_remove(facade_id: FacadeIdentifier) {
37 println!("wifi_remove({})", facade_id);
38 }
39
hci_add(_device_id: DeviceIdentifier) -> FacadeIdentifier40 pub fn hci_add(_device_id: DeviceIdentifier) -> FacadeIdentifier {
41 println!("hci_add()");
42 0
43 }
44
wifi_add(_device_id: DeviceIdentifier) -> FacadeIdentifier45 pub fn wifi_add(_device_id: DeviceIdentifier) -> FacadeIdentifier {
46 println!("wifi_add()");
47 0
48 }
49
hci_patch(_facade_id: FacadeIdentifier, _patch: &ProtoBluetoothChip)50 pub fn hci_patch(_facade_id: FacadeIdentifier, _patch: &ProtoBluetoothChip) {
51 println!("hci_patch()");
52 }
53
wifi_patch(_facade_id: FacadeIdentifier, _patch: &ProtoRadioChip)54 pub fn wifi_patch(_facade_id: FacadeIdentifier, _patch: &ProtoRadioChip) {
55 println!("wifi_patch()");
56 }
57
hci_reset(_facade_id: FacadeIdentifier)58 pub fn hci_reset(_facade_id: FacadeIdentifier) {
59 println!("bt_reset()");
60 }
61
wifi_reset(_facade_id: FacadeIdentifier)62 pub fn wifi_reset(_facade_id: FacadeIdentifier) {
63 println!("wifi_reset()");
64 }
65