basic ports view (#115)

* basic ports view

* slight adjustement of rendering
This commit is contained in:
Peli de Halleux
2017-12-19 14:26:57 -08:00
committed by GitHub
parent eac3e183c3
commit d78d9c8686
7 changed files with 43 additions and 6 deletions

View File

@ -74,6 +74,11 @@ namespace sensors.internal {
}
export function getActiveSensors(): Sensor[] {
init();
return sensorInfos.filter(si => si.sensor && si.sensor.isActive()).map(si => si.sensor);
}
function readUartInfo(port: number, mode: number) {
let buf = output.createBuffer(UartCtlOff.Size)
buf[UartCtlOff.Port] = port