14 lines
373 B
Plaintext
14 lines
373 B
Plaintext
mod device;
|
|
mod helios;
|
|
|
|
use crate::conf::{Conf, DacFamily, EtherDreamConf, HeliosConf};
|
|
use crate::device::device::Device;
|
|
use crate::device::helios::HeliosDevice;
|
|
|
|
pub fn device_factory(config: Conf) -> Box<dyn Device> {
|
|
let device = match config.dac {
|
|
DacFamily::Helios(conf) => Box::new(HeliosDevice { conf }),
|
|
DacFamily::Etherdream(conf) => todo!(),
|
|
};
|
|
device
|
|
} |