Friday, February 26, 2021

Computers in Your Camper

With COVID-19, there are a lot of people that have turned to camping for recreation. While some are content to use a tent, a fair number of people are purchasing recreational vehicles (RV) and heading off on road trips. My wife's brother just sold his house and bought a large camper trailer for just such a trip. My cousin is doing the same thing. I have sort of been bitten by the bug as well. I don't plan to convert a Mercedes  Sprinter van into a camper but I do love seeing what people have done to create their own tiny homes on wheels.

Yesterday I came across a person that built a very nice RV that seems to be a very comfortable home. I admired all of the thought they put into their build. Unfortunately they ended up doubling their budget for the camper but have something that would sell for 10 times what they paid. However while watching the video I noticed that they over engineered their electrical system and could have saved some significant money. Part of the problem is their mentality of how we use electricity at home vs. while camping and I hope to fix some misconceptions with this post.

A lot of the RVs being built are meant to be used off the grid. That means people want to pull into the forest somewhere and not have to connect to any water or electrical hookups. That is a noble goal and requires careful planning. Thinking of only electricity, this requires several solar panels on the roof combined with a large battery bank. The video I saw yesterday did an excellent job. Then things got expensive for no reason.

Electricity in our homes uses alternating current (AC). There are 2 reasons for this. The first is that it is a more efficient way to get electricity from the power station to your home. The second is that it is easier to fuse. While you can fuse direct current (DC) power systems, large voltages can jump across open circuits as that is what lightning does. We build appliances for our home to run using alternating current because that is what is available. Solar panels and batteries output DC and so one should spend a little time thinking about the losses converting DC to AC as there are some.

While our home appliances run on AC most of our home electronics such as televisions and computers actually run on DC. The power supply in your desktop computer converts the AC power into DC and delivers it to all of the components into your computer. If you look at the power brick associated with your laptop, it will tell you how much voltage AC it expects in and how much it delivers to your actual computer in DC voltage.

Jumping back to the video I watched, they had some massive Lithium-Ion batteries connected to a very expensive 3000 watt pure sine-wave inverter. The purpose of the inverter is to convert the 12 Volts from the batteries into 120 Volt AC power. The fact that it is a pure sine wave means that it closely matches the power supplied in your regular home power outlet. Advertisers for inverters like this say that it is better for sensitive electronics. The truth is that most of your computer power supplies are very robust and will easily convert a non-pure sine wave to the necessary DC voltage. What really needs pure sine wave power are things like electrical motors and refrigerators. Another thing to note is that the pure sine-wave inverter is only 90% efficient at optimum load. That means that the best case scenario is that you are wasting 10% of your electricity.

The thing that really disturbed me about the video is seeing that the inverter had several power strips plugged into it only to have every cord convert that AC power back to DC power. There is also power loss converting AC power to DC. It would be much better to run everything in the camper off of DC power and only use the inverter for things that really need AC power. Let's be honest, if you are building a camper you can find most of your appliances and electronic equipment that will run on DC power. Doing so would allow you to use a less expensive inverter and you could also downsize the number of Lithium-Ion batteries required.

So if you find yourself deciding to build your own camper van, pay attention to your electrical needs. There are a number of products that don't need AC power. You can find fans, lights, refrigerators, and many other electrical devices that run on DC power. If you do a bit of research, you can even figure out how to power your laptop and monitors using DC power. This will save you money in the long run and give you more power given your battery and solar charging capacity.

Thursday, February 25, 2021

Learning Requires Practice

Last night I sat down to practice guitar and I once again reminded myself how important it is to practice when learning any skill. Playing my guitar is not the only thing I practiced yesterday and I realized that I spent most of my day practicing.

I woke up in the morning and spent an hour skiing before work. My wife joined me and we had a fairly relaxed morning until we headed up the Little Cloud chairlift at Snowbird. Then we got caught in a snowstorm that reduced visibility to about 10 feet. White snow in a white cloud on a white slope made it impossible to see anything but my skis in front of me. While I normally ski that run at 50 miles per hour or faster, I came down at a gingerly 15. Once we descended below the cloud, I remarked to my wife that I practiced skiing blind. She agreed.

Next I practiced my computer skills at work. I am hosting a technology workshop for the department next month and we will be using a new whiteboarding-collaboration tool that I spent time exploring. Any time I learn a new tool, it can be considered practice. I practice with computer software a lot.

When my workday ended, I needed to wax a couple pairs of skis. While I have done a fair amount of ski tuning, every time I pull out the waxing iron I learn something new. Sometimes it is just how hot the waxing iron gets. Last night I learned that if I turn the iron up 5 degrees warmer than recommended, the wax spreads so much easier. You do run the risk of burning the wax but the job takes about 20% less time.

Then I sat down with my guitar. I've been practicing the guitar for quite a few years but there is a lot to learn. One thing the guitar reminded me is that I don't need to practice stuff I know well. Instead I should practice things that are difficult. Last night I worked on some specific chords along with different fingering styles. I sort of felt like a beginner all over again. Fortunately that just means I learned something.

When you sit down in front of your computer and things don't seem to make sense, don't get frustrated. Instead look at it as an opportunity to learn something. What are you missing? Is there a step you skipped over? Is the answer somewhere else on the screen and you just keep looking in the wrong place? Fortunately someone has probably already had the same question and it is just a matter of doing an Internet search and you shouldn't be stuck too long.

Wednesday, February 17, 2021

Doordash Doesn't Deliver During Snowstorms

Today we have a new person starting on the team at work and so the manager arranged lunch for everyone. That means I got a gift certificate for Doordash. My daughter is home with me because she can't get up the canyon for her job at Alta due to a massive snowstorm right now. I asked her if she wanted to share lunch with me. We decided on pizza and so I logged onto the site to order it. Guess what? That same snowstorm that is keeping my daughter from getting to work is also keeping Doordash from delivering a pizza. I probably should have figured that one out on my own.

Friday, February 12, 2021

My Hackathon Project

A couple of times a year we get to participate in hackathon projects at work. This allows people to work on things that interest them above and beyond their daily work. Our latest hackathon finished a week ago and I had a really great time.

Most hackathon projects are related to the PlayStation but I decided to do something a bit different. Several years ago I came up with the idea of attaching a speaker to my skis so that I would be able to find them if I lost them on a powdery day. For those that don't ski, bindings are meant to release your skis in the event of a fall so that they don't cause damage to your body. Ski brakes then extend into the snow and keep the skis from running away down the hill. The system works great most of the time with fresh powder being the exception. When you lose your skis on a powdery day, it is anyone's guess as to where they are.

My idea is to being able to have the speaker start making noise when you activate it with your smartphone. I bought a $30 microcontroller board with Bluetooth capabilities, a small buzzer, and a Lithium-ion battery. It didn't take long to put everything together and modify a few sample programs to get the board talking with my mobile phone. I could turn the buzzer on and off from my phone before going to bed on the first night of the event.

I woke up the next morning and took the device to Snowbird ski resort to do some testing. The first thing I wanted to check is how loud the buzzer was. Unfortunately, it wasn't that loud. Not wanting to waste the day, I next checked how far the Bluetooth worked. At around 150 feet or 50 meters, I could still communicate with the microcontroller from my smartphone which is more than enough distance. I found that to be encouraging and came home to work on the low-sound issue.

I replaced the buzzer with a speaker but that didn't help at all. The microcontroller just didn't have enough power to drive the speaker very loudly. As I felt stuck with the buzzer, I actually soldered the buzzer to the microcontroller board. That increased the sound output by 3 times. I could now hear the device from 60 feet away instead of just 20.

The next day I headed up to Alta ski resort and waited for the lifts to start carrying skiers to the top of the mountain. We had several inches of new snow and that made for great test conditions. While waiting in line, I ran over to an area of fresh snow and buried the microcontroller about 6 inches deep. I activated the buzzer and didn't hear a blasted thing. It turns out snow is a great sound insulator. While I felt disappointed, I still had one more test to perform: battery life in the cold conditions. That means I spent 2 hours powder skiing with the device turned on and communicating with my smartphone. I had my daughter with me who is an excellent powder skier and we had a lot of fun.

Now someone reviewing my hackathon project  might think I wasted the company's time by working on a device that has no relevance to video games. The reality is that I have never worked with a microcontroller before and this served as an entrance for me to other hardware projects. I actually have a very good idea for my next hackathon. I will use the same microcontroller board with a few of its analog-to-digital inputs to help create a new type of controller. I won't say more than that but it will definitely be related to video games and how to make them better.