- ESP32 (microcontroller)
- Lipo battery 11.1v 2200mah
- Generic buck converter 12v to 5v
- MPU6050
- 2 x DRV8825 Stepper Motor Controller
- 2 x Stepper Motor Nema 17
| hash = { | |
| 1 => { c: 2 }, | |
| 2 => { c: 4 }, | |
| } | |
| class Works | |
| def do(a, c:) | |
| puts "a: #{a.inspect}; c: #{c.inspect}" | |
| end | |
| end |
With the variety of server-side technologies today, developers have a lot of choices when it comes to deciding what kind of backend to use for their next application.
In this article, we want to explore the differences between GraphQL and Firebase, two very popular server-side technologies.
Before diving into technical details, let's create some perspective on the two technologies and where they're coming from.
Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.
- Follow standard conventions.
- Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
- Boy scout rule. Leave the campground cleaner than you found it.
- Always find root cause. Always look for the root cause of a problem.
| require 'benchmark' | |
| require 'sidekiq-ent' | |
| require 'redis-lock' | |
| require 'redis-semaphore' | |
| require 'ruby_redis_lock' | |
| # monkey patch to remove exponential backoff in pmckee11-redis-lock, | |
| # otherwise this benchmark does not complete successfully. | |
| class Redis | |
| class Lock |
Tuple Labs Software Vendor Models
These are the models of software vendors we use as a starting point for defining sales strategies at Tuple Labs in Austin, Texas. We think of classes of companies in the space differently so that we can best fit our proposals to deliver high ROI and follow our client company business models. You may use this work as long as you comply with the license terms.
It should be noted that many service providers and companies fall into multiple categories, and that the lines are not as clean as defined herein. At larger companies, one often sees different strategic business units operating under entirely different paradigms. Many offerings have features that blur the distinction between these models - these are simple guideline business models.
Finally, this document not meant to be a highly scientific treatment of the different kinds of software businesses. It is meant to be an approachable introduct
Your challenge, should you accept it, is to write a Ruby library that will modify an existing program to output the number of times a specific method is called.
You solution library should be required at the top of the host program, or via ruby's -r flag (i.e. ruby -r ./solution.rb host_program.rb).
Your solution library should read the environment variable COUNT_CALLS_TO to determine the method it should count. Valid method signatures are Array#map!, ActiveRecord::Base#find, Base64.encode64, etc.
Your solution library should count calls to that method, and print the method signature and the number of times it was called when the program exits.
Also, your solution should have a minimal impact on the program's running time. set_trace_func is a no-go...