Showing posts with label RS-232. Show all posts
Showing posts with label RS-232. Show all posts

Wednesday, August 3, 2011

PIC24 USB + Serial Development Board



Two main emphasis of this board are USB and Serial as well as using socketed components.  The 28-pin PIC24FJ64GB002 can perform as either a USB host or USB device, using jumpers to select between the connected USB socket.  The USB jumpers are also configured so when the PIC is USB host using the USB-A connector to attach a thumb drive, the USB-B connector may be configured to attach to an FTDI FT232RL chip to act as USB serial.  Using a USB-A to USB-B adapter, both the PIC and the FTDI chips could be active as USB devices. 

Two serial channels are jumpered for either RS-485 or RS-232 (DB-9 connectors not shown), or the second serial channel can be jumpered to the FTDI USB serial connection.  As configured here, RS-485 uses RX/TX with RTS to select whether reading or writing.  RS-232 can use RX/TX with CTS/RTS.  The ICSP (in circuit serial programming) connection in the lower left works with ICD or PICKit programmers, and shares the lines that provide CTS/RTS, so jumpers are provided to choose between those functions.  The PIC24 has quite a few 5V tolerant inputs, but I ran out of enough of them, so a 5V/3V3 logic level conversion board is socketed to read the CTS lines at 3.3V from the 5V MAX232 and MAX233

Voltage regulators are included to power 3.3V and 5V buses, accepting power from USB or 7V-12V external power.  Each module has a power jumper to effectively disable them.  The USB sockets have jumpers to selectively attach power to the 5V bus.

One SPI channel is also configured, allowing connection of features such as a micro SD card and/or SPI Ethernet.  This board specifically supports connection of a Microchip's PICtail Ethernet (ENC28J60) board.   

Saturday, July 30, 2011

TTL/RS-232 module



I developed this TTL/RS232 module using a typical MAX232 chip.  It is a RS-232 serial communiations transceiver with two transmit and two receive channels.  It converts from TTL logic (0V=low, 5V=high) to RS-232 signals (approximately -10V to +10V in this case); see the datasheet for more specifics.  The 6 pin header has 5V, GND, RX, TX, DTR, CTS.  The 10 pin header includes all the DB-9 pins, with the DB-9 female connector attached via ribbon cable and socket.  This model of the Maxim chip uses 0.1uF capacitors.  I could have used the MAX233 which has is an extra 2 pins wide but doesn't need any added capacitors so is easier to work with.  LEDs are included to show send/receive and cts/rts activity.  Two of the resistors for the LEDs ended up on the reverse side of the board.