Giter VIP home page Giter VIP logo

piecentral's People

Contributors

akumaraguru avatar arjunmehta94 avatar arjunsridhar1 avatar awli avatar baby-bell avatar bodiddles avatar brandonxxlee avatar cduck avatar charleshong3 avatar danellenachum avatar dependabot[bot] avatar dhe95 avatar dhutchings avatar firedog5 avatar fostertim avatar jerryycheng avatar jhgzhou avatar jonathan-j-lee avatar karthik-shanmugam avatar kevinji avatar kevinmasd avatar lizatre avatar matthew-zhao avatar nikitakit avatar onibrow avatar rohityelamanchili avatar tingtingchiang avatar yidingjiang avatar yizow avatar zentner-kyle avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

piecentral's Issues

Hosted student API documentation

We previously had student API documentation autogenerated from docstrings using sphinx, and hosted on readthedocs. It would be nice to do something similar this year.

I am one of several admins for our readthedocs account/subdomain, and can help if you want to reuse that website.

[Dawn] Field Control Variant

Will need to create a UI for handling game features. Experiment whether it can be done through tabs, windows, or a separate app.

Needs:

  • Communication Signals
    • Figure out with networking what we need to send to robots
    • (Basically boils down to coordinating game mode changes)
  • Student Locks
    • If student’s Dawn is still open, prevent their version of Dawn from making changes to the robots
  • Competition Display
    • Fancy bar mechanism to show timings
    • Show robot-related information to debug/check status

Remove old Ansible.js

New ansible in main/ folder is being written, we should remove the old Ansible.js in the renderer/utils folder. There may still be files importing the older Ansible file, they should be fixed first so nothing breaks when you remove it.

[Dawn] Accordian Peripherals

Theoretically, the Peripherals bar could load many peripherals, making it hard to visually read Gamepad data while editing code at the same time. Allow Peripherals to be hidden may help, though it does require some form of sorting.

Overall UI concerns also go in this ticket.

[DAWN] Fix performance by consolidating actions

Currently, Ansible.js dispatches a number of actions:

RendererBridge.reduxDispatch(ansibleConnect());
RendererBridge.reduxDispatch(updateStatus());
try {
  const data = RuntimeData.decode(msg);
  RendererBridge.reduxDispatch(updateRobotState(data.robot_state));
  for (const sensor of data.sensor_data) {
    RendererBridge.reduxDispatch(updatePeripheral(sensor));
  }
  RendererBridge.reduxDispatch(updateAllPeripherals(data.sensor_data));

} catch (e) {
  console.log(`Error decoding: ${e}`);
}

This should be reduced to just two actions: one to update the Info state, and one to update the Peripheral state.

In particular, the for loop must be moved into the reducer.

[Dawn] More persistent (saved state) features for menu, editor, files, configurations

Some nice editor features that shouldn't be too hard to implement

  • Have automatic re-opening of last file, e.g. having it saved in persistent local memory
  • Have configuration (persistent setting) if students don't necessarily want to see their last file they were working on when they last closed dawn for some reason
  • Have menu bar show recently opened files (and easy clicking)
  • Have configuration (persistent setting) if for some reason students don't want to be prompted when they close editor without saving that they didn't save

Make sure that runtime updates do not override student code

Currently runtime updates are formed by copying the runtime folder into a zip archive. Then the installation will unzip that folder. The previous runtime folder is deleted in the process now.

As it stands, this will probably delete any student code and replace it with the testing file that's in the repo. Some more sensible behavior should happen instead

Fix paths in setup scripts.

If you look through the various setup scripts in DevOps/frankfurter, you'll notice that some of the path variables are set incorrectly

As a example, see DevOps/frankfurter/scripts/install/master_frank_setup.sh. The variable FRANKFURTER_DIR is set to PiECentral/frankfurter/, which is a nonexistent directory. It should be set to PiECentral/DevOps/frankfurter/.

These errors happened as a result of the move to the monolithic PiECentral repo. Similar errors are likely sprinkled throughout the DevOps directory, so they should be hunted down and fixed.

[Dawn] NameEdit and Peripheral Naming

NameEdit (Renaming Peripherals) needs a revamp.

Old method was to use a library called React Inline Edit Kit. However, this system did not update values correctly, and the main bug was that "editing" once broke the Name-Edit functionality for the rest of the time. Perhaps we were using the library wrong.

Alternatives that may be explored include Draft.js.

[Dawn] Console Output

Dawn needs to modify its Runtime API communication to be able to allow for console output to be displayed.

Could try to differentiate errors from non-error through color scheme.

Could try to keep logs of console output for remote debugging.

[RUNTIME] Validate error handling on unparsable student code

If the student code has an error such that the entire file can't be parsed (e.g. missing parentheses, bad indentation, etc.), I'm not sure that a meaningful error message is reported to Dawn.

One team had this issue, and I believe all Dawn did was switch back into the idle state.

[Dawn] Dawn UI Update + Notifier

Might want to find some way to notify user that there is a new version of Dawn or Runtime pushed out.

May expand to actually installing/downloading onto host computer, though this seems very OS dependent.

Dawn tabs for multiple files

Currently students can only view and edit one file. In addition, new file erases the current code, so could create a new tab instead.

UI could utilize bootstrap navs

Or, use electron-windows but considering gamepads and peripherals this could be clunky. Maybe main window will show peripherals/gamepads and other windows just the code editor.

[Dawn] keyboard shortcuts

Implement keyboard shortcuts for anything useful or that students may want quick access to. Most likely the following features (with rough suggestions for key bindings)
Note: Super refers to Cmd on Mac, Control on Windows

Robot

  • Change IP (Super I)
  • Upload (Super U)
  • Run (Super Y) (Super+R is used to refresh app, maybe change to be Super Shift R)
  • Stop (Super W)
  • E-Stop (Super E)

Editor

  • Increase font size (Super +)
  • Decrease font size (Super -)

Misc

  • Open Preferences/Config (Super ,)
  • Open API (Super P)

Dawn actions tests

We should test all action creators, located in dawn/renderer/actions/

[Dawn] Documentation

Going to need to create some form of documentation for both student users and staff developers to be able to learn how to use the system. Probably going to be done with the GitHub wiki or with a Google Doc.

Dawn start script not cross-platform, only works on Mac

In dawn/package.json, a start script is defined which currently only works on Mac, by calling the Electron.app binary on our build/main.js script. We should make it work at least on linux also, where the command should be very similar (without the .app). In general, we just need a way to change the start script being run depending on the platform.

Add UI for dawn editor settings

Currently we have actions and reducers for changing editor settings but no UI for the actual user to change those settings. We should make one.

[HIBIKE] Filter serial ports by vendor/product ID

Currently the way hibike finds ports to use is the following:

ports = glob.glob("/dev/ttyACM*") + glob.glob("/dev/ttyUSB*")

This has the side effect of possibly catching non-hibike devices, if they're currently plugged in to the computer. @dHutchings brought up this issue.

I think we can use the serial.tools.list_ports module to find devices while matching for vendor/product ids of the hardware we actually use. This should cut down on the possibility of interfering with random devices.

cc: @karthik-shanmugam

[HIBIKE] Devices should define UID in implementation file, not header

Currently hibike_uid_t UID is defined in example_device.h, and other device headers.

If such a device.h header is included from multiple *.cpp files, the resulting duplicate UID definitions will break the linker.

In practice this is only a problem for more complicated devices (like YogiBear), but the example device (and maybe real devices) should also be changed to avoid this pitfall.

[Dawn] Error if no internet connection

I just started Dawn while not connected to wifi, and got an error:

Uncaught Exception:
Error: send ENETUNREACH 192.168.0.200:1236
    at Object.exports._errnoException (util.js:1022:11)
    at exports._exceptionWithHostPort (util.js:1045:20)
    at SendWrap.afterSend [as oncomplete] (dgram.js:404:11)

I'm running the latest pre-release Dawn.

[Dawn] React-Joyride

React-Joyride, the interactive tours mechanism, still has issues loading in Dawn.

Also think of new information to show to students.

PieCentral/Dawn/readme.md erroneous link

within PieCentral/Dawn/readme.md: the link to our stable release is pioneers.github.io/daemon (which doesn't work). The appropriate link to the stable release should be pioneers.github.io/dawn, right?

[HIBIKE] Read queue overflow stalls device writes

We've noticed that time taken to write to a hibike serial port can spike as high as 3 seconds. Close examination has shown that this is because the read queue for that port fills up, which prevents new operations for being executed against the device.

This means that hibike_message.py::blocking_read cannot effectively keep up with bytes coming in. A hacky fix is

diff --git a/hibike/hibike_message.py b/hibike/hibike_message.py
index 7825bdb..f5e25e4 100755
--- a/hibike/hibike_message.py
+++ b/hibike/hibike_message.py
@@ -332,6 +332,10 @@ def parse_bytes(bytes):
 def blocking_read(serial_conn):
   buffer = bytearray()
   while not parse_bytes(buffer):
+    if serial_conn.in_waiting > 500:
+        buffer = bytearray()
+        serial_conn.reset_input_buffer()
+        print('reset input buffer!!!!!!!!')
     curr = serial_conn.read()
     if struct.unpack('<B', curr)[0] == 0:
       buffer = bytearray(curr)

However, this is just a hack. There needs to be a real fix implemented.

[Dawn] Release build of Dawn crashes on exit

Uncaught Exception:
TypeError: Cannot read property 'kill' of undefined
    at BrowserWindow.<anonymous> (/private/var/folders/kx/1dxccvcx5bvcbs426mjjjyymbm5qnj/T/AppTranslocation/1F8B67D6-CEE7-4818-8AA3-F453F0315027/d/dawn.app/Contents/Resources/app.asar/build/main.js:1:680)
    at emitOne (events.js:96:13)
    at BrowserWindow.emit (events.js:188:7)

@kevinmasd said he thinks he knows why this is happening.

Add LICENSE

Since this project is open source, adding a LICENSE would be beneficial. GPLv3 and MIT are fairly common.

Centralize dawn settings state, figure out persistent solution

Currently different settings are handled in different ways, some persistent (saved even after you close Dawn), others are not. We should centralize this all into one reducer (the settings reducer) and save that so no settings are lost after closing Dawn.

[Dawn] Simulate Competition

Last season showed the need for a simulate competition button to be able to test Autonomous. It may also act as the last ditch mechanism if Field Control goes awry.

Need to find a timing mechanism more stable/precise than just setTimeouts.

[Dawn] Outdated "Updates" tour information

As of Dawn 0.5.1, when going through the tour, the "Updates" help text reads:

Occasionally we may release updates to the robot's software. When this happens, you will download two files, an update package and its signature, and click on this button to upload those updates to the robot.

This information is outdated--updates are no longer signed, and only require a zipped tarball. This text should be changed to avoid confusion.

Duplicates settings actions in Editor Actions

[In dawn/renderer/actions/EditorActions, the functions:

{ changeTheme, increaseFontsize, decreaseFontsize }

are duplicates in dawn/renderer/actions/SettingsActions.

As a result, my tests in branch dawn/actiontests may have to be changed as well to remove duplicates.

Add Protobuf compilers onto beaglebones

We currently are committing compiled protobufs into the main repo. These should be instead placed in the gitignore, once we are able to compile the files on the beaglebone.

Add wired xbox controller support to runtime

Debugging robots requires running through the entire stack (laptop running dawn, wifi routers, etc.). Being able to plug an xbox controller directly into the robot would make debugging far easier.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.