Re: Selection of a USB microcontroller
- From: "Paul E. Schoen" <pstech@xxxxxxxxx>
- Date: Sat, 28 Apr 2007 01:47:39 -0400
"FD" <fd@xxxxxxxxxx> wrote in message
news:4631d3e9$0$30828$e4fe514c@xxxxxxxxxxxxxxxxxxxxxxxxxxx
"Ulf Samuelsson" <ulf@xxxxxxxxxxxxx> schreef in bericht
news:f0r6kh$ge0$1@xxxxxxxxxxx
3. Specifically, if you choose the COM port emulation (usbser.sys),
you'll be dogged with always wondering what the COM port is when you
plug
it in. I hate that problem. Love to know if there's a solution.
A well behaved CDC uses a serial number and you allocate
a new port for every new serial number you detect.
This is not so good in a school environment where
you can have a large qty of USB devices and you will eventually
have a COM port allocated for each such device.
--
Best Regards,
Ulf Samuelsson
This is intended to be my personal opinion which may,
or may not be shared by my employer Atmel Nordic AB
I am a newbie on the USB front and the host side driver is something that
I
overlooked a bit. I definitely need Windows and Linux support.
A USB to serial convertor (in my design) might be a very simple solution.
It is not too hard to find the COM port where the device is connected to:
- scan the first 20 ports for availability (open the device)
- provide a handshake method between application and device
- for multiple devices: serial number the device with handshaking
I already use this with the serial devices I developed, since I
implemented
a serial communications protocol.
Frank
I have had good luck with the Silabs CP2103 USB to Serial Bridge
components. They provide good utility programs for low level programming of
the parts. They seem to work with less problems than other Serial/USB
converters.
For my serial communications, I use SerialNG:
http://www.domis.de/serialng.htm. It seems to work well with Delphi 4.
There is a function that returns a list of all COM ports that have been
enumerated by the PC, so you don't need to try opening all possible ports.
I send out a test code and detect proper response to determine if a device
is connected.
The device I developed is essentially a data collection device, operating
at 2400 samples per second to read line frequency waveforms to 10 bit
accuracy. My port is set for 57600 Baud. I use a Microchip PIC18F242,
14.7456 MHz clock, which divides exactly to the usual baud rates. I
programmed in assembly using a reference application as a starting point.
The 18F parts are designed to be used efficiently with C compilers. I have
C18, but have not yet used it.
Paul
.
- References:
- Selection of a USB microcontroller
- From: FD
- Re: Selection of a USB microcontroller
- From: John Speth
- Re: Selection of a USB microcontroller
- From: Ulf Samuelsson
- Re: Selection of a USB microcontroller
- From: FD
- Selection of a USB microcontroller
- Prev by Date: Re: shame on MISRA
- Next by Date: Re: shame on MISRA
- Previous by thread: Re: Selection of a USB microcontroller
- Next by thread: Re: Selection of a USB microcontroller
- Index(es):
Relevant Pages
|
Loading