data collector & transmitter

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 4.
To post in this forum you must have a registered copy of Flowcode 4 or higher. To sign up for this forum topic please use the "Online Resources" link in the Flowcode Help Menu.

Moderator: Benj

Post Reply
nuwan5213
Posts: 82
Joined: Thu Jul 29, 2010 10:03 am
Location: sri lanka
Has thanked: 24 times
Been thanked: 4 times

data collector & transmitter

Post by nuwan5213 »

hi all,
this time im going to make data collector via tcpip.
ok ,my modeule has numaric keypad & lcd.what i enterd by using keypad and it must be display to user via lcd and im going to connect this into router to collect data in to pc.my plan is connect 5 or more devices in to router and collect data.
i dont have any experieance about tcpip protocole and need help.what the chip should i use ?
give me the clear idea. :?:
Electronics for better world.

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: data collector & transmitter

Post by Benj »

Hello,

I would have a look through the Flowcode 4 examples these should include examples of how to send and receive data using the TCP/IP E-block. We use a 16F877A on our TCP/IP solution so you could use this device or you could go for a device with bigger memory if you need more functionality or the ability to store a lot of string data etc.

nuwan5213
Posts: 82
Joined: Thu Jul 29, 2010 10:03 am
Location: sri lanka
Has thanked: 24 times
Been thanked: 4 times

Re: data collector & transmitter

Post by nuwan5213 »

Mr benj

Why we cant manual simiulate keypad? Is it impossible (i mean shft+f8).can yot give me an example of two or more number displayed lcd program.
thanks.
Electronics for better world.

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: data collector & transmitter

Post by Benj »

Hello,

The keypad and LCD components both simulate correctly.

Look in the main Flowcode v4 example download and you will find some good examples.

http://www.matrixmultimedia.com/lc_index.php?p=18

Examples\String Manipulations\4. Inputting a password.fcf

Examples\Components\Keypad\2. Keypad and LCD 16F877A.fcf

nuwan5213
Posts: 82
Joined: Thu Jul 29, 2010 10:03 am
Location: sri lanka
Has thanked: 24 times
Been thanked: 4 times

Re: data collector & transmitter

Post by nuwan5213 »

Hi all,
anyone kindly send me a realtime clock with adjusment buttons.
it will help me a lot.
thanks. :o :o :o
Electronics for better world.

User avatar
JohnCrow
Valued Contributor
Valued Contributor
Posts: 1367
Joined: Wed Sep 19, 2007 1:21 pm
Location: Lincolnshire
Has thanked: 364 times
Been thanked: 716 times

Re: data collector & transmitter

Post by JohnCrow »

There is a digital clock in the flowcode examples folder (Interupts folder)

http://www.matrixmultimedia.com/lc_index.php?p=18

Plus I'm sure if you search the forums you will find more examples.
1 in 10 people understand binary, the other one doesn't !

nuwan5213
Posts: 82
Joined: Thu Jul 29, 2010 10:03 am
Location: sri lanka
Has thanked: 24 times
Been thanked: 4 times

Re: data collector & transmitter

Post by nuwan5213 »

hi ,
it desnt help me
i want clock with adjusment buttons.
thanks,
best regards
nuwan :(
Electronics for better world.

medelec35
Matrix Staff
Posts: 9521
Joined: Sat May 05, 2007 2:27 pm
Location: Northamptonshire, UK
Has thanked: 2585 times
Been thanked: 3815 times

Re: data collector & transmitter

Post by medelec35 »

Hi nuwan,
You have not said how you want to adjust clock. E.g with keypad buttons, directly entering time, or just separate buttons to adjust time.
Here is a clock example that uses two buttons for time adjustement.
http://www.matrixmultimedia.com/mmforum ... 824#p15813

Martin
Martin

nuwan5213
Posts: 82
Joined: Thu Jul 29, 2010 10:03 am
Location: sri lanka
Has thanked: 24 times
Been thanked: 4 times

Re: data collector & transmitter

Post by nuwan5213 »

hi martin,
this time i modified digital clock to transmitt data measns seconds,miniutes,hours to pc via rs232 also send a unit id why im going to attach several units parallal.also i need to get two digit number to transmitt that was my data also.
can i do this?
i dont build any hardwear for that.
if i connect several unit parallely and recive datas via pc com port possible.?

simply what i want is collect time ,unit id, and two digit data only.i sent unit id every main program cycle to identify the unit is online.
is it going to work.?
give some advices before i build cct.
best regards,
nuwan.
Attachments
clock_data_transmitter_test1.fcf
(19.09 KiB) Downloaded 325 times
Electronics for better world.

nuwan5213
Posts: 82
Joined: Thu Jul 29, 2010 10:03 am
Location: sri lanka
Has thanked: 24 times
Been thanked: 4 times

Re: data collector & transmitter

Post by nuwan5213 »

Jhon,
please findout my flow chart and givr me advice,.
thanks.
nuwan.
Electronics for better world.

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: data collector & transmitter

Post by Benj »

Hello Nuwan,
this time i modified digital clock to transmitt data measns seconds,miniutes,hours to pc via rs232 also send a unit id why im going to attach several units parallal.also i need to get two digit number to transmitt that was my data also.
Do you mean you are going to attach multiple microcontroller UARTs to a single PC RS232 interface. This is likely to fail as if two microcontrollers transmit data at the same time then the PC will receive corrupt data. Even if data is not corrupted by a collision the TX pin is always driving the signal so the microcontrollers would essentially be fighting each other for control of the signal probably leading in damaging the microcontrollers. You could use resistors to circumvent this but the collisions would still be an issue. What would be better is if everything came to a central point before being sent to the PC. A RS485 bus could potentially be used to do this.
http://www.matrixmultimedia.com/article.php?a=419

Alternatively you could use resistors to connect the signals together and then have a pin that tells the other microcontrollers that you are sending data. The microcontrollers must then all check this signal before sending to ensure a collision does not occur.
simply what i want is collect time ,unit id, and two digit data only.i sent unit id every main program cycle to identify the unit is online.
is it going to work.?
One unit: Yes,
Multiple Units: Not directly without some kind of work around for the collision and bus contention problems.

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: data collector & transmitter

Post by Benj »

Here is a basic schematic using the resistor and busy signal method.
ben1.jpg
ben1.jpg (62.67 KiB) Viewed 6991 times
A particular chip will check the RA0 pin as an input. If the pin is high then the chip pulls the pin low before sending the RS232 data. If the pin is low then the microcontroller waits a random amount of time before trying again.

nuwan5213
Posts: 82
Joined: Thu Jul 29, 2010 10:03 am
Location: sri lanka
Has thanked: 24 times
Been thanked: 4 times

Re: data collector & transmitter

Post by nuwan5213 »

Hi,

Tnanks ben .i will back to you with results after building cct.
regards,
nuwan.
Electronics for better world.

Post Reply