Chris, I'll look in to it. Did you read my latest post on the the forum about an idea to replace the relays with 74LS244N s and 74LS32Ns? GOD Bless and Thanks, rich! On 11/14/2017 11:45 PM, Chris Roper wrote: > Take a look at http://gcbasic.com/ > It is a compiler, it supports your device, has drivers / examples for mos= t > of what you have mentioned, is far easier than Assembler or C and is free= .. > To set up a serial connection via FTDI and control an LCD is only about > half a dozen lines of code in GCBASIC. > I also find that the code it generates is far better optimized than XC8 > code. > It is a great way to get started but is by no means confined only to > beginners it had some very advanced capabilities, supports over 1100 chip= s > from the PIC and AVR families with full portability. > > Cheers > Chris > > > > > On 15 November 2017 at 01:42, Richard Pope wrote= : > >> Hello James, Jeff, Tony, >> I considered the Arduino and the ATMEGA32 but I needed a lot of I/= O >> and I don't need CPP or Analog. Yes, there is more support for the >> Arduino but there is a lot out there for the PIC. I could use some more >> I/O pins. I am using shift registers to control the address lines going >> to the programming socket and a 8 to 3 encoder chip for the interrupts. >> The FTDI chip that I am considering is a FT232RL. It will be >> connected to the PIC in a direct manner and only the USB side will be >> able to connect to a PC. I know that the RS232 port on the PIC swings 0 >> to 5 volts. I'll have to check the datasheet for the FT232RL to see if >> it swings 0 to 3.3 or 5 volts. I don't know. >> I use C to do my coding. I understand Assembly to a certain point. >> I am able to follow along the code and see what is going on but I have a >> difficult time creating my own Assembly programs. I am going to run the >> 4520 at 40MHz so speed isn't going to be a big issue for the programmer. >> Right now I am using relays to switch the Address lines and various >> programming voltages to the appropriate pins on the programming socket. >> I found a program for controlling a LCD on the MC website. The >> only problem is that I can't find where that Data Pins are being >> defined. I found the definitions for the control lines. >> Thanks, >> rich! >> >> On 11/14/2017 3:18 PM, James Cameron wrote: >>> Thanks for the STM32 Blue Pill reference. An interesting looking board= .. >>> >>> On Tue, Nov 14, 2017 at 03:04:26PM +0000, Clint Jay wrote: >>>> Jeff, you raise good points but I would prefer to be safe than sorry, >>>> designing/building and coding for the MAX232 or other serial driver wi= ll >>>> ensure compatibility (as far as RS-232 is able to be compatible) with >> the >>>> widest range of PCs and prevent anything 'unpleasant' happening if the >>>> device is plugged into an unknown machine. >>>> >>>> As heretical as it would seem I'd have to admit you may have a point >> about >>>> Arduino, it's a known hardware platform that is proven to work. >>>> >>>> Similarly, I've been exploring options with STM32 Blue Pill boards >> recently >>>> but I still like and write code for PIC devices, as and when I need >> extra >>>> horsepower I may well leave the PIC Path and move to ARM, they're *so* >>>> cheap and have an abundance of facilities. >>>> >>>> >>>> >>>> On 14 November 2017 at 14:54, Byron Jeff wrote= : >>>> >>>>> Tony, >>>>> >>>>> There are actually two types of FTDI serial ports. There is the RS232 >> one >>>>> with a DB9 connector on the end. Typically that port will signal >> between >>>>> +/- 7 volts or so. Then there are the small FTDI TTL serial adapters. >>>>> Depending on configuration they will swing either between 0 and 5 >> volts or >>>>> 0 and 3.3 volts. >>>>> >>>>> In today's serial PC world rarely does an actual MAX232 need to be >> used for >>>>> level translation. Even with actual RS232 ports, virtually all of the= m >>>>> signal properly with a 0/5V TTL signal. Note that the sign is inverte= d >> such >>>>> that a logical 1 is represented by 0V and a zero by 5V. >>>>> >>>>> For years I've used a simple voltage clamp to limit the swings. The >> basic >>>>> circuit is here: https://i.stack.imgur.com/jyZvD.gif D1 conducts when >> Vin >>>>> is above VMax and D2 conducts then Vin is below Vmin. R limits the >> current. >>>>> I typically put a second resistor after the clamp. I find that 1K for >> both >>>>> works well with PIC inputs. >>>>> >>>>> A couple of variations are helpful. If D1 and D2 are Schotty diodes >> then >>>>> the voltage overshoot is typically only 0.3V or so. Also if D2 is a >> Zener >>>>> then D1 is unnecessary because the Zener action will limit the high >> voltage >>>>> while normal conduction clamps the low voltage. >>>>> >>>>> With the signal inverted there are a few things you can do to manage >> it. >>>>> I've been using PIC24FV parts for several years. The hardware EUARTS = on >>>>> them can be inverted in software. It is also possible to bit bang a >> digital >>>>> input/output for serial. Otherwise a NPN transistor whose base is >> connected >>>>> to Vout, emitter grounded, and a pullup collector will invert the >> signal in >>>>> hardware. >>>>> >>>>> Another thought that may be traitorous on this board: ever considered >> an >>>>> Arduino? Complete boards with the USB serial adapter on board clock i= n >> at >>>>> about $5 USD. Boards like a Nano will plug right into a breadboard. >> Plug in >>>>> a USB cable, load the Arduino IDE and you're going literally in about= 5 >>>>> minutes. Tons of libraries already built into the platform. >>>>> >>>>> As I've progressed in the hobby, I find that sometimes it's just more >>>>> trouble than it's worth to try to roll everything from scratch. Back >> in the >>>>> PIC 16C54 days, the price and functionality was a compelling reason t= o >>>>> switch as compared to the alternatives. But in 2017 with high level >> boards >>>>> such as a Raspberry PI Zero W that runs Linux and having a complete >>>>> wireles setup >>>>> for less than $10 USD and Arduino clones literally running 5 for $20, >> it >>>>> becomes more difficult to justify wiring up a board from scratch and >>>>> programming in assembly anymore. Those who have never done it may nee= d >> the >>>>> experience. But those of us who have a closetfull of t-shirts with >>>>> 'Assembly coder' emblazoned upon them? Not so much. I find now that I >> spend >>>>> more time and energy trying to match the hardware/firmware to the >>>>> application. It literally may be more adventageous to throw a RasPi >> ZeroW >>>>> into a problem to make a wireless remote light switch than any >> alternative >>>>> for >>>>> example. >>>>> >>>>> BAJ >>>>> >>>>> On Wed, Nov 15, 2017 at 12:54:26AM +1100, Anthony Nixon wrote: >>>>>> You wont need a level translator with the FTDI chip. It will directl= y >>>>>> interface to the PIC, and the FTDI directly interfaces to the USB po= rt >>>>>> with the right support components which are just a handful of >>>>>> passives. >>>>>> >>>>>> The trick is whether or not the FTDI will be powered by the USB port >>>>>> or by the PIC circuit. >>>>>> >>>>>> cheers >>>>>> >>>>>> Tony >>>>>> >>>>>> On Tue, Nov 14, 2017 at 11:56 PM, Richard Pope < >> mechanic_2@charter.net> >>>>> wrote: >>>>>>> Clint, >>>>>>> I'll do that this evening after I get up. I appreciate the >> insight >>>>>>> and help! I will probably have to use a MAX232 to do the level >>>>>>> translation. I appreciate you reminding me of that. >>>>>>> Thanks, >>>>>>> rich! >>>>>>> >>>>>>> On 11/14/2017 6:47 AM, Clint Jay wrote: >>>>>>>> There may be, I've usually just rolled my own routines to service >> the >>>>>>>> EUSART though I haven't used the '4520 specifically. >>>>>>>> >>>>>>>> I don't think there are huge differences between most EUSART >>>>> enabled mid >>>>>>>> range devices so there should be plenty of example code to examine >> and >>>>>>>> modify for your needs. >>>>>>>> >>>>>>>> You'll need a level translator if you're going PIC to PC directly. >>>>>>>> >>>>>>>> On 14 Nov 2017 12:36, "Richard Pope" >> wrote: >>>>>>>>> Clint, >>>>>>>>> Yes, I am using a FTDI to RS232 converter to hook the PC = to >> the >>>>>>>>> PIC. I just found out that all that I need to do is treat the >>>>> connection >>>>>>>>> to the PIC as a Serial connection. Is there a MC Serial Library >>>>>>>>> available? I'm the one that was confused. >>>>>>>>> Thanks, >>>>>>>>> rich! >>>>>>>>> >>>>>>>>> On 11/14/2017 6:28 AM, Clint Jay wrote: >>>>>>>>>> I'm a little confused but the way I read your message would >> suggest >>>>> that >>>>>>>>>> you're going to connect your PIC to the PC with an FTDI USB to >>>>> serial >>>>>>>>>> device? >>>>>>>>>> >>>>>>>>>> Or have I misunderstood and you're hoping to connect the PIC to >> the >>>>> FTDI >>>>>>>>>> with USB? >>>>>>>>>> >>>>>>>>>> On 14 Nov 2017 12:25, "Richard Pope" >>>>> wrote: >>>>>>>>>> HELLO ALL, >>>>>>>>>> . . . . I could really use some help with using USB on the PIC >>>>> 18F4520. >>>>>>>>>> I am going to use a FTDI USB to RS232 converter to talk to the P= IC >>>>>>>>>> 18F4520 Through the RX and TX Pins. I want to send Configuration >>>>> Code to >>>>>>>>>> a 24C512 serial EPROM. When I add additional devices I want to b= e >>>>> able >>>>>>>>>> to update the EPROM. I also want to be able to use a Win 8.1 64b= it >>>>> Pro >>>>>>>>>> PC to control the Programmer. I also do a lot of searching and >>>>> research >>>>>>>>>> on materials that I acquire from the MicroChip website. I have >> been >>>>>>>>>> reading the MC USB Device Firmware Framework User's Guide. >>>>>>>>>> . . . . I have the latest version of MpLab, and the latest >>>>> versions of >>>>>>>>>> the X8, X18, and X32 Compilers installed. I also see that I need >> to >>>>>>>>>> install the latest versions of C30 C and C18 C Compilers and set= up >>>>> the >>>>>>>>>> proper Paths for these files. I don't mind doing the footwork. I >> am >>>>>>>>>> Disabled and retired. This gives me a lot of free time. >>>>>>>>>> Thanks, >>>>>>>>>> >>>>>>>>>> Richard R. Pope >>>>>>>>>> 1230 19th Street #5 >>>>>>>>>> Reedsburg, WI 53959, USA >>>>>>>>>> 1-608-768-7448 >>>>>>>>>> mechanic_2@charter.net >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> --- >>>>>>>>>> This email has been checked for viruses by Avast antivirus >> software. >>>>>>>>>> https://www.avast.com/antivirus >>>>>>>>>> >>>>>>>>>> -- >>>>>>>>>> http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive >>>>>>>>>> View/change your membership options at >>>>>>>>>> http://mailman.mit.edu/mailman/listinfo/piclist >>>>>>>>> -- >>>>>>>>> http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive >>>>>>>>> View/change your membership options at >>>>>>>>> http://mailman.mit.edu/mailman/listinfo/piclist >>>>>>>>> >>>>>>> -- >>>>>>> http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive >>>>>>> View/change your membership options at >>>>>>> http://mailman.mit.edu/mailman/listinfo/piclist >>>>>> -- >>>>>> http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive >>>>>> View/change your membership options at >>>>>> http://mailman.mit.edu/mailman/listinfo/piclist >>>>> -- >>>>> Byron A. Jeff >>>>> Associate Professor: Department of Computer Science and Information >>>>> Technology >>>>> College of Information and Mathematical Sciences >>>>> Clayton State University >>>>> http://faculty.clayton.edu/bjeff >>>>> -- >>>>> http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive >>>>> View/change your membership options at >>>>> http://mailman.mit.edu/mailman/listinfo/piclist >>>>> >>>> >>>> -- >>>> Clint. >>>> >>>> *No trees were harmed in the sending of this mail. However, a large >> number >>>> of electrons were greatly inconvenienced.* >>>> -- >>>> http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive >>>> View/change your membership options at >>>> http://mailman.mit.edu/mailman/listinfo/piclist >> -- >> http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive >> View/change your membership options at >> http://mailman.mit.edu/mailman/listinfo/piclist >> --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus -- http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .