From 713b65d414e327db7b530ce0be8403bc0ff4ff3b Mon Sep 17 00:00:00 2001 From: sam-anthony Date: Sat, 26 Mar 2022 14:51:43 -0230 Subject: engine displacement --- main.go | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'main.go') diff --git a/main.go b/main.go index aca48bb..d36ebc8 100644 --- a/main.go +++ b/main.go @@ -16,18 +16,17 @@ func check(err error) { } } +var ( + displacement = volume{2000, cubicCentimetre} + // selectedVolumeUnit is used to index volumeUnitStrings. + selectedVolumeUnit = defaultVolumeUnitIndex +) + var engineSpeed = [numPoints]int32{2000, 3000, 4000, 5000, 6000, 7000} var volumetricEfficiency = [numPoints]int32{100, 100, 100, 100, 100, 100} var ( - manifoldPressure [numPoints]pressure - - // selectedPressureUnit is used to index pressureUnits - selectedPressureUnit int32 -) - -func init() { manifoldPressure = [numPoints]pressure{ newPressure(), newPressure(), @@ -37,12 +36,13 @@ func init() { newPressure(), } - // selectedPressureUnit is used to index pressureUnitStrings + // selectedPressureUnit is used to index pressureUnitStrings. selectedPressureUnit = defaultPressureUnitIndex -} +) func loop() { g.SingleWindow().Layout( + engineDisplacementRow(), g.Table(). Rows( engineSpeedRow(), -- cgit v1.2.3