Monthly Archives: October 2019

A self-expanding ESP32 PWM board…

I’ve been working on a little ESP32 expansion board/shield for an LED project I’ve been working on. One of the nice things about the ESP32 is that it has a peripheral known as “LED control” that provides 16 independent channels of PWM for controlling LED brightness, and my project uses that capability.

One of my projects is going to require all 16 channels, so I wanted to do a board that would support 16 channels, but I also wanted a version of the board that would only support 8 channels. I started with the 8 channel board and figured out a way to build a single board that would support 8 channels and also function as an expansion board to add the other 8 channels. I thought the approach was interesting enough to share it here…

Let’s start with a picture of the board:

image

I’m using the 20-pin development board, and it turns out that of the 16 channels supported by the LED control peripheral, half of them are on each set of pins. I started doing an 8-channel version of the controller; you can see the primary pins on the right side of the board that come into the center of the board and then head down into the MOSFET region of the board. That design was fairly simple to do.

Then I needed a way to do something with the 8 channels on the other set of pins. At that point, I realized that if I could use the same board to get the other 8 channels if I flipped the board over:

image

On the primary board, the pins for channels 9-16 on the left side of the board are connected to a header. The ESP32 will be connected to headers on the top side of the primary board, and then we will add a header to the primary board expansion pins – pins 9-16 – on the underside of the primary board.

We will then take a second board and flip it upside down. That puts the header pins that are connected to the MOSFETs on the left side of layout directly under the header on the primary board connected to the expansion pins, so we can just put a complementary header on the expansion board and just stack them together.

Here’s what it looks like in the real world. This is the primary board with headers for the ESP-32 on the left and MOSFETs on the right. That is set up for 8-channel mode.IMG_9631

To enable 16-channel mode, we flip this board over and add some headers. The top header connects to pins 9-16 from the ESP32, and then there’s a single pin on the bottom which connects to ground (if I do a future version I’ll add an extra pin on the left) to provide a bit more support.
IMG_9632

We then take a second board and set it up as an expansion board by adding the complementary headers to it.

IMG_9633

We can then finally stack the expansion board on the back of the primary board and add the ESP32:

IMG_9634

That gives us 16 outputs.

Here’s a short video demo of the controller:

And a second video that show my first project using it:


Happy Zoo Year…

Image result for cougar mountain zoo sign

Traditionally, winter has been the off-season for me. It gets rainy so only about half of the Tuesday/Thursday night rides I schedule actually occur, and we’re skiing on the weekends, so I go from 3 rides a week during the season to 1 ride a week, on average. My fitness slowly decreases and, come March, it takes a lot of effort to get it back.

Last fall I realized – I can be a bit slow at times – that since I was now retired, I had the chance to keep a bit more of my fitness by riding more during the winter on weekdays. And perhaps I could keep my climbing legs as well.

I also realized – well, already knew – that my well-known laziness would be the biggest issue, so I needed a more defined goal. So….

12 Months of Zoo

Was born.

The rules are pretty simple:

The first trip was the Sunday of Thanksgiving week,  November 18th at 1:48PM. The climb took me 34:19, which is pretty much average for me. I also climbed the backside of Summit which is sortof on the way back home and features one of my favorite descents to the north.

December weather is always really hit and miss and we are generally skiing the whole month, but the snow was late so I did a quick ride on Saturday, December 15th in the early morning. 35:52. I added in Pinnacles at the top and a really painful climb off of 164th on the way back.

January, the weather, skiing, and seasonal ennui conspired against me, and it wasn’t until 11:02 AM on January 28th that I made the “JanuZoo” ride, completing it in 35:34.

February 2019 was the snowiest month in Seattle in 50 years. Snowy at my house at 300’ means a lot more snowy at 1300’. Eastside Tours rode a total of zero times for the month, the first shutout I can remember in the 15 years that I’ve been on the ride. It froze overnight and then barely got warm enough during the day.

But between storms on February 21st at 1:01PM, I bundled up and headed out into the mid-40s weather, heartened by the a bit of sun. West Lake Sammamish was cold but not icy, at least none that I saw. I hit Newport and started the climb, with remnants of the last storm still piled up to the side of the road. The road was dry-ish, however, so I kept climbing. Pretty much none of the climb had seen any sun and it all had snow on the side, which pushed the temp down into the mid 30s, but it really wasn’t that bad as I climbed at a lackluster 167 watts. I finished the middle part, and turned onto the top – which sees less traffic – and the snow got higher. A few minutes later, I reached the false summit, descended, and got ready for that last little push to the top.

The road was plowed because there’s a reservoir and antennas up there, but not really very well – there were some clear tracks that were not dry and some snow/ice on the road, and 16-18” on the sides. Hmm. 18-20%, check. Air temp just above freezing, check. Areas of dubious traction, check. And I decided that I wasn’t willing to risk the rest of my ski season and the spring biking season just to ride up a short piece of road. So, I got of my bike and hiked up the damn thing, pushing my bike along with me, for the couple of minutes it took to walk to the top and a 36:41 completion time. And the road was fine, at the top, I clipped back in and slowly and carefully rode down, and quickly found out the real problem. Even unzipping, I get sweaty on the climb and the descents are a field experiment in wind-chill factors. The rest of the ride was the minimal one, just to get home.

With all the issues in February, I decided to hit March early, and on March 13th I headed out at noon and rode both Squak Mountain and Zoo. My ancient Garmin Edge 705 crapped out the week before, so I have no riding data to support this ascent, though I will note that there was about 15” of snow at the top of Squak and I have evidentiary pictures of the top of the Zoo. This is mostly the leftovers from the February storms.

ZooUpZooTop


April 7th brought “A Grand Squaky Zoo”, climbing 3 of the 4 big climbs from Sufferin’ Summits – though not the hardest climbs. The Zoo climb was done in 36:03 and 179 watts on my new Garmin 520 Plus (or is that “+”?).

Sunday, May 5th was Day 1 of minicamp where I rode 5 days straight in a quest to jump-start my fitness. It featured Squak, the extremely painful Telus North climb up James Bush Road, and Zoo in 35:21 at 184 watts.

Sunday, June 9th brought the “3 Biggies” – up Grand Ridge, Squak, and Zoo again. Zoo was dispatched at 32:25 at 208 watts, a nice improvement. And June 29th brought “The Reservoir Rendezvous”, with Grand Ridge, Squak, Telus, Zoo, and Summit. It also brought my slowest trip up at 39:55 and 183 watts, because I was chatting with Douglas Migden from Freemont who is training for the Transcontinental race in Europe doing Zoo. He does Pinnacles at the top rather than the classic top, which doesn’t meet my strict definition of a Zoo climb, but I decided to cut him some slack because he was doing it 6 times that day, plus riding from Freemont and back. My slowness was also attributed to a bout of kidney stones on the 19th, which knocked back my training for a 10 days or so.

Two climbs in June made July pretty obvious, with three climbs as the goal. I did them all in one day in the ZooZooZooSummit ride on July 20th. 38:32 @ 169 watts, 37:30 @ 171 watts, and 34:15 at 191 watts. Disappointingly slower than my early June climb, despite having a group to rabbit after on the third trip up. But 5100’ in 36 miles is pretty good.

There’s something a little embarrassing at this point. I did the triple on the assumption that I had started the year of Zoo in August of 2018 to put an emphatic completion on the year. Then I went back and looked at my data and realized that while I had done serious climbing in both September and October, there were no zoo climbs. Sigh.

August 17th was Sufferin’ Summits 2019. I had managed to squeeze in an abscessed tooth in early August for another week off the bike, and then I pulled a hammie playing soccer on the 11th. My zoo climb was 33:16 @ 193 watts, which was somewhat surprisingly my second fastest ascent of the year despite my time off and my goal to ride slowly on this ride. Hill #5 – which includes “the widowmaker” – was the last one I completed on Sufferin’ Summits (not for the first time).

September 7 brought a “Minimal Zoo”, with 20.3 miles and the flattest route up the zoo and back home. 35:03 @ 180 watts and not feeling very good at all despite starting in the afternoon.

October found me seriously – rabidly even – uninterested with the project, but I pulled on riding clothes for what might be the last jersey/shorts climbing day of the year and headed out. I finished with a thoroughly demotivated – and demotivating – 37:47 @ 169 watts, but finish I did, capping off 15 ascents in the period of 12 months. Here’s a picture facing north. The lake is Lake Sammamish, and off in the distance you could see the Olympics and Mt. Baker if they were available to be seen.

IMAG0417

And thereby completes the cycle of the seasons and the year of the zoo…