Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Microcontroller choice

Status
Not open for further replies.

GarryJ

New Member
Hi all, I'm new to this forum, and reasonably new to microcontrollers. I read the sticky at the top of the forum, but seeing as I'd like to keep my options open rather than committing to a PIC straight away, I thought I'd post here.

I'm looking for a suitable microcontroller to perform the following
functions:

- LCD display control
- Infra-red input processing (correspondent outputs to be interfaced with
FPGA)
- Datalogging (data to later be transferred to PC via USB link)

There is also a possibility it will later be used to control a CD-ROM
drive.

I was considering a PICAXE, due to theirlow cost and extreme simplicity to program, however their serial data output rate (2400 baud) is too low for my needs; even with an LCD alone connected, this results in a very obvious delay in the LCD screen refresh.

Any advice would be much appreciated.

Cheers,

Garry
 
GarryJ said:
Hi all, I'm new to this forum, and reasonably new to microcontrollers. I read the sticky at the top of the forum, but seeing as I'd like to keep my options open rather than committing to a PIC straight away, I thought I'd post here.

I'm looking for a suitable microcontroller to perform the following
functions:

- LCD display control
- Infra-red input processing (correspondent outputs to be interfaced with
FPGA)
- Datalogging (data to later be transferred to PC via USB link)

There is also a possibility it will later be used to control a CD-ROM
drive.

I was considering a PICAXE, due to theirlow cost and extreme simplicity to program, however their serial data output rate (2400 baud) is too low for my needs; even with an LCD alone connected, this results in a very obvious delay in the LCD screen refresh.

Pretty well any micro-controller should be able to do it, but PIC's are the most popular one - you can find examples of most of what you want in my tutorials. Generally serial is FAR easier than USB for transferring to the PC, if you need USB use a serial to USB converter, you can buy these as a chip. If you don't mind the extra complication?, some of the top-range 18F series have USB built-in.
 
I would use a PIC and serial I/O. Why spend extra to convert USB to serial. But it will work.

Looks at Nigel's tutorial 7 and 8 I think.. It is 9600 baud and that is not slow if sending small packets of data. How much data are you transferring? What are you going to write you code in (language)?

LCD you can write directly too one or are you planning on serial to save pins/work?

If you read the current forums for someone tring to hook a floppy drive to a PIC, in that thread there are links to a PIC to IDE controller.

Anyway, without a block diagram of what you are tring to do. Both do it, PIC are popular as stated.
 
mramos1 said:
I would use a PIC and serial I/O. Why spend extra to convert USB to serial. But it will work.

Looks at Nigel's tutorial 7 and 8 I think.. It is 9600 baud and that is not slow if sending small packets of data. How much data are you transferring? What are you going to write you code in (language)?

LCD you can write directly too one or are you planning on serial to save pins/work?

If you read the current forums for someone tring to hook a floppy drive to a PIC, in that thread there are links to a PIC to IDE controller.

Anyway, without a block diagram of what you are tring to do. Both do it, PIC are popular as stated.

Thanks to both of you for your advice.

The USB connection is for ease of use; the device is intended to be used with a laptop, and not many new laptops have RS232 ports.

I plan to code in C, as I've never coded in assembly before and don't really have time to learn it, the user interface for my project is only one section. As for serial or parallel access to the LCD, it depends on what microcontroller I choose, pin count, etc. Anything without a visible delay will suffice.

A block diagram (work-in-progress) of the system is attached. The aim of the game is to have a programmable digital audio filter auditioning system. :eek:
 

Attachments

  • System architecture.jpg
    System architecture.jpg
    67.1 KB · Views: 318
Last edited:
Yea, the laptop sort of forces you to USB.. Like Nigel said there are
chips for it, so that will help on your cost.

I have not played with serial LCDs but I would think they are fast, just the price would be a little more with the decoding onboard.


Good luck on the project.
 
Nigel, further to your post in this thread; do you know of any existing projects that use a PIC as an IDE controller for CD-DA?
 
A guy called 'Keith Wilson' had one on his pages in Germany, along with many other good PIC projects, but the site seems to have vanished!. **broken link removed**

For IDE interfacing you might try **broken link removed**
 
I managed to find Keith Wilson's email address using the wonder of the internet - I've requested the documentation for his CD-DA project, if I get a hold of it I'll post it for posterity.

Next question: anyone know of any good (and reasonably cheap) binary encoded rotary switches I could use for a volume control knob? I've been trawling Google for a while now and the ones I can find are all fairly expensive or too fancy for my needs.

I'm looking for a minimum 8-bit output, incremental preferred to absolute. :)
 
GarryJ said:
Next question: anyone know of any good (and reasonably cheap) binary encoded rotary switches I could use for a volume control knob? I've been trawling Google for a while now and the ones I can find are all fairly expensive or too fancy for my needs.

I'm looking for a minimum 8-bit output, incremental preferred to absolute. :)

*cough* Ahh, cheap probably isn't going to be available if you want 256 counts per rotation- I think you'll need an optical encoder. Over here in the states, the highest resolution non-optical encoder I can get seems to be:

https://www.electro-tech-online.com/custompdfs/2006/07/ECW1J.pdf

36PPR, or 4*36 = 144 counts/rev after the quadrature/grey code decoder for about US$4. Optical encoders start about US$30, and I can get nice 2K count optical encoders for ~US$80.

(BTW, do you really mean incremental over absolute? absolute is usually more desirable...)
 
Possibly I misunderstood the difference between incremental and absolute; what I'd like to incorporate is a dial that increases the volume when turned clockwise, and decreases the volume when turned anti-clockwise, with no limit on the angle of rotation.
 
No, you have it correct then. Absolute would let you have a "off" position somewhere, but if all you want is some knob to fiddle with the setting, then relative is fine. (Absolute encoders either have multiple channels, or at the very least one channel with a limit pulse somewhere - in either case, they're more expensive/much more expensive).
 
Since you already have an FPGA in your system, have you considered implementing your IR receiver, LCD display, and PC communications in it? You seem to know your VHDL (or Verilog) so implementing it all in the FPGA shouldn't be so bad.
 
I considered that option initially, but discarded it for one main reason: the audio filtering that will be carried out in the FPGA will be fairly computationally intensive (1fs → 8fs in both FIR and IIR, both with two channels), and so I want to reserve all of the FPGA for this. In addition, although and FPGA could carry out these tasks, they'll be implemented far more efficiently in a microcontroller - when it comes to control tasks such as polling inputs and datalogging, most FPGAs are very limited due to their architecture.

The device will be used to evaluate the audible impact of varying group delay in IIR filters (compared to the constant group delay in FIR), and to provide a quick and easy way to prototype filters in general.

Back on the topic of CD-DA, I found a good (if a little long) resource here: **broken link removed**
 
In case anyone's interested, I've chosen the lovely PIC16F690 for my project. The USB connectivity has been taken care of by using another chip, the TAS1020B, which also allows for USB audio streaming.

The CD-DA integration is on the back burner for now, as an implementation which would give good quality, low-jitter audio data is just as much work as the rest of the project put together.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top