Arduino app to set DS1307 Real Time Clocks.

I use a number of implementations of the DS1307 or DS3231 Real Time Clock chip, preferably the latter these days as they are considerably more accurate and compatible with DS1307 code.

In some applications, it is necessary or sometimes just better to preset the clock before connecting it into the application, and the need arises to set the clock ‘stand alone’. The method I have used for this has been clumsy and not as accurate as one might want for the DS3231, so this article describes a new solution.

IMG_1563

The solution uses an Arduino as the engine if you like. Above is an Arduino Pro, but a range of similar Arduinos would be equally suitable. ALso pictured are three RTCs, one connected to pins A2, A3, A4 and A5 providing GND, VCC, SDA and CLK respectively. Continue reading Arduino app to set DS1307 Real Time Clocks.

Counterfeit FTDI

I purchased a USB-RS232 adapter which claimed to use an FTDI chipset.

HXSP-2108D

Above is a pic of the device, branded Hexin model HXSP-2108D.

The device delivered pretends to be FTDI to the extent it ships with a FTDI driver disk, uses FTDI’s VID and PID to identify to USB, and works to some extent with separately sourced FTDI drivers, but it does not use FTDI chips. Attempts to read the chip with FTPROG return an empty EEPROM that cannot be programmed… in fact it causes errors in FTPROG.

eBay effectively supports these sellers of counterfeit goods as they require return of the goods to the seller for possible refund, and in this case that would cost about the same as was paid for the goods.

The seller insisted that they would test it and return it or a replacement, carefully avoiding the question of whether it used a genuine FTDI chipset, further reason to not return it as it would just cost good money to get the same counterfeit product back..

eBay harbours counterfeiters, and whilst I have bought plenty of FTDI based devices that appeared genuine (eg using FTPROG), this Hexin product is an incomplete knock off.

Precision GPS experiment #1

This article reports an experiment to evaluate the usefulness of precision GPS for the purpose of location data for automated antenna field strength surveys.

The experiment was conducted with the rover located in a fixed location 13km North of the reference station at Symonston and with very wide view of the sky, about 7:00 am 07/04/2016.

Only GPS satellites were used for the rover.

The software was RTKLIB v2.4.3b8.

IMG_0505

The GPS was a UBLOX LEA-6T with a small patch antenna (as sold for small UAVs). The LEA-6T provides binary data as used by RTK for carrier phase measurements. Above is the GPS and a USB-RS232 adapter. Continue reading Precision GPS experiment #1

CH340, CH341 USB to RS-232 chip compatibility

One of the several sources of chips for USB to RS-232 converters is WCH, a Chinese firm offering their CH340 and CH341 chipsets.

CH340T

Information is scarce as their website is mostly in Chinese language.

CH34x chips have become more common, perhaps as consumers have fled the Chinese Prolific product line (for good reason).

In true Chinese style, downgrade knock offs of Arduino boards (eg the Arduino nano) have appeared, the downgrade is achieved by use of CH340 USB to RS-232 converters instead of the FTDI chips on the genuine nano. Continue reading CH340, CH341 USB to RS-232 chip compatibility

A low cost home made USB CI-V interface with open collector and solid Windows drivers

This article describes an inexpensive USB adapter for Icom’s CI-V interface.

There are four common options for USB-serial adapters:

  • Prolific;
  • FTDI;
  • WCH; and
  • Silabs.

This article describes an adapter based on an inexpensive FTDI adapter (~$5 on eBay).

opc478ftdi01

You will need the module, a Schottky signal diode (eg 1N5711), wire and a 3.5mm TRS plug or two. I have connected two plugs, one wired for TS (CT-17) and one for RS (OPC-478x). Continue reading A low cost home made USB CI-V interface with open collector and solid Windows drivers

Revised thinking on STC chips

I have successfully implemented a few projects on the STC 15F104E, a Chinese 8051 architecture MCU.

STC15fF04EThe chip includes EEPROM, and some flexible extensions to the timers which potentially make it more useful than a standard 8051.

I have previously observed that the documentation is poor, and the programming tool is poor.

The project that led to the latest observations was an attempt to implement RC PWM – ON/OFF switch originally on one of these chips as it contained sufficient resources to suit the application. One of those resources was an +/- edge triggered INT0.

The code worked fine, but for only a short and variable period. Essentially, the the main loop was executing fine, the chip stopped triggering the interrupt service routing for INT0 after a variable time from 10s to 1000s… but it ALWAYS stopped working. Cycle the power and the same thing is observed. Continue reading Revised thinking on STC chips

RC PWM – ON/OFF switch

This article describes a remote ON/OFF switch which uses an RC receiver and adapter chip to convert the RC PWM signal into an ON/OFF output. (Suitable RC transmitters are on hand.)

The immediate application is for remote ON/OFF PTT or KEY of a transmitter for field strength testing at various locations.

Background

Remote control hobbies have long used a multi channel digital proportional protocol for control of planes etc. The simplest multi channel receiver has an independent PWM output for each servo.

The PWM signal is a 1000-2000µs pulse with a repetition rate from about 50Hz up to 500Hz or so, the duration of the pulse conveys the information.

Implementation

The converter chip is a ATTiny25 MCU with firmware that monitors the PWM stream and provides ON/OFF and OFF/ON output pins. For the immediate application, the ON/OFF (or non inverted) output drives a 2N7000 FET with ‘open collector’ output suited to the PTT and KEY lines of most modern transceivers.

The firmware ignores PWM signals with duration outside the range 900µs to 2100µs, and switches ON at 1600µs, and OFF at 1400µs to provide some hysteresis. If PWM input is lost for 125ms, the output will fail safe OFF.

rcsw01Above is the schematic. The 2N7000 is good for 60V, can handle up to 100mA without a heat sink, and had a body diode to absorb transients if the load is a relay. Continue reading RC PWM – ON/OFF switch

Trial of prototype stand alone GPS logger

An upcoming project calls for a stand alone GPS logger.

The requirement is for a GPS stream that allows correction using RTKLIB, but this trial is of a lesser GPS as proof of concept.

SAGPS001

Above, the equipment consists here of a Ublox NEO-6M based GPS module (~A$15 incl on eBay) at left, an Openlogger (~A$15 incl post on eBay) at right, and a 12V-5V converter (~A$7 from Hobbyking) at bottom. The latter is a 5A converter, way overkill, but it was on hand. The GPS module has a 3V regulator on board for the NEO-6M chip.
Continue reading Trial of prototype stand alone GPS logger

OpenLog for TinyTrak – drive test

OpenLog07

A drive test of the OpenLog logger collecting raw NMEA data in parallel with the TinyTrak (VHF) was conducted. To maximise the performance of APRS, a fill-in digi / iGate was run at my home. The tracker used a 65W transmitter with quarter wave vertical in the centre of the car roof.

Google Earth googleearth 29/10/2015 , 08:19:01

Above is an overview of the APRS and OpenLog tracks. Click on the image for a scaleable / zoomable view in Google Maps. Continue reading OpenLog for TinyTrak – drive test

OpenLog for TinyTrak

There are a host of factors that contribute to data loss in APRS, to name just some:

  • non-standard / sub-standard / poorly configured digipeaters;
  • defect ridden iGates that lose, duplicate and corrupt packets;
  • poorly configured mobiles;
  • network congestion and interference;
  • unpredictable equipment failures;
  • basic geographical coverage of the network; and
  • dependence on the ionosphere for HF APRS.

This article describes an enhancement to the popular TinyTrak (and its clones) to also capture the GPS stream to an inexpensive local data logger.

The logger does not interfere with normal radio APRS, it coexists with it and creates a properly timestamped fine detail log of positions over a very long time, a log that can be post processed into a range of graphic / map and tabular reports.

Data logger

The datalogger used in an OpenLog. It is a simple logger that writes data to a micro SD card, costs about $A12 (inc post) for the logger and about A$10 (inc post) for a 16GB Class 10 micro SD card. (A slower card could be used, but they aren’t much cheaper.)

OpenLog05

Above, the OpenLog data logger.
Continue reading OpenLog for TinyTrak