> from the help line
>I have an ArmMite SBC that communications via the RS232 port to the PC. I am
able to talk to it when the ArmMite goes through a USB hub, but when I connect
directly to the PC I do not get any data.
>On the PC side I am writing code in Ansi C using the National Instruments
LabWindows/CVI IDE.
While I don't have any experience with Labview's C. I would suspect that the
com port (ie COM1 COM2 ...) is changing between the 2 configurations.
You could determine this by looking in the Device Manager.
Or just shut down your LabView (so it closes the ports)
and run BASICtools or TclTerm in the 2 configurations to see what COM port is in
use (do a refresh under Options->Port)
Labview serial link
-
- Posts: 1462
- Joined: Fri Oct 19, 2012 5:11 am
Re: Labview serial link
The COM port number does not change when I move the USB from the ArmMite from
the USB hub to directly to the PC.
I am able to get the data stream out of the ArmMite, but I must press the RESET
push button. How do I get it to start without having to press the RESET button?
(Not necessary if plugged into PC via a USB hub).
the USB hub to directly to the PC.
I am able to get the data stream out of the ArmMite, but I must press the RESET
push button. How do I get it to start without having to press the RESET button?
(Not necessary if plugged into PC via a USB hub).
-
- Posts: 1462
- Joined: Fri Oct 19, 2012 5:11 am
Re: Labview serial link
What is probably happening is that when in the USB hub and you plug in the
ARMmite, it pulses DTR low (reseting the ARMmite) but is holding RTS high so it
comes up and runs your code.
But when plugged into the PC, it is holding RTS low when it last pulses DTR so
that it comes up into the NXP boot loader.
Why the difference, you'd have to ask Bill Gates on this one.
what to do??--
If you are running BASIC on the ARMmite, you could disconnect RTS.
looking at the board the trace runs through the middle of the 6 of R6 down,
makes a right turn to a via. Cut it on the backside after that via, which would
allow you to jumper it back if you needed it in the future.
If you're running C you'll need to make it selectable (install a jumper or
switch).
Alternatively you could disable the USB reset by lifting pin 2 on U2, not easy
without a microscope, very good iron, and a fine pointed probe.
ARMmite, it pulses DTR low (reseting the ARMmite) but is holding RTS high so it
comes up and runs your code.
But when plugged into the PC, it is holding RTS low when it last pulses DTR so
that it comes up into the NXP boot loader.
Why the difference, you'd have to ask Bill Gates on this one.
what to do??--
If you are running BASIC on the ARMmite, you could disconnect RTS.
looking at the board the trace runs through the middle of the 6 of R6 down,
makes a right turn to a via. Cut it on the backside after that via, which would
allow you to jumper it back if you needed it in the future.
If you're running C you'll need to make it selectable (install a jumper or
switch).
Alternatively you could disable the USB reset by lifting pin 2 on U2, not easy
without a microscope, very good iron, and a fine pointed probe.
-
- Posts: 1462
- Joined: Fri Oct 19, 2012 5:11 am
Re: Labview serial link
OR--
you could control the reset from your C program.
I don't know if Labview has the same mechanism as GCC, but source to do that is
in the files section here at
you could control the reset from your C program.
I don't know if Labview has the same mechanism as GCC, but source to do that is
in the files section here at
- Attachments
-
- ARMserial.zip
- PC serial program in C
- (16.16 KiB) Downloaded 765 times
-
- Posts: 1462
- Joined: Fri Oct 19, 2012 5:11 am
Re: Labview serial link
On the PC Side when opening the port in the program I am logging with, I flash
the DTR signal.
In VB.NET it looks like this,
SerPort.Open()
SerPort.DtrEnable = True
Application.DoEvents()
SerPort.DtrEnable = False
Would just be short a couple of semi-colons for C#.
Hope it helps.
Darin
the DTR signal.
In VB.NET it looks like this,
SerPort.Open()
SerPort.DtrEnable = True
Application.DoEvents()
SerPort.DtrEnable = False
Would just be short a couple of semi-colons for C#.
Hope it helps.
Darin
-
- Posts: 1462
- Joined: Fri Oct 19, 2012 5:11 am
Re: Labview serial link
When using Labwindows CVI to communicate to the armmite use the VISA
serial functions as thease will alow you to control the control lines of
the poer brining the ammite out of reset. This can not be done in the
standard rs232 library.
Colin
The COM port number does not change when I move the USB from the ArmMite
from the USB hub to directly to the PC.
I am able to get the data stream out of the ArmMite, but I must press
the RESET push button. How do I get it to start without having to press
the RESET button? (Not necessary if plugged into PC via a USB hub).
serial functions as thease will alow you to control the control lines of
the poer brining the ammite out of reset. This can not be done in the
standard rs232 library.
Colin
The COM port number does not change when I move the USB from the ArmMite
from the USB hub to directly to the PC.
I am able to get the data stream out of the ArmMite, but I must press
the RESET push button. How do I get it to start without having to press
the RESET button? (Not necessary if plugged into PC via a USB hub).