Skip to content
Robb Jones edited this page Feb 1, 2018 · 9 revisions

Cub Scout Pinewood Derby Event Runner

Robb Jones

v1 November 2013-January 2014 v1.1 Jan 2015 Jan 2018

Overview

Run your pack's pinewood derby from your computer. Control everything via smartphone or tablet (or computer).

Screenshots

Title page: https://flic.kr/p/rE6Nr4

Run results: https://flic.kr/p/qzD4WF

Race results: https://flic.kr/p/qRUujX

Project it! https://flic.kr/p/qRuhPp

Control the race wherever you are! https://flic.kr/p/qRk8zM

Features

  • Spectators can follow along on any html5-capable device
  • Racer registrations done electronically via any html5-capable device that has a camera
  • Race car photo auto-crops
  • Race staff can run the race via any html5-capable device
  • Shows every heat in the current race, with running results
  • Always up-to-date race results viewable by rank and all participants
  • Option to cycle thru results, suitable for projection screens
  • Integrates with electronic race track scoreboard

Technology Stack - January 2018

  • Python 3.6
  • Django 2.0
  • Tornado 4.5.1
  • jQuery
  • SQLite

Pinewood Derby Event Checklist

  • Order trophies from Fond Memories (at least 2 weeks out)
  • Get participation ribbons or patches
  • Get placement medals
  • Create, print instructions for joining network, racer URL
  • Seed database with scouts, racer slots
  • Send out e-mail asking for car pics
  • Print car roster for manual scoring just in case
  • Send out Derby Rules + Race-specific info
  • All cars will race on every lane
  • Cars will race against random scouts, not by den/rank
  • Winners determined by lowest average time (by rank)
  • Four sets of races: -- Pack heats - all cub scouts race together -- Wildcard - 2nd place rank finishers play for one slot in the pack finals -- Open division heats - anyone/everyone competes, $1 entry fee --- Cars racing in the Pack heats are not eligible -- Pack finals - top finisher from each rank + a wild card*
  • Bring your smartphone/tablet/laptop to follow along!

Application Entry Points

Application home http://{host}/runner/
Race Observer http://{host}/runner/race/current/standings
Race Control http://{host}/runner/race/current/control/ 
Race Admin http://{host}/admin/runner/ 
Login as ‘registration’ to manage racer registration (set up in db first)
Login as ‘control’ to run the race (set up in db first)
Login as ‘guest’ (or don’t login) to look at data in the admin screens

Maintainer Notes and Procedures

https://github.com/joneser005/derby Server startup/shutdown Run tornado-server.sh Run car-pic-processor.sh Login the registration user Login the race runner

##Installation

Python 3.5+ Django 2.0 pip install -r requirements.txt

Race setup

Computer system

Database prep

Make sure test data is deleted or otherwise out of the way Seed Person, Racer with any values known ahead of time to reduce data-entry at registration. Promote Person ranks from prior year: ./derby/sql/promote-scouts.sql Log in prior to the event (http/s issue) Assign server a static ip address, use that in the QR code/connection instructions Have racer photos in advance, where possible, to speed up registration. This script automates car picture cropping if the car is photographed on a white sheet of paper, which can be used on any car picture - before hand or during registration: ./derby/car-pic-processor.sh Seed race: python manage.py seedRace 1 1 args = '{race_id} {group_id}', see Django admin interface for id values help = 'Seeds or reseeds a Race using a RaceGroup' Call again before/during the Race if new Racers are added Race cannot have more lanes than racers. Use fewer lanes. In this case, if racers are added later (and not sure that is even possible), they will continue to use the same number of lanes defined for the race.

TODO

See Github Issues list

Terms used in the system

  • A Person is a human. A Person can have one or more Racers (say, if they are also racing last year’s car in the open division)
  • A Racer is a derby car. Racers is the pool of all Racers. It is up to the reader to distinguish the term ‘Racers’ from the plural form of ‘Racer’ :-)
  • An Event is (for example) ‘Pinewood Derby Jan 2015’. And Event has many Races.
  • A Race is one of {Heats | Finals | Open Division | Practice}. A Race has many Runs, generally equal to the number of Racers. Race has a RaceGroup, a subset of all Racers who will be competing in the Race.
  • A Run is one set of Racers racing down the track. A Run has many RunPlaces, equal in number to the number of lanes the track supports or are in use (that is, in case we only use lanes 1-5 on a 6-lane track because (say) a lane is unusable).
  • A RunPlace ties a Racer and their time-to-finish to a track lane within a Run.

Registration SOP

Access the Registration page here: http://192.168.1.3/admin/runner/ Log in as username=’registration’. This may already be done for you. Registration is interested in three links: ‘Persons’ and ‘Racers’, and ‘Groups’

Follow the Racers link or click the add button next to Racers. If the Person does not exist, add then via the link provided. Provide a car name. Select 'Choose file...' for picture. Mobile devices will prompt you for an image source - choose a camera app.

Inspect the car, must meet district standards. Key checks: Wheels must use pre-cut axle slots. The original axle slots must remain at 4 ⅜ inches. The width of the car must not exceed 2 ¾ inches. The overall width includes decoration or weights attached to the sides of the car. Wheels not visibly altered (shape). Car must have approx. 1 cm. clearance on the underside to fit on the track. Car must weigh <= 5.0 oz Overall car length must not exceed 7 inches (including decorations) The car must use the standard, BSA-issue wood, axles, and wheels. Addl components are fine. Wheels must not include washers, hubs, sleeves, or bearings. No liquid lubricants are allowed. Add/update the Racer in the system. Select the Racer’s owner (Person) from the drop-list. Cubs should already be there. Other people will need to be created. Enter the Racer’s name (car name). If they don’t have one, pick something from the ‘Name suggestions’ drop-list. It’s an either-or thing, even though it doesn’t say so. Select a picture > Browse…, then use the camera app Camera FX to snap the pic. Make a note of the Racer’s ID number (it’s on both the Racer list and detail screens) Write the racer’s ID number on the bottom of the car with a sharpie. This number will be used to uniquely identify the car, so be sure it is readable and easy to distinguish (i.e. underline sixes and nines) Add the Racer to the relevant Group(s). You will probably see three Groups, something along the lines of: ‘Cub Primary’ or ‘Open Division’. Add the new Racer to Group(s) as appropriate. Send the Racer car to the race staging area.

Race Runner SOP

Admin: Seed Race, set Currents. Note initial Current.run must belong to Current.race. Go to the Race Control page, requires admin login. http://192.168.1.3/runner/race/current/control/

Click/tap the blue header of the current Run to begin listening for track results for 30 seconds. A count-down is displayed so you always know when it is listening for results. If the program times out waiting for a result, simply click/tap again when ready to begin listening for another 30 seconds. You cannot cancel a listen cycle - just wait for it to timeout. If a Run needs to be re-run, an admin needs to change the Current record to point to the desired Run. There isn’t a way to do this directly from the runner screen (above) at this time. This feature is planned for a future release. Once results are received, you should see them on the runner screen, and the next Run will turn green to indicate it is now the current run.

Update below ip address & embed QR code for the URL, then print a few copies. Registrars can replace 'runner' with 'admin' then log in as 'registration'.

Pack 180 Pinewood Derby Follow along on your own device!

1 Connect to the wi-fi network name = Pack 180 password = derbycar

2 Open this link in your web browser http://192.168.1.3/runner or scan this QR code (e.g. QR Droid, Google Googles, Barcode Scanner, etc.)