EasternEdgeRobotics / Software_2017

The control software for 2017
MIT License
3 stars 0 forks source link

Implement lights using raspi gpio #328

Open ConnorWhalen opened 7 years ago

ConnorWhalen commented 7 years ago

Addresses #327

The implementation is based on how the motors are implemented: DigitalLight -> Motor Light -> PWM List -> Maestro RPiGPIOLight -> MaestroChannel

ConnorWhalen commented 7 years ago

From CircleCI:

    java.lang.AssertionError: expected:<616.0> but was:<617.0>
        at org.junit.Assert.fail(Assert.java:88)
        at org.junit.Assert.failNotEquals(Assert.java:834)
        at org.junit.Assert.assertEquals(Assert.java:553)
        at org.junit.Assert.assertEquals(Assert.java:683)
        at com.easternedgerobotics.rov.fx.ViewLoaderPrefsTest.doesResetSizeLocation(ViewLoaderPrefsTest.java:82)

This looks like a weird failure, I'm going to kick off another CI build

cal-pratt commented 7 years ago

I would just delete the old light classes completely. They don't work so there's not any value in keeping them. As an aside I would probably copy the abstract map computeIfAbsent implementation instead of just hoping the list is ordered correctly once its passed to the Rov ctor. I don't really like the abstract list implementation, but maybe next year you could make a factory classes for creating I2C/Maestro/GPIO objects.

Other than that :+1: Test it on the rov then ship it.

ConnorWhalen commented 7 years ago

FYI The old light classes have already been deleted