Improving Signal to Noise

I’ve been puttering away at a few things over the past week:

  • A WS2812B 2020 form factor carrier board with 8 LEDs to make pretty side/top/front decals for both of up upcoming bots
  • Trying to get a prototype radio transmitter together
  • Hitting F5 watching my BDB PCBs move from production to shipped!

Custom Controller Attempt 1: Retrofit a PS2 controller

My first idea was that rather than starting from scratch, I should retrofit a PS1 controller with a Flysky Tanaris module, and an arduino.

I created a PS1 controller using a PIC16F84 back in highschool, so I figgured that with a modern arduino it should be pretty easy to go the other way.

Parts:

  • 1x Arduino Nano 33 IoT - Tested, works well
  • 1x 16340 3.3+5V battery/charger/regulator module - Tested, works well
  • 1x I2C LCD 128x64px monochrome display - Tested, works well
  • 1x PS2 controller - Arduino can read it, but the data looks fishy
  • 1x Flysky Tanaris module - Untested, but google says it takes 5V, GND, and PPM, and that seems easy to generate

As luck would have it, it was fairly straight forward to get most of the controller pieces together, however victory was hollow. The knockoff PS2 controller I cut apart had absolutely terrible analog range, and the triggers were digital, which the d-pad was analog. Little brother mode indeed. I decided to take the somewhat longer path of designing and printing my own controller instead.

Custom Controller Attempt 2: Build a controller from scratch

With one setback on this project, it seemed prudent to proceed with the longer, but maybe more straightforward plan of building my own controller.

I’ve built a custom controller before (arduino nano, 2x analog sticks, LiPO battery, NRF24l01) for the pair of quadcopters I build in 2013/2014.

My plan was to print something like a PS2 controller, but with a screen and less buttons.

On the plane heading to a work trip I sketched out a state machine for the menus on the screen, but there was one thing that was nagging me.

Rememeber last week when I listed “Test early in isolation” and “Expect failure”. While on the work trip, the fact that I hadn’t actually tested tranmitting using the Flysky tanaris module was nagging at me.

As you can probably guess, problems abound!

Challenges:

  • The Arduino Nano IoT 33 is very new and uses a relatively unsupported and sparsely documented SAMD21 arduino integration
    • As a result a lot of Arduino libraries don’t work out of the box, especially ones using timers or specific hardware port access
  • Even after getting PPM input and output working well together, the flysky tanaris module didn’t seem to want to work
  • There was no documentation at all on the Tanaris module, which I had hoped meant that it was straight forward, but instead left me without much to dig into

I tried a few things:

  • Binding my FS-i6X transmitter to:
    • FS-RX2A receiver via iBUS: Worked
    • FS82 receiver via iBUS: Worked
    • FS-i10B via iBUS: Worked
    • FS-i10B via PPM: Worked
    • FS-i10B via PWM: Worked
  • Binding the Arduino->Flysky Tanaris transmitter to:
    • FS-RX2A receiver via iBUS: Nothing
    • FS82 receiver via iBUS: A bit of noise on channel 1
    • FS-i10B via iBUS: Nothing
    • FS-i10B via PPM: Nothing
    • FS-i10B via PWM: Nothing
  • Logic level converting from 3.3V to 5V for the PPM input on the tanaris module: Nothing

This highlights how important testing each component in isolation is before getting too deep into a project.

Next Steps

I’m looking at one of three options for the controller now:

  • Get a nice OpenTX transmitter that I can hack to my heart’s content (I’m looking at the Flysky Nirvana at ~$180, which is pretty pricy but good value versus most others)
  • Order a different Flysky compatible TX module and carry on with the custom controller (I’ve ordered one, but it’s not siginificantly more likely to work than the one I tried already)
  • Keep using my FS-i6X and possibly just have a telemetry module as a bolt-on attachment

Gantt Update #2

gantt
dateFormat  YYY-MM-DD
title The Gantt to Motorama

section First Strike v2
Chassis v3            :active,  crit,  fs1, 2019-11-24, 10d
Weapon  A           :   crit, fs2, after fs1, 10d
Chassis v4              :  crit, fs3, after bdb404, 14d
Weapon B? : fs4, after fs3, 10d
LEDs : done, fs4, after fs3, 7d
Drive Test+Refine : crit, fs4, after fs3, 14d
Chassis v5? : 10d
Armor Fab. : crit, 10d
Stand : 3d
Spares? : 10d
Motorama!               :         motorama, 2020-02-14, 3d

section Z Offset +2.0000
Chassis v2            :active,  crit,  zo1, 2019-11-24, 14d
Lifter v2           :   crit, zo2, after zo1, 10d
Chassis v3              :  crit, zo3, after bdb404, 14d
LEDs : done, fs4, after fs3, 7d
Drive Test+Refine : crit, fs4, after fs3, 14d
Armor Fab. : crit, 21d
Stand : 3d
Spares? : 10d
Motorama!               :         motorama, 2020-02-14, 3d


section Controller
Integrate : 2019-12-25, 2w
Refine : 2w

section BotDriverBoard
v4 Design            :done,    bdb401, 2019-11-08,2019-11-11
v4 Manufacture               :done,  bdb402, after bdb401, 12d
v4 PCB Ships               :active, crit,  bdb403, after bdb402, 10d
v4 Test               :        crit,  bdb404, after bdb403, 5d
v4.1 Design            :done,    bdb411, 2019-11-11,2019-11-12
v4.1 Manufacture               :active,  bdb412, after bdb411, 21d
v4.1 PCB Ships               :         bdb413, after bdb412, 10d
Test 4.1               :         bdb414, after bdb413, 14d
v5 Design? : 7d
v5 Manufacture? : 21d
v5 Ship? : 10d
v5 Test? : 7d

The Road to Motorama 2020

Today my Motorama Robot Conflict 2020 registration was approved! Builder’s DB signup in, paperwork signed and submitted, and payment received.

Here’s what I’m working on!

The High Level Plan

  • First Strike v2: Improved weapon engagement, smaller, better driving
  • Z Offset +2.0000: New skeleton (Not PETG!), reinforced lifter joint+arm,
  • Pwny Botstation v1
    • A “simple” custom controller closer to a console gamepad built specifically for combat robotics
    • Uses a Flysky Tanaris module (to make safety compliance simpler) for downstream control
    • An ESP8266 based telemetry flight recorder
    • A display
    • RGB LEDs?
  • BotDriverBoard: A custom PCB designed to replace the existing dual brushed ESC carrier that I’ve been using so far. Highlights:
    • WIFI Telemetry
    • Custom channel mixing
    • Enough current to handle Ant+Beetles
    • Room for future growth
    • Low low BOM (< $15 CAD)
    • RGB LEDs?

Strategy

  • Rapid prototyping
  • Expect failutre:
    • Pad timelines (especially shipping!)
    • Test early in isolation
  • BDB can be cut, using the existing generic controllers (In fact, BDB v3 was cut just 10 days before BotBrawl #10!)
  • Pwny Botstation can be cut entirely, using the FlySky i6x that I’m currently using (Idea was on hold until after BotBrawl #10)

A Gantt for the Ant (and Beetle)

gantt
dateFormat  YYY-MM-DD
title The Gantt to Motorama

section First Strike v2
Chassis v3            :active,  crit,  fs1, 2019-11-16, 10d
Weapon  A           :   crit, fs2, after fs1, 10d
Chassis v4              :  crit, fs3, after bdb404, 14d
Weapon B? : fs4, after fs3, 10d
LEDs : fs4, after fs3, 7d
Drive Test+Refine : crit, fs4, after fs3, 14d
Chassis v5? : 10d
Armor Fab. : crit, 10d
Stand : 3d
Spares? : 10d
Motorama!               :         motorama, 2020-02-14, 3d

section Z Offset +2.0000
Chassis v2            :active,  crit,  zo1, 2019-11-16, 14d
Lifter v2           :   crit, zo2, after zo1, 10d
Chassis v3              :  crit, zo3, after bdb404, 14d
LEDs : fs4, after fs3, 7d
Drive Test+Refine : crit, fs4, after fs3, 14d
Armor Fab. : crit, 21d
Stand : 3d
Spares? : 10d
Motorama!               :         motorama, 2020-02-14, 3d


section Pwny Botstation
Concept           :done,    nc1, 2019-11-12, 2019-11-15
HW Prototype : active, nc2, after nc1, 14d
SW Prototype : active,        nc3, after nc1, 14d
Refine : 21d
Pretty Version : 21d
Order Spare Parts? : 35d

section BotDriverBoard
v4 Design            :done,    bdb401, 2019-11-08,2019-11-11
v4 Manufacture               :active,  crit, bdb402, after bdb401, 12d
v4 PCB Ships               :       crit,  bdb403, after bdb402, 10d
v4 Test               :        crit,  bdb404, after bdb403, 5d
v4.1 Design            :done,    bdb411, 2019-11-11,2019-11-12
v4.1 Manufacture               :active,  bdb412, after bdb411, 21d
v4.1 PCB Ships               :         bdb413, after bdb412, 10d
Test 4.1               :         bdb414, after bdb413, 14d
v5 Design? : 7d
v5 Manufacture? : 21d
v5 Ship? : 10d
v5 Test? : 7d

Service has been restored

My migrated server is finally back up and running!

1
2
while True:
print("Yay!") # yes, 3

Now to migrate over my old blog posts…