2016-12-06

Last week we figured out the map of the train tracks.  This involved finding the location of every point (train track switch) and section of track (area that could be individually powered).  The hardware that was being tested was a proto-board with components to allow for a PIC to be mobile.  To test it the board was programmed to send out valid packets and pulse a heartbeat LED.  The hardware that was tested can be seen on the schematic page.

Goals from previous week:

  • Figure out the bit mapping,
  • Test the hardware

Work Completed:

Greg:

  • Soldered 2 boards for the stations
  • Calculated addresses for sections of track
  • Calculated pins for points (how to control them)
  • Understood how to use the reed switches
  • Developed routing network (Eg North track to South track Eastbound)
  • Created schematics to interface with the points
  • Enhanced schematic to interface with the reed switches
  • Added interface to Bluetooth module
  • Moved to UART1 to keep UART2 open for bluetooth connection
  • Cleaned all tracks
  • Perform test runs on simple routing (N->N, Express->Express, S->S, E-bound)
  • Setup Input Capture to detect train on reed switch

Jack:

  • Got basic Bluetooth communication
  • Determined MAC addresses for all Bluetooth devices
  • Can now communicate with three Bluetooth slave
  • Determined that the BT modules can only connect to a maximum of three devices, unfortunately
  • Began on a workaround for the above problem
  • Began work on receiving information from the slave devices (we had discussed removing this from the project, I was determining how difficult it would be)

Challenges:

  • There are a lot of soldering connections which take a lot of time
  • Bluetooth master can only connect to two slaves

Upcoming Goals:

Greg:

  • Add safety cutout to the train tracks to prevent trains from crashing off the end.
  • Design external interface.

Jack:

  • Interface track control with Bluetooth.
  • Finish commands for individual stations.

Greg and Jack:

  • Build interface to control all of the train tracks.
  • Solder all boards

2016-11-28

Goals for previous week:

  • Perform hardware test on the station boards
  • Create a map of bytes to rail sections
  • Create a map of switch bits
  • Test remaining base stations
  • Build a routing map so that trains can be steered from one area to another
  • Finish implementing basic Bluetooth communication
  • Begin connecting the Bluetooth and the train control

Work Completed:

Greg:

  • Built the hardware for testing multiple stations
  • Created a map of the network

Jack:

  • Found a number of additional bugs with the Bluetooth code

Challenges:

Neither of us were on campus for Thanksgiving break, so not much work could be completed.  Also the soldering irons in the lab are not very efficient making it difficult to build the boards.

Upcoming Goals:

Jack:

  • Finish implementing basic Bluetooth communication
  • Begin connecting the Bluetooth and the train control

Greg

  • Figure out the bit mapping
  • Test the hardware

2016-11-22

Goals for previous week:

  • Capture schematic of base station – Achieved
  • Run diagnostics on all sections of track – 2/5 Stations tested
  • Have a basic Bluetooth setup for testing and proof of concept – Close, hit unexpected complications

Work Completed:

Greg:

  • Captured the schematic required for a base station
  • Programmed a PIC to be able to send valid packets to the train tracks

Jack:

  • Test Bluetooth code written, but still needs to be debugged.
  • Researched Redbear Bluetooth chip.

Challenges:

The biggest challenge at the moment is time management.  With a large amount of additional projects it is challenging to invest enough time into this project.  After Thanksgiving we should be able to add additional time to this project.

Another challenge is working with the Bluetooth code from last year, which is far more hacked together than we initially thought.

Additionally, I found a problem with one of the Bluetooth chips when attempting to change its software from the slave code to the master code. I connect the chip to the computer and it comes up fine, but when I try to copy the updated software onto the chip it disconnects mid-transmission.

Upcoming Goals:

  • Perform hardware test on the station boards
  • Create a map of bytes to rail sections
  • Create a map of switch bits
  • Test remaining base stations
  • Build a routing map so that trains can be steered from one area to another
  • Finish implementing basic Bluetooth communication
  • Begin connecting the Bluetooth and the train control

 

2016-11-13

Goals

  • Get a train to move
  • Get a good packet sent
  • Test all stations

Tasks accomplished

Over the past week a lot of time has been spent on bringing the old hardware back online. On Tuesday we were able to work with the Professor who designed the track and communication protocols many years ago. This allowed us to try sending test packets via RealTerm to an individual station. This allowed us to perform a quick diagnostics on a station but we needed to be next to a computer.

To make it easier to perform the diagnostics a board was designed that would plug into each station and transmit the appropriate packets to power up all of the train tracks. This board will also be able to interface with the BlueTooth connection.

The board had 2 LDOs, one to step from the power supply to 5V and one to step from 5V to 3.3V. This was required since the PIC runs at 3.3V but the UART must be at 5V.

Problems

  • Power supply for PIC
  • BlueTooth connections

To do

Next week the objectives are:

  • Build a protoboard with the components
  • Run diagnostics on all stations
  • Update code to test all PICs and sections of track
  • Start to develop switching logic.