Friday, October 16, 2015

Toy Jeep Makeover

A RC toy jeep is gutted and transplanted with a new controller, a Bluetooth communication module and new sensors.



Toy RC Jeep Newbright Rubicon $9.99
  • One drive motor and one steer motor
  • 49MHz RC
Microcontroller PSOC4 CY8CKIT-049-42XX $3.99


  • PSOC4200 Cortex-M0 processor with digital and analog peripherals
  • USB serial bridge

IMU GY-512 6 DOF MPU-6050 module  $1.94

  • 3-axis gyro and 3-axis accel
  • Motion processor for orientation output







Bluetooth CC2541 Serial Bluetooth 4.0 BLE transceiver module $2.45
  • Bluetooth






Sonar Ultrasonic module HC-SR04 $0.90
  • distance output to 5m





Motor driver DRV8833PWR $0.90
  • dual H-bridges
Power regulator LTC3429

  • 0.5-4.4V input 
  • 3.3V 600mA output


Friday, October 9, 2015

3.3V and 5V Systems

High performance logic has long moved to very low voltages (sub 1V) demanded by nanoscale fabrication technology.  But a lot of systems still use 3.3V and 5V signal interface.  A common problem is interfacing between 3.3V and 5V.  A signal from 3.3V can usually drive the 5V: the TTL minium VIH is 2V, so there is no problem; however, the CMOS is a little borderline, with VIH is usually 0.7*VCC = 3.5V; if the speed is relatively slow, 3.3V can switch correctly.

Going the other way is a little more problematic.  The problem is usually the ESD protection diodes; they will turn on when driven by a 5V signal in a 3.3V supply voltage.  If the drive is robust, it can destroy the protection diode and damage the module.  The safe current limit is usually about 10mA.  So we can place a resistor in series to limit the current.  10mA is actually a lot of current, if the speed is not of concern, the current can be a lot lower, 1-2mA.  The resistance is (5-3.3-0.5)/2m = 600Ohms to 1200Ohms; 1K is a good value.  Sometimes the driver is weak and the output voltage drops quickly when starting sourcing a few milli-amps; it can be connected directly.  However, it is better to be safe.  Other scheme is to use a diode in series, some even suggested using an LED which has a turn-on voltage of 1.7V.  But a resistor has to be used to either pull up or pull down.

Another issue is the voltage supply.  We can start with 5V and drop to 3.3V with an LDO.  Sometimes the system is predominantly 3.3V with only very low current requirement for 5V.  In such a case, a simple charge pump circuit to generate 5V from 3.3V is actually convenient.  Here is the circuit diagram,
an the constructed board (also including a series resistor for signal interface),
It supplies a few milliamps quite nicely.